Part 1 - Vercel to VPS

Published: (January 18, 2026 at 01:19 PM EST)
2 min read
Source: Dev.to

Source: Dev.to

Cover image for Part 1 - Vercel to VPS

Vercel feels like magic. You push to Git, and suddenly your site is live and globally available—no servers, no configs, no stress.
But at some point you may decide to move out of Vercel, not because it’s bad or pricey, but because production means more than “it works”.

Why move from a managed platform to a VPS?

Managed platforms like Vercel and Netlify handle all the infrastructure setup so developers can ship faster, but a VPS gives you control.

  • Cost

    • Managed platforms are cheap at low traffic and expensive at scale.
    • A VPS has a fixed monthly cost, regardless of traffic patterns.
  • Infrastructure Control

    Managed platforms

    • No control over the server.
    • No control over process lifecycles.
    • No control over the network.

    VPS

    • Choose how requests flow.
    • Decide how apps restart.
    • Define how failures are handled.

We’re moving for the love of the game—to learn more about production systems.

Production setup on a VPS

Request flow

User → DNS → Nginx → Node / Next.js → PM2

User → DNS

When a user sends a request, the first stop is DNS (Domain Name System).

  • Translates a domain name into an IP address.
  • Allows IPs to change without breaking users.
  • Enables global routing and failover.

DNS → Nginx

After DNS resolves the domain, the request reaches your server and is handled by Nginx—the front door of your application.

  • Handles incoming HTTP/HTTPS traffic.
  • Manages TLS certificates (HTTPS).
  • Performs request routing, rate limiting, and static asset delivery.
  • Acts as a reverse proxy, protecting your Node process from direct exposure.

Nginx → Node / Next.js

Nginx forwards the request to your Node.js / Next.js application via a reverse proxy.

  • Routing and rendering.
  • API logic and data fetching.
  • Authentication logic.

Node / Next.js → PM2

Your application is managed by a process manager such as PM2.

  • Restarts the app if it crashes.
  • Allows multiple instances to run.
  • Captures logs.
  • Prevents memory leaks from silently killing production.

Without a process manager, a single crash or uncaught exception would cause downtime.

TL;DR

  • PM2 protects Node.
  • Nginx protects your app.
  • DNS protects your server.
  • The VPS hosts them all.

You can also check out my article on Test-Driven Development (TDD) on my blog. Give it a read.

Back to Blog

Related posts

Read more »

Rapg: TUI-based Secret Manager

We've all been there. You join a new project, and the first thing you hear is: > 'Check the pinned message in Slack for the .env file.' Or you have several .env...

Technology is an Enabler, not a Saviour

Why clarity of thinking matters more than the tools you use Technology is often treated as a magic switch—flip it on, and everything improves. New software, pl...