What is NFT Metadata & How Does...

December 8, 2021

The word “meta” is all the rage lately since the Facebook name re-brand, but let’s get our crypto fundamentals in order before everything is referred to as metadata. 

A Non-Fungible Token (NFT) is a token that represents a single specific digital asset, whether that be a .JPEG file, .GIF, .MP4, or whatever else. That file itself can’t be hosted on the Ethereum blockchain, so it’s hosted off-chain. NFT metadata specifies what that data is and includes things like the visual or auditory asset and other information like transactional history. 

NFT metadata is essentially a workaround to avoid the technical and financial catastrophe (or, impossibility, rather) of hosting large files natively on-chain on Ethereum or other blockchain environments. 

For example, if you wanted to run a full Ethereum node, you’d have to download the full Ethereum blockchain of about 1,050 GB (the archival nodes, or the entirety of the Ethereum blockchain since it launched, is about 9,000 GB). 

That’s to run the entire Ethereum network– yes, all ETH-related matters, DeFi, NFTs, and dApps make up just under 1,100 GB. 

In comparison, a 1080 full-feature length movie is about 2 to 4 GB on its own, and most high-quality images can be around 2 to 20 MB. There simply isn’t a way to store these files on the Ethereum blockchain because it would make running the network prohibitively storage and data-consuming.

How expensive are we talking? Gemini estimates that simply storing 1 GB of data on the Ethereum blockchain costs about 17,500 ETH (or $75.75 million as of November 2021). The costs to simply just store a blockbuster movie like James Cameron’s Avatar on the Ethereum blockchain would be more than the costs of making the $237 million film. 

That’s where NFT metadata comes in. It’s a careful balance of utilizing the blockchain without burdening it with the data. 

But, NFT metadata existing off-chain creates a few other issues, which we’ll get into below. 

Let’s Get Technical: NFT Metadata

We’ll use the classic Ethereum ERC-721 token standard for the following NFT discussion.

Each ERC-721 contains a “metadata” string in its definition, which defines what the non-fungible token actually is. For example, this metadata could point to a specific .JPEG, which makes all the difference; although a CryptoPunk .JPEG and a DeadFellaz .JPEG are of comparable file size, they’re worth significantly different amounts. 

The crux of the matter that trips people up about NFT metadata is where exactly files are stored off-chain– is it a Google Drive of some sorts? Is it some Amazon Web Services file storage? Who runs the show of hosting NFT metadata online?

Each NFT references the visual or auditory (image, audio, etc) file that exists online somewhere. It makes a request for the content at a specific location, which returns the content for you to see or hear. NFTs usually point to an IPFS (InterPlanetary File System) hash or an HTTP URL somewhere on the Internet. 

This “somewhere” is generally hosted by the website that hosts the NFT. ERC-721s specify metadata in a standardized JSON (JavaScript Object Notation) format, that looks something like this

The information is stored as a URI (Universal Resource Identifier) inside the Ethereum contract, rather than a JSON; storing a JSON would be prohibitively expensive and resource-demanding. The URI string, however, points to a location where the user can find the token’s JSON description. 

The token’s metadata exists as a permanent, unalterable record on the blockchain, and this record describes what the token represents (its URI string to JSON), the token’s ownership and transaction history. The JSON file contains the image’s name, description, URL of where it's hosted, and sometimes more granular information like the project’s total supply, type of encryption, and a unique signature. 

Limitations of NFTs 

This JSON metadata typically only identifies the asset, and doesn’t provide much in-depth information beyond the bare essentials. 

The data isn’t very searchable or readable by other smart contracts, which is a kink and limitation of the Ethereum network that multiple projects are attempting to address. 

The data is created by the token minters, who actually own the NFT contract. However, users can’t update the data, for better or for worse, which can be problematic for a few reasons.

For one, as we’ve seen in the evolving Internet ecosystem, links can break. Since the NFT metadata links you to somewhere else to view the art, if that link dies, you’ll essentially be pointing to a very expensive 404 error page. The JSON data can’t be updated by users, and neither can the links be fixed. 

The crux of the issue is that if the data were able to be updated, the inherent value of the NFT could be compromised. For example, let’s say a malicious third-party found an exploit to change all the Bored Ape Yacht Club image metadata with pictures of real-world apes found on Google; the market would respond, and likely negatively.

Hosting Mechanisms also have their fair share of limitations:

  1. HTTP server owners could theoretically change the content of a specific server to whatever they like.
  2. IPFS is designed for decentralized hosting, but is still operated by centralized entities like NFT marketplaces that serve the role of IPFS nodes that keep the gateway live. 

Final Thoughts: What is NFT Metadata Exactly?

As we’ve learned, NFT metadata is the second of the two key pieces to the NFT value proposition. 

The first is that NFTs have a unique ID that distinguishes each token as unique from every other token. The ERC-721 tokenization standard utilizes Ethereum smart contracts to record transfers and changes of ownership of each particular NFT, which is a fairly computation-heavy endeavor. This is why gas fees are generally much higher for trading or minting NFTs compared to simply sending ETH on the network. 

NFT metadata is baked into the second fundamental feature that makes NFTs tick. NFTs can link to data external to their smart contract, essentially allowing the network to reference data that exists off-chain. This keeps the computational costs of running NFTs on a network like Ethereum lower than they would be. 

The Non-Fungible Token that defines the provenance of an asset lives on the blockchain, whereas the asset itself typically lives off-chain. There are few exceptions; for example, OnChain Monkeys is a collection created entirely on chain with a single transaction.  There is no file storage solution needed since the entire collection is hosted on-chain. 

Latest post

Anthony Georgiades

January 12, 2022

Alex Moskov

January 12, 2022

Andrew Amarosa

January 12, 2022

Andrew Amarosa

January 4, 2022

Anthony Georgiades

January 4, 2022

jonas

January 4, 2022

Anthony Georgiades

January 4, 2022

Andrew Amarosa

January 4, 2022

Alex Moskov

January 4, 2022

Andrew Amarosa

December 22, 2021

Get the latest news

from the Pastel Network