Skip to content

How to get all the NFTs ever owned by a given address on Ethereum ? #258

Answered by PatrickAlphaC
TilakMaddy asked this question in Q&A
Discussion options

You must be logged in to vote

That's exactly what they do 😎

...sort of.

(Keep in mind, this is speculation cuz I can't see their code, but this is how I'd do it)

They do it a bit more "on-the-fly". When a user looks up an address, they start indexing on that address and add the results to whatever database they are using. Once they have found all the NFTs an address has, they can easily load that information for next time.

So they do a quick listen for all Transfer events and boom. That's pretty much it.

I'm sure they have a pretty big codebase to optimize stuff too.

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
3 replies
@TilakMaddy
Comment options

@TilakMaddy
Comment options

@PatrickAlphaC
Comment options

Answer selected by PatrickAlphaC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants