# Installation

Install the adapter for your framework with your preferred package manager:

```sh
npm i @tanstack/react-hotkeys
```

Every framework adapter re-exports the core `@tanstack/hotkeys` package, so you don't need to install both.

> [!NOTE]
> Not using a framework? Install `@tanstack/hotkeys` directly for vanilla JavaScript or TypeScript.

Requires React 18 or newer. `useHotkey` is a client hook and `HotkeysProvider` is a client component, so server components like Next.js `app/layout.tsx` can render `HotkeysProvider` directly. To pass `appHotkeys` from a Server Component, use `AppHotkeysProvider` instead. See [App hotkeys with Server Components](./framework/react/guides/ssr#app-hotkeys-with-server-components).

Start with the [React Quick Start](./framework/react/quick-start). To add the devtools panel, install:

```sh
npm i @tanstack/react-devtools
npm i @tanstack/react-hotkeys-devtools
```

See [Devtools](./devtools) for setup instructions.
