Next.js hosting
Deploy Next.js and Node.js applications on OpenHost — Git-push deploys, environment variables, logs, and zero-downtime updates.
Next.js plans run your application in an isolated container with a managed reverse proxy. You push code, we build and serve it — with automatic SSL, environment variable management, and live logs.
What's included
| Feature | Details |
|---|---|
| Git-push deploy | Connect a repo, every push builds and deploys |
| Node.js LTS | Currently Node 20/22, configurable |
| NVMe storage | 8–50 GB depending on plan |
| Reverse proxy | Automatic HTTPS termination and routing |
| Environment variables | Stored encrypted, injected at build and runtime |
| Build + runtime logs | Streaming in the panel |
| Zero-downtime deploy | New build serves only after health check passes (Plus+) |
| Daily backups | Off-site snapshots of app state |
| CDN | Global edge caching for static assets |
Plans
| Plan | Traffic/mo | Concurrent requests | vCPU | RAM | Storage |
|---|---|---|---|---|---|
| JS Start | 50 GB | ~100 | 1 | 1 GB | 8 GB |
| JS Hobby | 100 GB | ~200 | 1 | 1 GB | 10 GB |
| JS Plus | 500 GB | ~500 | 2 | 2 GB | 20 GB |
| JS Pro | 1 TB | ~800 | 4 | 4 GB | 30 GB |
| JS Max | 2 TB | ~1500 | 6 | 6 GB | 50 GB |
Deploy your app
Create a Next.js site
Panel → Websites → Create website → Node.js application. Assign your domain or use the preview URL.
Connect Git
In the site settings → Git → Connect repository. Authenticate with GitHub, GitLab, or Gitea. Select the repository and branch.
Configure build
Set your build commands (defaults work for most Next.js apps):
Command Default Override if needed Install npm installpnpm install,yarn installBuild npm run buildpnpm build, custom scriptStart npm startnode server.js, etc.Set environment variables
Panel → Environment variables → Add:
- Variables are injected at both build time and runtime
- Mark sensitive values as Secret (hidden from logs)
- Changes trigger a clean rebuild
Deploy
Push to your connected branch. The panel shows build logs in real time. Once the build succeeds and the health check passes, traffic routes to the new version.
Environment variables
Manage secrets without committing them to your repo:
DATABASE_URL— database connection stringNEXT_PUBLIC_*— client-side variables (exposed to browser)API_KEY,JWT_SECRET— server-only secretsNODE_ENV— automatically set toproduction
Variables are encrypted at rest. Changes trigger a rebuild unless you explicitly skip it.
Logs
Build logs
Streaming during deploy: Panel → your site → Deployments → click a deploy. Shows install, build, and start phases.
Runtime logs
Panel → your site → Logs. Shows stdout and stderr from your running application. Useful for debugging API errors, uncaught exceptions, and slow requests.
Zero-downtime deploys (Plus+)
On Plus tier and above:
- New build starts in a separate container
- Health check verifies the new version responds
- Traffic seamlessly shifts to the new container
- Old container is removed
Your users never see downtime during deploys.
Custom domains
- Add your domain in Panel → your site → Domains
- Point DNS (A record to server IP, or CNAME if using Cloudflare)
- SSL certificate issues automatically
Multiple domains can point to the same app (e.g. app.yourdomain.com and yourdomain.com).
Databases
Next.js plans don't include a managed database, but you can:
- Connect external databases (Supabase, PlanetScale, Neon, your own Postgres)
- Install a database on a VPS plan and connect via
DATABASE_URL - Use Coolify on an App Platform plan for one-click Postgres/Redis
Static export mode
If your Next.js app uses output: "export" (static HTML):
- The build produces static files
- They're served directly from the CDN edge
- No Node.js process runs at runtime
- Fastest possible serving, lowest cost
Troubleshooting
| Issue | Fix |
|---|---|
| Build fails with "module not found" | Check dependencies are in package.json (not devDependencies if needed at build) |
ENOSPC during build | Storage full — increase plan or clean build cache |
| App crashes immediately | Check runtime logs; common: missing env var, wrong start command |
| 502 after deploy | App not listening on the correct port; check your start script binds to 0.0.0.0:$PORT |
| Slow cold starts | Reduce bundle size; use standalone output mode for smaller deploys |
Best practices
- Use
output: 'standalone'innext.config.jsfor smaller deployment artifacts - Set
NEXT_TELEMETRY_DISABLED=1to skip telemetry - Cache API responses at the route level with Next.js cache headers
- Keep
node_modulesout of git (we install from lockfile) - Use ISR (Incremental Static Regeneration) for pages that change occasionally
Related docs
- Custom domain guide
- SSL certificates
- VPS hosting — for apps needing root access
- Coolify — self-hosted PaaS alternative