---
title: Installation
description: Install and initialize the EmitKit JavaScript package.
sidebar:
  order: 1
---

Install `@emitkit/js` with your package manager:

```bash
pnpm add @emitkit/js
```

Initialize it with a server-side API key:

```typescript
import { EmitKit } from '@emitkit/js';

const client = new EmitKit(process.env.EMITKIT_API_KEY!);
```

The client defaults to `https://api.emitkit.com`. See the
[TypeScript guide](/sdk/typescript) for the first event.
