# How to set the Node.js version

Each application chooses its own **Node.js major version**. Set it when you deploy an app, or when
you move an existing app to a newer runtime.

## Set it in the GUI

1. Open the host and select the application.
2. Go to **Configure application > Technologies > NodeJS**.
3. Choose the version.

![The NodeJS panel on an application's Technologies tab, enabled, with the version selector that accepts a main version or a subversion|1000](../../assets/screenshots/technologies/nodejs.png)

## Set it in YAML

Set `nodejs_version` on the application (vhost) to the major version, as a quoted string. This key
on its own installs the runtime. See [Configure Node.js](configure.md) for the full set of keys.

```yaml
nodejs_version: "24"
```

[Publish](../../platform/hosts/publishing.md) the change to apply it.

## Verify and restart

Over [SSH](../../platform/hosts/ssh.md), confirm the runtime:

```bash
node -v
```

Then **restart your application** so it runs on the new version - see
[Keep a Node.js app running](run-with-process-manager.md). Long-running Node processes keep using the
old runtime until they are restarted.

> [!TIP]
> Match the version to your app's `engines` field in `package.json`, and test on a staging copy before
> switching a production site.

## Related

- [Configure Node.js](configure.md)
- [Keep a Node.js app running](run-with-process-manager.md)
- [Publishing changes](../../platform/hosts/publishing.md)
- [What is Node.js?](what-is.md)
- [Deploy Medusa](../../applications/medusa/deploy.md)
