Setup Steps
1. Install Vercel CLI:
npm install -g vercel2. Login:
vercel login3. Deploy your project:
cd project-directory
vercel4. Answer questions on first deploy (project name, framework, settings)
5. Production deploy:
vercel --prod6. Add environment variables:
vercel env add VARIABLE_NAME7. GitHub integration:
- Connect your GitHub repo at https://vercel.com/new
- Auto-deploy on every push
8. Add custom domain:
vercel domains add mysite.com9. vercel.json configuration:
{
"buildCommand": "npm run build",
"outputDirectory": ".next",
"framework": "nextjs"
}10. Preview deployment: A preview URL is automatically created when you open a PR