How do I add a custom domain on Vercel or Netlify?
Buy a domain, add a CNAME record in your DNS settings pointing to your Vercel/Netlify URL, then add the domain in the platform dashboard. SSL is automatically provisioned by the platform.
Verify This Answer
Cross-check this information using these trusted sources:
More FAQs in Deploying the DevTinder Frontend to Vercel or Netlify Static Hosting for React Apps
Vercel and Netlify provide a global CDN for fast loading, free automatic SSL, git push to deploy, preview deployments for every PR, and build optimization. EC2 requires manual setup for all of these.
Install vercel CLI (npm install -g vercel), run npm run build in the frontend, then run vercel. Follow the prompts for project name, framework preset, build command, and output directory. Set environment variables with vercel env add, then deploy to production with vercel --prod.
Set VITE_API_URL to the backend domain (https://api.yourdomain.com/api) and VITE_SOCKET_URL to the backend domain in the frontend environment variables. Update the backend CORS to allow the frontend origin with credentials: true.
Still have questions?
Browse all our FAQs or reach out to our support team
