NFT
12 min

How to Create an NFT in 2026 — Step-by-Step Guide (No Code & With Code)

Published
· Updated

How to Create an NFT — Two Paths

There are two realistic ways to create an NFT in 2026:

  1. No-code platform — fastest, no Solidity knowledge required.
  2. Custom ERC-721 contract — full control over royalties, mint logic and on-chain metadata.

This guide covers both. If you're just exploring, start with the no-code path. If you're building a serious collection or learning to be a Web3 developer, the contract path is worth the extra effort.

If you're new to NFTs, read the NFT glossary entry and the ERC-721 standard first.

Path 1 — No-Code: Mint on OpenSea or Manifold

Step 1: Set up a wallet

Install MetaMask and securely back up the seed phrase. Use a hardware wallet if the collection has any real value.

Step 2: Choose your chain

For lowest fees, mint on a Layer 2 (Base, Arbitrum, Optimism, Polygon). For maximum prestige and liquidity, mint on Ethereum mainnet — but expect higher gas fees.

Step 3: Add a tiny amount of ETH

You'll need ~$2–10 worth on an L2, or $20–100 on Ethereum mainnet, to cover gas.

Step 4: Create the collection

On OpenSea Studio or Manifold:

  1. Click "Create"
  2. Upload your image, video or 3D file
  3. Add name, description, traits, external link
  4. Pick a royalty (usually 2.5–10%)
  5. Confirm the transaction

That's it — you've minted an NFT.

What it actually does under the hood

The platform uses a shared factory contract (or your own Manifold contract) to mint a new token in an ERC-721 collection. Your metadata is uploaded to IPFS so it can't be silently changed.

Path 2 — Code: Your Own ERC-721 Contract

Step 1: Project setup

npx hardhat init
npm install @openzeppelin/contracts

Step 2: Write the contract

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.24;

import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol";
import "@openzeppelin/contracts/access/Ownable.sol";

contract MyCollection is ERC721URIStorage, Ownable {
    uint256 public nextId;
    uint256 public constant MAX_SUPPLY = 1000;
    uint256 public constant PRICE = 0.01 ether;
    string private _baseTokenURI;

    constructor(string memory baseURI)
        ERC721("MyCollection", "MYC")
        Ownable(msg.sender)
    {
        _baseTokenURI = baseURI;
    }

    function mint() external payable {
        require(nextId < MAX_SUPPLY, "Sold out");
        require(msg.value >= PRICE, "Pay price");
        uint256 tokenId = nextId++;
        _safeMint(msg.sender, tokenId);
        _setTokenURI(tokenId, string(abi.encodePacked(_baseTokenURI, _toString(tokenId), ".json")));
    }

    function withdraw() external onlyOwner {
        payable(owner()).transfer(address(this).balance);
    }

    function _toString(uint256 value) internal pure returns (string memory) {
        if (value == 0) return "0";
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) { digits++; temp /= 10; }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }
}

Step 3: Prepare metadata

Each token needs a JSON file like:

{
  "name": "My Collection #1",
  "description": "A piece of my generative series.",
  "image": "ipfs://CID/1.png",
  "attributes": [
    { "trait_type": "Background", "value": "Cipher Green" },
    { "trait_type": "Rarity", "value": "Common" }
  ]
}

Upload images and JSON to IPFS via Pinata, NFT.Storage or web3.storage. Use the resulting CID as your baseURI (e.g. ipfs://bafy.../).

Step 4: Deploy

npx hardhat run scripts/deploy.ts --network base

Verify on the relevant block explorer so OpenSea can read your contract correctly.

Step 5: List it

Once minted, NFTs appear automatically on OpenSea, Blur, Magic Eden and other marketplaces that index the chain. You don't need to manually upload — the contract is the source of truth.

How Much Does It Cost to Create an NFT?

PathChainTypical cost (mid-2026)
OpenSea lazy-mintPolygon / Base$0 — buyer pays gas
OpenSea standard mintEthereum$5–40 in gas
Custom ERC-721 deployBase / Arbitrum / Optimism$1–5
Custom ERC-721 deployEthereum mainnet$40–250 depending on gas

How Royalties Actually Work in 2026

NFT royalties are not enforced at the protocol level. They're enforced (or ignored) by marketplaces. As of 2026:

  • OpenSea respects on-chain royalties via the EIP-2981 standard.
  • Some marketplaces (Blur, X2Y2) honor lower or zero royalties.
  • The reliable royalty is the one you bake into mint price, not what you hope to collect on secondary.

OpenZeppelin's ERC2981 extension makes royalties trivial to implement.

Common Mistakes That Hurt Your Collection

  • Hosting images on a private server. If your server dies, the NFT shows a broken image. Use IPFS (or Arweave) for true permanence.
  • Skipping contract verification. Buyers won't trust an unverified contract.
  • Massive total supply. 10,000 mediocre PFPs are worth less than 100 strong pieces.
  • Lazy-minting then never paying gas. Lazy mints are technically not on-chain until first sale — fine for many use cases, not great if the collection grows.
  • Centralized "freeze metadata" buttons. If you can change metadata later, so can a hacker who gets your private key.

Should You Use a No-Code Platform or Build Your Own?

NeedRecommendation
One-off art pieceOpenSea / Manifold
Small artist collectionManifold (great for artists, full ownership)
Generative PFP projectCustom ERC-721 + IPFS pipeline
Gaming / utility NFTCustom ERC-1155
Soulbound / identityCustom non-transferable ERC-721

FAQ

Can I create an NFT for free?

Yes — using lazy-mint on Polygon or via Manifold's free tier. The buyer pays gas on first transfer.

Do I need to know how to code?

No for path 1. Yes (Solidity + a little JS) for path 2.

Where should I store the artwork?

IPFS or Arweave, not a private server.

How do I sell my NFT?

List it on a marketplace (OpenSea, Blur, Magic Eden for Solana). Marketing matters more than tech.

Learn More

To actually understand what happens when you mint an NFT — what state changes on-chain, what gas you're paying for, how the wallet signature flows — work through our Solidity smart contracts guide and the Bitcoin 101Proof of Worksmart contract course path.

Ready to Learn By Doing?

Stop reading. Start building. Our interactive simulations teach you blockchain mechanics through hands-on experience.

Explore Courses