This guide shows you how to install Node.js, Deno, and Bun on Windows. The steps described below must be performed via RDP. If you don’t know how to connect to your server via RDP, please check our First Access (RDP) guide.
First, you need to decide which JavaScript runtime you want to install. There are many online resources that describe each one in detail. But you can also read this guide, as it contains basic commands and code examples. We recommend Node.js, as it is one of the most widely used and popular options.
Open your favorite browser (I’m using Chrome for this guide) and go to https://nodejs.org/en
Click the Download Node.js (LTS) button and wait for the download to complete.
It is generally recommended to install the latest Long Term Support (LTS) version.
Start the installer by clicking it. You will be prompted to configure some installation settings. On the Welcome page, click Next.
Now you need to read and accept the Node.js license agreement (check the box), then click Next.
Next, you will be asked to choose an installation location for Node.js.
We recommend using the default installation path.
On the next page, you can choose whether to exclude some core Node.js packages from installation. For a normal installation, which is recommended, just click Next. You also have the option to install Chocolatey, but this is not necessary.
Now click Install and wait for everything to be set up. Be patient, this may take a while. :)
After completion, simply click Finish and you can start using Node.js on your server.
You can check the installed Node.js version with node -v. From time to time, you should verify if you are using the latest LTS version. To update Node.js, just follow the relevant section of this JavaScript Installation guide again.
npm is the official package manager for Node.js. It allows you to install packages from the internet.
You can find all npm packages on the official website.
Whenever you want to start a new Node.js project, create a new folder, open Command Prompt or PowerShell inside it, and run the command npm init to start the setup. You will be asked for some basic info to create a package.json file. This file is the "config" for Node.js.
On Windows, you can click the current path once in File Explorer, type cmd, and press Enter to open the command prompt directly in the current directory – super handy.
After initialization, create a new file named index.js and write code inside. As an example, we create a simple HTTP server on the standard port 80 that returns a test message when accessed via localhost. The code looks like this:
const http = require('http')
const server = http.createServer((req, res) => {
res.writeHead(200, { 'Content-Type': 'text/plain' })
res.end('Hello from ZAP-Hosting Docs =)')
})
server.listen(80)
Now you can run the code with node . and view the result in the browser at localhost:80.
Install external npm packages with npm install [package-name].
You can easily install Deno by running the command irm https://deno.land/install.ps1 | iex in PowerShell. Search for PowerShell in Windows, open it as administrator, and execute the command. Follow the instructions shown.
Check the installed version with deno --version.
Update Deno simply by running deno upgrade.
To start Deno, create a new file index.ts and write some code inside. As an example, we build a simple HTTP server on port 80 that returns a test message when accessed via localhost:
Deno.serve({ port: 80 }, (_req: Request) => {
return new Response('Hello from ZAP-Hosting Docs =)')
})
Run the code with deno run --allow-net index.ts and open localhost:80 in your browser to see the result.
Deno is designed with a focus on security and therefore requires specific permissions like --allow-net to access certain modules.
Bun also offers a very simple one-command installation but can also be installed via npm if you already use Node.js.
Run irm bun.sh/install.ps1|iex in PowerShell to install Bun on your server.
If you already have npm installed, you can also run npm install -g bun to install Bun.
Bun is designed to be faster than other JavaScript engines and has a similar structure to Node.js. Open an empty directory and run bun init in the command prompt.
Depending on the chosen language (JS or TS), Bun creates a configuration file (jsconfig.json or tsconfig.json).
To start Bun, create a new file index.ts and write code inside. As an example, we build a simple HTTP server on port 80 that returns a test message when accessed via localhost:
const server = Bun.serve({
port: 80,
fetch(req) {
return new Response('Hello from ZAP-Hosting Docs =)')
},
})
Run the code with bun index.ts and open localhost:80 in your browser to see the result.