Kick off a software project quickly.

Next.js Stack

Next.js Stack — Node.js LTS, PM2, Nginx and PostgreSQL preconfigured. Deploy your React SSR app to production without Vercel.

2 GB RAM 1 vCPU Available

Tech stack

Node.js LTSPM2NginxPostgreSQL
Minimum RAM2 GB
Minimum CPU1 vCPU
Compatible OSChoice of Linux distributions

Next.js Stack provisions your VPS with everything a Next.js application needs in production: Node.js LTS installed from the official NodeSource repository, PM2 for zero-downtime process management, Nginx as the TLS-terminating reverse proxy, and PostgreSQL for any data model your app requires. No external platform, no per-invocation billing, no 10-second function timeout.

Next.js standalone output (`output: 'standalone'` in `next.config.js`) produces a self-contained bundle with only the runtime dependencies it needs — copy it to the server and start it with PM2. SSR, ISR, and API routes all run on your infrastructure, at a fixed cost, with full disk access for the persistent ISR cache between deploys.

Key features

Node.js LTS from the official NodeSource repository — the current LTS release, not the outdated distro package.
PM2 process manager — zero-downtime reloads, log rotation, startup scripts, and cluster mode for multi-core VPS.
Nginx reverse proxy with gzip compression and static asset caching for /_next/static/.
PostgreSQL for full-stack Next.js apps that need a relational database.
Compatible with Next.js App Router, Pages Router, and standalone output.
ISR (incremental static regeneration) persisted to disk between deploys.

When to use this solution?

1

SSR marketing site

A Next.js application with full SSR for optimal Core Web Vitals and SEO — without Vercel's per-invocation billing.

2

Full-stack application

Next.js with App Router API routes + PostgreSQL — a backend and frontend on the same VPS at a fixed monthly cost.

3

Agency multi-site

Several Next.js client sites pooled under a single Nginx instance, each on its own subdomain with automated SSL.

Deploy Next.js Stack on your VPS

Guide optimized for ServOrbit Cloud VPS.

01

Create the VPS

Select the "Next.js Stack" template. Minimum 2 GB RAM — the Next.js production build is memory-intensive.

02

Clone and build your app

SSH in, clone your repository, create .env.production, run npm ci && npm run build. Enable output: 'standalone' in next.config.js for a lightweight deployment bundle.

03

First access

This template installs a toolchain (Node.js LTS, PM2, Nginx, PostgreSQL). There is no web interface to open — connect via SSH and deploy your own Next.js application.

04

Start with PM2

Launch with pm2 start node --name nextjs -- .next/standalone/server.js. Save the process list with pm2 save && pm2 startup for automatic restart on reboot.

05

Configure Nginx and SSL

Point the Nginx virtualhost to proxy_pass http://localhost:3000, serve /_next/static/ directly from disk, and obtain a Let's Encrypt certificate with Certbot.

Frequently asked questions

Next.js Stack is for React applications (Next.js), while Nuxt Stack targets Vue.js applications (Nuxt 3). The toolchain is identical — Node.js LTS, PM2, Nginx, PostgreSQL — but the frameworks and their build outputs differ.

Embed the deploy button

Maintaining a project that uses Next.js Stack? This button lets your readers deploy it on a VPS in one click, without reading Docker documentation.

Deploy Next.js Stack on ServOrbit
Markdown
[![Deploy Next.js Stack on ServOrbit](https://servorbit.com/brand/deploy/button.svg)](https://servorbit.com/vps-cloud?template=nextjs-stack&utm_source=deploy-badge&utm_medium=referral&utm_campaign=nextjs-stack)
HTML
<a href="https://servorbit.com/vps-cloud?template=nextjs-stack&utm_source=deploy-badge&utm_medium=referral&utm_campaign=nextjs-stack"><img src="https://servorbit.com/brand/deploy/button.svg" alt="Deploy Next.js Stack on ServOrbit" height="40"></a>

The button points to a VPS order with the template preselected. The image is served from servorbit.com — nothing to host on your side.

Kick off a software project quickly.

Activate Next.js Stack on your infrastructure.

Dedicated Cloud VPS — IPv4 included, European datacenter, support included. Your data never leaves your server.

Recommended configuration: 2 GB RAM · 1 vCPU

Need help?

Browse our help center and FAQ, or reach our team — callback, WhatsApp or email. Support in French, English and Arabic.