Deploying Next.js on Plesk with zero downtime
A step-by-step guide to running modern Next.js apps on Plesk with Node.js, Passenger and a one-command deploy script.
Plesk is a fantastic control panel for teams who want a GUI plus the flexibility of Node.js. Here's how we deploy Next.js apps on it.
Enable Node.js
Install the Node.js extension, select the latest LTS version and set the application root and startup file to server.js.
Environment variables
Add DATABASE_URL, AUTH_SECRET and NEXT_PUBLIC_SITE_URL in the Node.js panel or in a .env file outside the web root.
One-command deploys
Our deploy.sh script pulls the latest code, installs dependencies, runs database migrations, builds the app and restarts Passenger:
./deploy.sh
Keep it fast
Enable HTTP/2 and Brotli in Plesk, add a CDN in front and let Next.js handle caching headers. That's it — production-grade hosting with a friendly panel.