NFTs12 min read
Setting Up IPFS Metadata
Configure IPFS for decentralized, permanent NFT metadata storage that will outlast any centralized server.
What is IPFS?
IPFS (InterPlanetary File System) is a decentralized storage protocol. Unlike traditional URLs that point to a server location, IPFS uses content addressing - files are identified by their content hash (CID), ensuring the content never changes.
Permanent - content never changes
Decentralized - no single point of failure
Verifiable - hash proves content integrity
Standard - supported by all NFT marketplaces
IPFS Providers
Step-by-Step Guide
Step 1
Choose an IPFS Provider
Select a pinning service to host your files permanently.
- Pinata: Most popular, user-friendly, generous free tier
- NFT.Storage: Free, backed by Protocol Labs
- Infura: Enterprise-grade with API access
- Web3.Storage: Free with Filecoin backing
- Self-hosted: Run your own IPFS node
Step 2
Prepare Your Assets
Organize your images and media files for upload.
- Name files sequentially: 1.png, 2.png, 3.png, etc.
- Use consistent dimensions and formats
- Optimize file sizes for faster loading
- Include high-res and thumbnail versions if needed
- Verify all files before upload
Step 3
Upload Images to IPFS
Upload your images folder and get the CID (Content Identifier).
- Upload entire folder to maintain structure
- Record the folder CID (starts with "Qm..." or "bafy...")
- Verify images are accessible via IPFS gateway
- Example URL: ipfs://QmXxx.../1.png
- Pin files to ensure persistence
Step 4
Create Metadata JSON Files
Generate JSON metadata for each NFT following standards.
- Create one JSON file per NFT (1.json, 2.json, etc.)
- Include: name, description, image, attributes
- Point image field to IPFS URL of the image
- Follow OpenSea/marketplace metadata standards
- Use consistent attribute trait types
Step 5
Upload Metadata to IPFS
Upload your metadata folder and get the base URI.
- Upload metadata folder to IPFS
- Record the metadata folder CID
- This CID becomes your base URI for the collection
- Format: ipfs://QmMetadataCID/
- Verify metadata is correctly formatted
Metadata JSON Example
Standard NFT metadata format (OpenSea compatible)
{
"name": "Cool NFT #1",
"description": "This is a cool NFT from my collection.",
"image": "ipfs://QmImageFolderCID/1.png",
"attributes": [
{
"trait_type": "Background",
"value": "Blue"
},
{
"trait_type": "Rarity",
"value": "Common"
}
]
}Pro Tips
- Always pin your files with at least one pinning service for persistence
- Use a dedicated IPFS gateway for faster loading (Pinata, Cloudflare)
- Test your metadata on OpenSea testnet before mainnet launch
- Keep local backups of all your files and metadata
- Consider using Arweave for truly permanent storage alongside IPFS