How to deploy a React app to the internet in 2026 (without losing your weekend)
TL;DR — Modern React deployment is six steps: pick a host (Vercel, Netlify, Cloudflare Pages, or a VPS), commit your code to GitHub, connect the repo to the host, configure the build command, point a domain at it, and let the platform auto-provision SSL. Total time: 20 minutes for the first deploy, two minutes for every subsequent push. This article walks through each step, compares the four main hosts, and ends with the case for skipping the whole thing if you don't need to ship a custom React app.
Deploying a React app used to mean Apache configs, SSH keys, and a Friday-night SSL renewal that broke everything. In 2026, the entire pipeline collapses into six clicks if you're willing to use a managed platform — and the platforms have generous enough free tiers that almost nobody starts on bare infrastructure anymore.
This article walks through deploying a Vite-built or Next.js React app from local dev to a custom domain with HTTPS. We'll cover the four main hosts, when to pick each, and what to do when something inevitably fails on the first try.
Step 1 — Pick a host
Four serious options in 2026, ordered by typical use case:
Vercel (recommended for Next.js)
Best for: Next.js apps. Built by the Next team; the integration is tighter than anyone else can match.
Free tier: hobby projects, 100 GB bandwidth/mo, unlimited deploys.
Paid: $20/mo Pro for production traffic + team collaboration.
Strength: zero-config Next.js, Edge Functions, automatic image optimisation, preview deploys for every PR.
Watch-out: pricing scales with bandwidth + serverless invocations. Heavy data-fetch sites can surprise you on the bill.
Netlify
Best for: Vite, CRA, generic static sites, JAMstack architectures.
Free tier: 100 GB bandwidth/mo, 300 build minutes/mo.
Paid: $19/mo Pro tier.
Strength: flexible build pipeline, great form handling, Netlify Functions for server logic.
Watch-out: cold-start times on Netlify Functions are slower than Vercel Edge Functions.
Cloudflare Pages
Best for: static sites with global CDN priorities. Or apps using Workers for server logic.
Free tier: unlimited bandwidth, 500 builds/mo. Genuinely the best free tier of the four.
Paid: $20/mo Workers Paid plan unlocks more serverless invocations.
Strength: global Anycast network — your app loads fast from anywhere.
Watch-out: Workers Runtime is a subset of Node — some npm packages don't work. Test before committing.
A VPS (DigitalOcean, Hetzner, OVH)
Best for: specific needs the managed platforms can't meet — long-running processes, custom backends, regulatory locality.
Cost: $4-12/mo for a small droplet.
Strength: full control, no vendor lock-in.
Watch-out: you own EVERYTHING — SSL renewal, Nginx config, security patches, log rotation. The TCO of "$4/mo" is closer to four hours per month of fiddling. Don't pick this if you'd rather ship features.
Step 2 — Push your code to GitHub
All four platforms deploy by watching a Git repo. If your code isn't in GitHub (or GitLab / Bitbucket — most platforms support all three), put it there first.
cd your-react-app
git init
git add .
git commit -m "initial commit"
gh repo create my-app --public --source=. --pushStep 3 — Connect the repo to your host
On your chosen host (using Vercel as the example):
Sign in with GitHub.
Click New Project.
Select your repo from the list. Vercel auto-detects the framework — Next.js, Vite, CRA, Remix, all get the right defaults.
Click Deploy.
The first build runs immediately. For a freshly-bootstrapped Next.js app, that's about 90 seconds. Vercel publishes the result at a random URL like my-app-abc123.vercel.app. Open it — your app is live.
Step 4 — Configure the build (if needed)
Most apps just work with auto-detected defaults. The handful that don't:
Monorepo: set the Root Directory to the subfolder containing your React app.
Custom build command: override if your package.json's build script isn't `npm run build`.
Output directory: override if your build emits somewhere other than `dist/` (Vite) or `.next/` (Next).
Node version: pin in your platform settings or via a `.nvmrc` file. Don't rely on the platform default.
Environment variables: add your API keys + secrets via the platform UI. Never commit them.
Step 5 — Point a custom domain
Replace the random vercel.app URL with your real domain:
Vercel: Settings → Domains → Add. Type your domain.
Vercel shows the DNS records to add — an A record for apex, a CNAME for subdomain.
Add the records at your domain registrar (Namecheap, GoDaddy, Cloudflare, etc.).
Wait 10-30 minutes for DNS propagation.
Vercel verifies the domain and provisions SSL automatically via Let's Encrypt.
Same pattern on Netlify, Cloudflare Pages, and a VPS — except a VPS makes you handle SSL with certbot + cron, which is exactly the kind of thing managed platforms remove from your life.
Step 6 — Watch the auto-deploys
From here on, every git push kicks off a fresh build. Vercel + Netlify + Cloudflare Pages all spin up a build container, run your build command, push the output to their CDN, and update your domain — usually 60-120 seconds end to end. They also deploy a preview URL for every pull request, so you can sanity-check changes before merging.
Things that will trip you up
Build works locally, fails in CI
Almost always a Node version mismatch. Add an `.nvmrc` file with the same version you run locally:
20.18.0And configure the platform to honour it (Vercel does this automatically; Netlify needs `NODE_VERSION` env).
SSL doesn't provision
DNS not propagated yet. Wait 30 minutes and retry. If it still fails, check that your CNAME / A record points at the platform's documented target (not at a random IP from a stale Stack Overflow answer).
Site shows the platform's default 404 page
You connected the domain but didn't deploy yet. Push something to main.
Deploy succeeds but the site shows the OLD content
CDN cache. Most platforms invalidate automatically on deploy; some need a manual purge. On Vercel, this is usually a browser cache — hard-refresh (Cmd+Shift+R).
Or skip all this
Everything above assumes you actually need a custom-coded React app. If your goal is a landing page, marketing site, blog, or simple multi-page brochure — you can have it live, on a custom domain, with HTTPS, in under five minutes using Pendro. No GitHub repo, no build config, no DNS-record copying. Type a sentence describing your business, edit the generated draft, click Publish.
Further reading
Each platform publishes solid first-deploy docs:
Build your site in Pendro.
Pick a template, edit live, hit publish. No code, no hosting setup, no surprises.
Stay close
More posts like this in your inbox.
Occasional updates — new posts, product changes, and notes on what we're learning. One email every couple of weeks, never more.
No spam, ever. Unsubscribe in one click.