Deploy a Node.js App¶
This guide walks you through deploying a Node.js application — built with Express, Fastify, Koa, or any other framework — to your own server using Appliku.
Prerequisites¶
Before you begin, make sure you have:
- A Node.js application with a
package.jsonin the root of the repository - Your code pushed to a GitHub or GitLab repository
- An Appliku account with at least one server set up
Tip
If you are deploying a Next.js application specifically, see the dedicated Deploy Next.js guide instead.
Step 1: Create an Application from GitHub¶
Go to the Applications page in your Appliku dashboard and click + Add Application.
Select GitHub (or GitLab) as the source, then fill in the form:
- Application name — a descriptive name for your app
- Repository — select your Node.js repository
- Branch — the branch to deploy from (e.g.,
mainormaster) - Server — the server to deploy to
Click Create Application.
Step 2: Select the Node.js Build Image¶
On the application overview page, go to Settings and open the Build Settings tab.
Change the Base Docker Image to one of the Node.js options (e.g., Node 25 NPM or Node 20 Yarn). Pick the version that matches your project. For new projects, Node 25 NPM is recommended.
Step 3: Set the Build Command¶
In the same Build Settings tab, set the Build Command to install dependencies and build your project:
If your project does not have a build step, you can use just:
If you use Yarn, set the build command to:
Click Save Changes.
Step 4: Set the Container Port¶
Appliku routes HTTP traffic to your web process container. By default it expects port 8000, but most Node.js apps listen on port 3000 or 8080.
Go to the Build Settings tab and set the Container Port to match the port your application listens on (e.g., 3000).
Note
Make sure your application reads the port from the PORT environment variable if one is set, and falls back to a default. For example:
Step 5: Add a Web Process¶
Go to the Processes tab and add a process:
- Name:
web - Command:
npm startornode server.js(whichever starts your application)
The web process is special — it is the process that receives HTTP traffic through Nginx.
If your package.json has a start script defined, npm start is the simplest option:
Click Save and Deploy.
Step 6: Deploy¶
Appliku will build your Docker image, install dependencies, run the build command, and start the web process. You can monitor the build progress on the application overview page.
Once deployed, click View Application to open your app in the browser.
Tips¶
Use the PORT Environment Variable¶
Always bind your server to 0.0.0.0 and read the port from the PORT environment variable. This ensures Appliku can route traffic correctly:
Run in Production Mode¶
Set the NODE_ENV environment variable to production in the Environment Variables tab. Most frameworks optimize performance and disable development features when this is set:
Health Checks¶
If your application has a health check endpoint (e.g., /health), Appliku will use it to verify your app is running before routing traffic to it.
Adding a Database¶
If your application needs a database, scroll down on the application overview page and click Add Database to provision PostgreSQL, MySQL, or Redis on the same server. The connection URL will be automatically added to your environment variables.
Related Guides¶
- Processes — learn more about process types and configuration
- Environment Variables — managing secrets and configuration
- Build Settings — build image, build command, and container port options