Goyalayus

Notes, essays, and fragments from the edge of understanding.

NFT's are Okayish

August 18, 2025

Original Substack post

Imagine you're a digital artist. You've just created your masterpiece and want to sell 100 limited-edition, signed copies. In the physical world, this is straightforward: you print 100 copies, sign and number each one ("1/100," "2/100," etc.), and their scarcity gives them value.

But how do you "sign" a digital file? How do you prove that one JPEG is an "original" part of the limited series, while another is just a right-click-save copy? This has been the central challenge of digital ownership for decades. A perfect copy of a file is indistinguishable from the original, making true scarcity impossible.

That is, until the invention of a technology that could create a unique, verifiable "digital signature" for any item: the Non-Fungible Token, or NFT.

The Problem: Fungible vs. Non-Fungible

Most of our valuable property in the real world is non-fungible. Your house is not interchangeable with your neighbor's. Your specific car, with its unique Vehicle Identification Number (VIN), is not the same as another car of the same model. Your concert ticket for Seat 22, Row 5, is not the same as a ticket for Seat 23. They are all unique.

Early cryptocurrencies and tokens on the blockchain were fungible, meaning each unit was identical and interchangeable. One Bitcoin is the same as any other Bitcoin. On the Ethereum network, the popular ERC-20 standard created tokens that were also fungible. My "AliceCoin #1" was the same as my "AliceCoin #2." This was great for creating currencies, but it couldn't solve our artist's problem. You can't have a limited edition of 100 unique prints if every token representing them is identical.

The Solution: A Digital Deed of Ownership (ERC-721)

In 2017, a new standard was proposed to solve this very problem: ERC-721. This standard provided a blueprint for creating Non-Fungible Tokens (NFTs).

Think of an ERC-721 smart contract as a digital deed registry or a title of ownership for a finite collection of unique items. It's a public ledger that definitively proves who owns which specific item.

The core idea is simple but powerful: it maps a unique Token ID to a specific owner's address. For our artist's collection of 100 prints, it would look like this:

  • Token ID #1 (Print 1/100) -> Owned by Address 0xabc...

  • Token ID #2 (Print 2/100) -> Owned by Address 0xdef...

  • Token ID #3 (Print 3/100) -> Owned by Address 0xabc...

  • ...and so on, up to Token ID #100.

Each Token ID is a distinct asset. You cannot own "half" of Token ID #1, and Token ID #1 is not interchangeable with Token ID #2, even though they might look the same. The contract guarantees their uniqueness.

The Anatomy of an ERC-721 Token Contract

So, how does this "digital deed registry" actually work? The ERC-721 standard requires a contract to have a specific set of functions that manage ownership.

1. Core Ownership Functions:

  • ownerOf(uint256 _tokenId): This is the most fundamental function. You can ask the contract, "Who owns Print #75?" and it will return the public blockchain address of the owner. It's an undeniable, public proof of ownership.

  • transferFrom(address _from, address _to, uint256 _tokenId): This is how ownership is transferred. The current owner (_from) can call this function to send their specific print (_tokenId) to a new owner (_to). This is the digital equivalent of selling or gifting the artwork.

2. The "Approval" Mechanism:

What if a collector wants to sell their print on a marketplace like OpenSea? They don't want to give the marketplace their private keys. This is where approvals come in.

  • approve(address _approved, uint256 _tokenId): The owner of a print can call this function to give another address (like a marketplace's smart contract) permission to transfer that single token on their behalf. This is a secure way to enable trading.

The "Signature" and the "Artwork": Linking the Deed to the Art

This is the most crucial part. The NFT contract itself doesn't store the massive image or video file on the blockchain—that would be astronomically expensive. Instead, it holds a link to the artwork's information, or metadata.

  • tokenURI(uint256 _tokenId): This function links the Token ID to its metadata. When called, it returns a URL (often to a decentralized storage system like IPFS to ensure it can't be taken down). This URL points to a simple JSON file.

That JSON file is like the plaque next to a painting in a museum. It contains all the "traits" or "properties" of the NFT:

The smart contract provides the unquestionable proof of ownership, and the tokenURI links that ownership to the specific digital content and its properties.

Pseudocode: The Blueprint for Our Artist's Collection

Let's imagine the simplified code for our artist's collection of 100 signed prints.

I know what you all are thinking This is not a fucking use-case, yeah I know, This is what I also think, hence the Title