---
title: "How to deploy a Next.js app on OnePloy"
description: "Step by step: deploy Next.js on OnePloy by connecting your repository, setting environment variables and adding a domain with automatic HTTPS."
url: https://oneploy.dev/deploy-nextjs-on-oneploy/
type: post
published: 2026-11-02T19:10:53+00:00
updated: 2026-11-02T19:10:53+00:00
author: "admin"
language: en-US
categories: ["Guides"]
---

# How to deploy a Next.js app on OnePloy

> Step by step: deploy Next.js on OnePloy by connecting your repository, setting environment variables and adding a domain with automatic HTTPS.

You can put a production Next.js app online with automatic HTTPS and push-to-deploy in about ten minutes. Here is the full path.

## What you need

- A free OnePloy account
- A Next.js app in a GitHub, GitLab or Bitbucket repository
- A domain whose DNS you can edit (optional for a first test)

## 1. Create a project

Sign in to OnePloy, create a project and choose where it should run: OnePloy Cloud or a server you have connected.

## 2. Add your app

Add a new application from your repository. Connect GitHub in a click, or use a deploy key for other Git hosts.

## 3. Let OnePloy build it

Leave the build settings on automatic. OnePloy detects Next.js, installs dependencies, runs the build and starts the server. If your app needs system packages, switch to a Dockerfile.

Make sure your start script listens on the port OnePloy expects:

```json
{
  "scripts": {
    "build": "next build",
    "start": "next start -p 3000"
  }
}
```

## 4. Set environment variables

Add runtime variables such as `DATABASE_URL`. Mark variables that Next.js needs at build time, such as anything prefixed `NEXT_PUBLIC_`, as build variables.

## 5. Add your domain

Point your domain at the address shown in the dashboard, then add it to the application. The HTTPS certificate is issued automatically.

## 6. Deploy

Click deploy and watch the build logs live. Every later push to your branch deploys automatically and only takes traffic once it is healthy.

**Note:** Add a health check path such as `/api/health` so each new version is verified before the old one stops.

---

Source: https://oneploy.dev/deploy-nextjs-on-oneploy/ · OnePloy
