{"post":{"slug":"how-to-deploy-nextjs-2026","title":"How to deploy Next.js in 2026: Vercel vs Cloudflare vs self-host","excerpt":"A 2026 guide to deploying Next.js. Vercel, Cloudflare, AWS, and self-host compared on performance, price, and pain.","category":"code","date":"January 21, 2026","author":"ByteLedger Team","content":"<span class=\"dropcap\">D</span>eploying Next.js used to mean Vercel or pain. In 2026, Cloudflare Workers, OpenNext adapters, and mature Docker images mean you have real choices. The right one depends on your traffic shape, your budget, and how much you want to think about infrastructure.\n\nThis guide picks the right deployment for your Next.js app, with honest notes on the catches at each tier.\n\n## What changed in 2026\n\nThe Next.js deployment story finally got competitive.\n\n- **OpenNext is mature.** The community-built adapter layer makes Next.js run cleanly on Cloudflare, AWS, and standalone Node servers.\n- **Cloudflare Workers handle full Next.js apps.** Server Components, Server Actions, and image optimization all work on Cloudflare's runtime.\n- **Vercel pricing got predictable.** New tiers and bandwidth pricing made costs more transparent than the early \"you got DDoS'd, pay us\" era.\n\n## How we picked\n\n- **Real cost** at three traffic tiers — hobby, growing, established.\n- **Cold start performance** on edge runtimes.\n- **Deployment friction** including CI setup and rollback.\n- **Observability** — what you can see when things break.\n- **Vendor lock-in** — what costs to leave.\n\n## 1. Vercel — easiest path\n\nVercel is the path of least resistance. `git push` deploys, preview URLs work out of the box, and every feature in Next.js is supported by definition. Image optimization, ISR, edge functions, and Server Actions all work without configuration. For a team that wants to ship product, not configure infrastructure, this is still the right choice.\n\nThe trade is predictable cost only up to a point. Bandwidth-heavy apps hit serious bills. The pricing changes in 2025 helped, but Vercel is still the most expensive way to run Next.js at scale.\n\n## 2. Cloudflare Workers — best edge performance\n\nCloudflare Workers run Next.js apps via the OpenNext adapter, and the experience in 2026 is genuinely good. Cold starts are sub-50ms globally, the free tier covers small projects entirely, and bandwidth is unmetered. Workers KV, D1, R2, and Durable Objects give you a complete platform without leaving Cloudflare.\n\nThe catches: not every Next.js feature works identically — image optimization in particular requires a Cloudflare Images integration, and some npm packages depending on Node-specific APIs need workarounds.\n\n## 3. Self-host on a VPS — cheapest at scale\n\nFor predictable workloads, a $20/month VPS running Next.js in Docker behind Caddy or Nginx is cheaper than any platform. Standalone output mode keeps the image small, and a simple GitHub Actions workflow can deploy in under 30 seconds. Tools like Coolify or Dokploy give you a Heroku-like experience over your own VPS.\n\nThe trade is real ops cost. You handle backups, security updates, monitoring, and scaling. For a side project, this is fine. For a production app with no on-call rotation, this is risky.\n\n## 4. AWS, Railway, Fly, Render — the middle ground\n\nRailway, Fly.io, and Render all run Next.js cleanly with auto-deploys and managed databases. Costs sit between Vercel and self-host. AWS via SST or OpenNext works but is more complex than the alternatives — only worth it if you are already deep in AWS.\n\n## Comparison: Next.js deployment in April 2026\n\n| Platform | Best for | Free tier | Pain level |\n| --- | --- | --- | --- |\n| Vercel | Most teams | Hobby | None |\n| Cloudflare Workers | Edge performance, low cost | Generous | Low |\n| Railway / Fly / Render | Mid-scale | Limited | Low |\n| Self-hosted VPS | Cost at scale | N/A | Medium |\n| AWS (OpenNext / SST) | Existing AWS shops | Free tier | High |\n\n## Common mistakes to avoid\n\n**Premature self-hosting.** A side project does not need a VPS. Use Vercel or Cloudflare's free tier until you have real users.\n\n**Ignoring bandwidth pricing.** Vercel and AWS charge for bandwidth in ways that surprise people. Estimate your traffic and check the calculator before committing.\n\n**Not testing rollback.** Every deployment platform handles rollback differently. Practice it before you need it at 3am.\n\n## FAQ\n\n**Should I use the Pages Router or App Router on Cloudflare?**\nBoth work via OpenNext. App Router with Server Components is the future and is well-supported on Cloudflare in 2026.\n\n**What about Edge Runtime vs Node Runtime?**\nEdge Runtime is faster cold-start but limits which npm packages you can use. Node Runtime is more flexible. Most apps benefit from a mix.\n\n**Is the Next.js Standalone build worth using?**\nYes, for self-hosted deploys. It produces a much smaller Docker image with only the dependencies you actually use.\n\n## Where to go next\n\nFor related guides see [Best web hosting for developers in 2026](/blog/best-web-hosting-developers-2026), [Best monitoring tools for SaaS in 2026](/blog/best-monitoring-tools-saas-2026), and [Cost of running a side project in 2026](/blog/cost-of-running-a-side-project-2026).","hue":310,"metaTitle":"How to Deploy Next.js in 2026: Vercel vs Cloudflare vs VPS","metaDescription":"Vercel, Cloudflare Workers, and self-host compared for Next.js in 2026. The right deployment for your app and budget.","keywords":["how to deploy nextjs 2026","nextjs on cloudflare","vercel vs cloudflare","self host nextjs","nextjs deployment guide","nextjs aws","nextjs docker","nextjs vps","nextjs serverless","deploy nextjs cheap"],"tldr":["**Vercel** — easiest experience, predictable pricing for small to medium apps.","**Cloudflare** — best edge performance and the most generous free tier.","**Self-host on a VPS** — cheapest at scale, real ops cost.","**Skip:** custom AWS Lambda setups for Next.js — it is more pain than payoff."],"readTime":"4 min read","wordCount":786},"related":[{"slug":"how-to-deploy-a-web-app-2026","title":"How to deploy a web app in 2026: from local to live in the right way","excerpt":"Deploying a web app in 2026 is faster than ever, but the choices are overwhelming. Here is the clear path from working locally to running reliably in production.","category":"code","date":"April 15, 2026","author":"ByteLedger Team","readTime":"4 min read","hue":321},{"slug":"how-to-deploy-fullstack-app-2026","title":"How to deploy a full-stack app in 2026: Vercel, Fly.io, Railway, and the realistic paths","excerpt":"The deployment landscape simplified in 2026. Here are the four realistic paths — Vercel, Fly.io, Railway, Cloudflare — and which one fits your stack, traffic, and team.","category":"code","date":"February 11, 2026","author":"ByteLedger Team","readTime":"3 min read","hue":145},{"slug":"how-to-deploy-a-react-app-2026","title":"How to Deploy a React App in 2026: a step-by-step guide","excerpt":"The fastest way to deploy a React app in 2026 is to build it and push it to a static host that runs the build for you. Here are the exact steps and common pitfalls.","category":"code","date":"May 6, 2026","author":"ByteLedger Team","readTime":"3 min read","hue":212}],"sameCategory":[{"slug":"bazel-build-explained-2026","title":"Bazel Explained: What Hermetic Builds Actually Cost","excerpt":"Bazel delivers reproducible, precisely cached builds and demands that you describe everything. Here is what you get, what it costs, and who should say no.","category":"code","date":"August 19, 2026","author":"ByteLedger Team","readTime":"3 min read","hue":145},{"slug":"graphql-federation-2026","title":"GraphQL Federation: One Graph, Many Teams","excerpt":"Federation composes independently-owned subgraphs into a single API. Here is what it solves, the operational cost it adds, and when a simpler gateway is enough.","category":"code","date":"August 19, 2026","author":"ByteLedger Team","readTime":"3 min read","hue":300},{"slug":"hermetic-builds-explained-2026","title":"Hermetic Builds Explained: Same Inputs, Same Output","excerpt":"A hermetic build depends only on declared inputs. Here is what that property gives you, the common leaks that break it, and how to move toward it incrementally.","category":"code","date":"August 19, 2026","author":"ByteLedger Team","readTime":"3 min read","hue":130},{"slug":"monorepo-tooling-compared-2026","title":"Monorepo Tooling Compared: What You Actually Need","excerpt":"Monorepo tools solve task orchestration and caching, not repository layout. Here is what each tier provides and how to tell when you have outgrown the simple option.","category":"code","date":"August 19, 2026","author":"ByteLedger Team","readTime":"3 min read","hue":150}],"newer":{"slug":"emergency-fund-guide-2026","title":"Emergency fund guide 2026: how much, where to keep it, and how to build it","excerpt":"An emergency fund is the single most underrated financial tool in 2026. Here is the no-nonsense guide to how much you actually need, the right account to keep it in, and a 12-month plan to build it from scratch.","category":"finance","date":"January 21, 2026","author":"ByteLedger Team","readTime":"5 min read","hue":290},"older":{"slug":"how-to-negotiate-medical-bills-2026","title":"How to negotiate medical bills in 2026: a step-by-step playbook","excerpt":"A surprising amount of every US medical bill is negotiable. Here is the step-by-step playbook for getting your bill cut 30–80% in 2026 — including the script that works on hospital billing departments.","category":"finance","date":"January 21, 2026","author":"ByteLedger Team","readTime":"5 min read","hue":285}}