A comprehensive, open-source NFT portfolio management platform built by the Web3Market Team. This boilerplate provides a complete solution for viewing, managing, and trading NFTs across multiple marketplaces using NFTGo as the primary marketplace aggregator with modern Web3 integrations.
π Marketplace Aggregation: Leverages NFTGo's marketplace aggregator to seamlessly list NFTs on multiple platforms including OpenSea, LooksRare, and more marketplaces coming in the future.
π Website: web3market.site π Live Demo: nft-portfolio.web3market.site
- NFTGo Marketplace Aggregator: Primary marketplace aggregator enabling listing across multiple platforms
- Supported Marketplaces: OpenSea, LooksRare, and more platforms (expanding in the future)
- NFTGo API: Comprehensive NFT data provider and marketplace integration
- Moralis: Spam detection and additional NFT metadata
- View complete NFT collection with rich metadata
- Real-time pricing data and market analytics
- Bulk listing and management tools
- Advanced filtering and sorting capabilities
- Pagination with smooth animations
- Multi-Marketplace Listing: List NFTs across multiple marketplaces simultaneously via NFTGo aggregator
- Supported Platforms: OpenSea, LooksRare, with more marketplaces coming in the future
- Edit existing listings with price updates
- Cancel listings with one-click functionality
- Accept offers and manage bids:
β οΈ TODO - Not yet implemented - Real-time marketplace fee calculations
- IPFS Media Support: Automatic detection and rendering of images, videos, and audio
- Traits & Attributes: Comprehensive NFT metadata display
- Price Estimation: Bulk pricing analysis using NFTGo's AI-powered pricing
- Responsive Design: Mobile-first approach with Tailwind CSS v4
- Mobile Navigation: Slide-in hamburger menu with smooth animations for mobile devices
- Dark/Light Mode: Seamless theme switching
- Social Integration: Direct links to Web3Market social channels
- RainbowKit: Modern wallet connection with support for 100+ wallets
- Wagmi: Type-safe Ethereum interactions
- Viem: Lightweight Ethereum client
- WalletConnect: Secure wallet connectivity
- Node.js 18.0 or higher
- Yarn or npm package manager
- Git for version control
git clone https://github.com/web3marketsite/nft-portfolio-boilerplate.git
cd nft-portfolio-boilerplate
# Using yarn (recommended)
yarn install
# Or using npm
npm install
Create a .env.local
file in the root directory and add the following environment variables:
# NFTGo API Configuration
NFTGO_API_KEY=your_nftgo_api_key_here
# Moralis API Configuration
MORALIS_API_KEY=your_moralis_api_key_here
# Optional: Enable mock data for development
NEXT_PUBLIC_USE_MOCK_DATA=false
- Visit NFTGo Developer Portal
- Sign up for a free account
- Create a new project and copy your API key
Pricing Information:
- Free Tier: Available with rate limits
- Paid Plans: Check NFTGo Developer Portal for current pricing
- Note: Some advanced features may require a paid subscription
- Visit Moralis Admin Panel
- Create a free account
- Navigate to Web3 APIs and copy your API key
Pricing Information:
- Starter Plan: FREE - 40,000 Compute Units per day
- Pro Plan: $49/month - 15M Compute Units per month
- Business Plan: $249/month - 75M Compute Units per month
- Enterprise Plan: Custom pricing for high-volume usage
For detailed pricing and features, visit Moralis Pricing
π‘ Tip: Both services offer free tiers that are sufficient for development and testing. You can start with free accounts and upgrade as your application scales.
# Using yarn
yarn dev
# Or using npm
npm run dev
Open http://localhost:3000 in your browser to see the application.
src/
βββ app/ # Next.js App Router pages
β βββ api/ # API routes for external service proxies
β β βββ nftgo/ # NFTGo API proxy endpoints
β β βββ moralis/ # Moralis API proxy endpoints
β βββ nft/ # Individual NFT detail pages
β β βββ [contractAddress]/[tokenId]/
β β βββ offers/ # NFT offers page
β βββ globals.css # Global styles with Tailwind CSS v4
β βββ hero.ts # HeroUI configuration
β βββ layout.tsx # Root layout component
β βββ page.tsx # Main portfolio dashboard
β βββ providers.tsx # App providers (Wagmi, RainbowKit, etc.)
βββ components/ # Reusable UI components
β βββ debug/ # Development debugging components
β βββ icons/ # Custom icon components
β βββ layout/ # Layout components (Header, Footer)
β βββ marketplace/ # Trading and listing components
β βββ nft/ # NFT display components
β βββ ui/ # Base UI components (modals, buttons, etc.)
β βββ wallet/ # Wallet connection components
βββ config/ # Application configuration
β βββ app.config.json # App-wide settings
βββ context/ # React Context providers
β βββ MagicEdenContext.tsx # Magic Eden integration
β βββ NFTContext.tsx # NFT data management
β βββ PriceContext.tsx # Pricing data management
βββ hooks/ # Custom React hooks
β βββ useNFTListings.ts # NFT listings management
β βββ useWeb3MarketModal.ts # Modal state management
βββ lib/ # Utility libraries and configurations
β βββ constants.ts # App constants
β βββ dev-utils.ts # Development utilities
β βββ utils.ts # General utilities
β βββ walletConnectConfig.ts # Wallet connection config
βββ services/ # External API integrations
β βββ marketplace/ # Marketplace service implementations
βββ types/ # TypeScript type definitions
β βββ index.ts # Main type definitions
βββ utils/ # Helper functions
βββ formatters.ts # Data formatting utilities
βββ ipfs.ts # IPFS handling utilities
- Next.js 15: React framework with App Router and Turbopack
- React 19: Latest React with concurrent features
- TypeScript: Type-safe development
- Tailwind CSS v4: Modern utility-first CSS framework with CSS-first configuration
- Framer Motion: Smooth animations and transitions
- HeroUI: Modern React component library (formerly NextUI)
- Wagmi: React hooks for Ethereum
- Viem: TypeScript Ethereum client
- RainbowKit: Wallet connection UI
- WalletConnect: Multi-wallet support
- NFTGo: Primary NFT data provider and marketplace aggregator API
- Moralis: NFT metadata and spam detection
- Infura: Ethereum node provider
- ESLint: Code linting and formatting
- PostCSS: CSS processing with Tailwind CSS v4 plugin
- TanStack Query: Server state management (formerly React Query)
# Development
yarn dev # Start development server with Turbopack
npm run dev # Alternative with npm
# Production
yarn build # Build for production
yarn start # Start production server
npm run build # Alternative with npm
npm run start # Alternative with npm
# Code Quality
yarn lint # Run ESLint
npm run lint # Alternative with npm
This application makes extensive use of external APIs. Here's what you need to know:
- NFT Collection Loading: ~1-5 requests per wallet
- Marketplace Listings: ~3-10 requests per refresh
- Bulk Pricing: 1 request per pricing analysis
- Trading Operations: 2-5 requests per transaction
- Spam Detection: ~1 request per 50 NFTs
- Metadata Enrichment: ~1 request per 10 NFTs
- Wallet Validation: ~1 request per wallet connection
The application implements intelligent rate limiting:
- Caching: API responses are cached to minimize requests
- Batching: Multiple NFTs processed in single requests where possible
- Progressive Loading: Data loads incrementally to improve UX
- Error Handling: Graceful degradation when rate limits are hit
- Start with Free Tiers: Both APIs offer generous free allowances
- Monitor Usage: Check your API dashboards regularly
- Cache Aggressively: The app caches data to reduce API calls
- Upgrade Gradually: Scale your API plans as your user base grows
The project uses RainbowKit with a pre-configured setup. To customize wallet options, edit src/app/providers.tsx
:
const config = getDefaultConfig({
appName: 'Your NFT Dashboard',
projectId: 'your_walletconnect_project_id', // Get from WalletConnect Cloud
chains: [mainnet], // Add more chains as needed
ssr: true,
});
All external API calls are proxied through Next.js API routes to:
- Secure API keys on the server side
- Handle CORS issues
- Add request/response transformations
- Implement rate limiting
Configure allowed image domains in next.config.ts
:
const nextConfig: NextConfig = {
images: {
domains: [
'metadata.ens.domains',
'ipfs.io',
'i.seadn.io',
// Add more domains as needed
]
}
};
The project uses Tailwind CSS v4 with modern CSS-first configuration:
- Theme Configuration: Define custom colors, fonts, and breakpoints directly in
src/app/globals.css
using the@theme
directive - No Config File Required: Tailwind CSS v4 eliminates the need for
tailwind.config.js
- CSS Variables: Native CSS custom properties for theme values
- Components: Styled with HeroUI components
- Animations: Custom animations with Framer Motion
/* src/app/globals.css */
@import "tailwindcss";
@theme {
--color-brand-primary: oklch(0.7 0.15 200);
--color-brand-secondary: oklch(0.8 0.1 300);
--font-family-display: "Inter", sans-serif;
--breakpoint-3xl: 1920px;
}
- Create a new service in
src/services/marketplace/
- Add marketplace configuration in
src/lib/constants.ts
- Update the marketplace selector components
- Add API proxy routes if needed
Extend the NFT type definition in src/types/
to include additional metadata fields specific to your use case.
-
Connect Repository:
# Push to GitHub git add . git commit -m "Initial commit" git push origin main
-
Deploy to Vercel:
- Visit vercel.com
- Import your GitHub repository
- Configure environment variables
- Deploy
-
Environment Variables in Vercel:
- Go to Project Settings β Environment Variables
- Add all variables from your
.env.local
- Redeploy the application
The application can be deployed to any platform that supports Next.js:
- Netlify: Use
@netlify/plugin-nextjs
- Railway: Direct deployment support
- DigitalOcean App Platform: Node.js application
- AWS Amplify: Full-stack deployment
- β API keys are stored server-side only
- β All external requests go through proxy routes
- β No sensitive data exposed to client
- β No private keys stored or transmitted
- β All transactions require user signature
- β Read-only access to wallet data
- β Input validation on all API routes
- β TypeScript for compile-time safety
- β Error boundaries for graceful failures
We welcome contributions from the community! Here's how to get started:
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature
- Make your changes
- Test thoroughly
- Submit a pull request
- Follow TypeScript best practices
- Use ESLint configuration provided
- Write meaningful commit messages
- Add tests for new features
- Update documentation as needed
- Use GitHub Issues for bug reports
- Provide detailed reproduction steps
- Include environment information
- Add screenshots for UI issues
This project is open-source and available under the MIT License.
- Web3Market Team - Original development and maintenance
- NFTGo - Comprehensive NFT data API
- Moralis - Web3 development platform
- RainbowKit - Wallet connection infrastructure
- Next.js Team - Amazing React framework
- Website: web3market.site
- Issues: GitHub Issues
- Discussions: GitHub Discussions
Built with β€οΈ by the Web3Market Team
This boilerplate is designed to accelerate NFT application development with production-ready features and best practices.