---
title: Install the JavaScript (Node) SDK prior to v6
slug: feature-experimentation/docs/install-sdk-javascript-node-prior-to-v6
docTags: 
createdAt: 2026-08-05T20:39:50.000Z
---

The JavaScript (Node) SDK is distributed through [npm](https://www.npmjs.com/package/@optimizely/optimizely-sdk):

Using `npm`:

```shell
npm install --save @optimizely/optimizely-sdk
```

Using `yarn`:

```shell
yarn add @optimizely/optimizely-sdk
```

Using `pnpm`:

```shell
pnpm add @optimizely/optimizely-sdk
```

Using `deno` (no installation required):

```shell
import optimizely from "npm:@optimizely/optimizely-sdk"
```

The full JavaScript SDK source code is available on [GitHub](https://github.com/optimizely/javascript-sdk/tree/master).

## Requirements

The JavaScript (Node) SDK requires Node version 8.0+.

The following peer dependencies may be required for use in production:

```json
{  
  "json-schema@0.4.0": {  
    "licenses": [  
      "AFLv2.1",  
      "BSD"  
    ],  
    "publisher": "Kris Zyp",  
    "repository": "<https://github.com/kriszyp/json-schema>"  
  },  
  "murmurhash@2.0.1": {  
    "licenses": "MIT\*",  
    "repository": "<https://github.com/perezd/node-murmurhash>"  
  },  
  "uuid@8.3.2": {  
    "licenses": "MIT",  
    "repository": "<https://github.com/kelektiv/node-uuid>"  
  },  
  "decompress-response@4.2.1": {  
    "licenses": "MIT",  
    "repository": "<https://github.com/sindresorhus/decompress-response>"  
  }  
}
```

To regenerate this, run the following command:

```javascript
npx license-checker --production --json | jq 'map_values({ licenses, publisher, repository }) | del(.[][] | nulls)'
```

and remove the self (@optimizely/optimizely-sdk) entry.

:::hint{type="info"}
**Note**
The `jq` command-line JSON processor is required to run the above script. You may install `jq` to your environment by using [Homebrew on MacOS](https://formulae.brew.sh/formula/jq) using the command `brew install jq`. For Windows users, visit the [jq GitHub repository](https://github.com/stedolan/jq) to learn more.
:::

## Next

After installing, you need to [initialize the SDK](docId\:nHER9yNaUuV3aw35WcbhJ).
