π Deployment on Vercel
This guide explains how to deploy Nextall (Backend + Frontend) on Vercel.
Your project structure looks like this:
Deployment happens in two steps:
- Deploy Backend (nextall-be)
- Deploy Frontend (nextall-fe) using backend URL as
BASE_URLin production environment.
1. Deploy Backend (nextall-be)
The backend is a Node.js + Express application.
Steps:
- Push your
nextall-befolder to a separate GitHub repository (e.g.,nextall-be). - Go to Vercel Dashboardβ.
- Create a New Project β Import the
nextall-berepository. - Set Environment Variables in Vercel:
- Go to Settings β Environment Variables
- Add variables from your
.env.productionfile (refer to Installation docs).
- Go to Settings β General:
- Change Build & Output Settings β Node.js Server
- Ensure the backend uses
vercel.jsonwith:
{
"version": 2,
"builds": [{ "src": "server.js", "use": "@vercel/node" }],
"routes": [{ "src": "/(.*)", "dest": "server.js" }]
}- Deploy β Vercel will provide you with a backend URL like: (https://nextall-backend.vercel.appβ)
2. Deploy Frontend (nextall-fe)
The frontend is a Next.js app.
Steps:
- Push your
nextall-befolder to a separate GitHub repository (e.g.,nextall-be). - Go to Vercel Dashboardβ.
- Create a New Project β Import the
nextall-berepository. - Set Environment Variables in Vercel:
- Go to Settings β Environment Variables
- Add variables from your
.env.productionfile (refer to Installation docs).
- Deploy β Vercel will provide you with a Fronted URL like: (https://nextall-front-end.vercel.appβ)
You have successfully deployed Nextall on Vercel. π
- Backend (nextall-be) is live and serving API requests.
- Frontend (nextall-fe) is connected to your backend and accessible via your Vercel domain.
Now you can start exploring your marketplace, onboard vendors, and let users shop seamlessly! ποΈ
Last updated on