# Installation

> Install the Testlane CLI from npm with your package manager, and check that your shell finds it.

By the end of this page, `testlane` runs from any directory in your shell. It takes about a minute with your package manager.

## Before you start

Testlane runs on Node.js and shells out to git, so you'll need both:

| Tool                           | Version       | Required                                                                    |
| ------------------------------ | ------------- | --------------------------------------------------------------------------- |
| [Node.js](https://nodejs.org)  | 18 or later   | Yes                                                                         |
| `git`                          | 2.38 or later | Yes                                                                         |
| [`gh`](https://cli.github.com) | Any           | No, though it adds each PR's state and title, `gh pr diff` and push-back    |

Any package manager installs it, and it needs no other runtime. Keep in mind that every feature that uses `gh` falls back to plain git when `gh` is missing or not signed in, so you can add it later.

## Install the CLI

::steps{level="3"}

### Install the package

Testlane is published to npm as `@uxfront/testlane`, and it puts a `testlane` command on your `PATH`. We recommend installing it globally:

:::code-group

```bash [npm]
npm i -g @uxfront/testlane
```

```bash [pnpm]
pnpm add -g @uxfront/testlane
```

```bash [yarn]
yarn global add @uxfront/testlane
```

:::

When it finishes, `testlane` is in your package manager's global `bin` directory.

### Check that your shell finds it

```bash
testlane version
```

It prints the version you installed:

```
testlane 2.0.0
```

If your shell says `testlane: command not found` instead, see [the FAQ](https://testlane.dev/docs/getting-started/installation#faq) below.

::

## FAQ

::accordion
  :::accordion-item{label="Why does my shell say testlane: command not found?"}
  Because your package manager's global `bin` directory isn't on your `PATH`. Add `$(npm prefix -g)/bin` for npm, `$(pnpm bin -g)` for pnpm or `$(yarn global bin)` for Yarn, then open a new shell.
  :::

  :::accordion-item{label="Do I need Bun or Deno?"}
  No. Testlane runs on Node.js 18 or later, and nothing else.
  :::

  :::accordion-item{label="Can I add gh later?"}
  Yes. Every command that uses `gh` checks for it first, with `gh auth status`, so the commands you run once it's installed and signed in pick it up. Keep in mind that a PR workspace gets push-back only when it's created, so remove one you opened before with `rm` and open it again to get it. Run `testlane doctor` to see whether `gh` is found.
  :::
::

## Where to go next

Now that it's installed, set up your first project:

- [Quick start](https://testlane.dev/docs/getting-started/quick-start) takes you from here to a running workspace in three commands.
- [Agents](https://testlane.dev/docs/getting-started/agents) shows how to hand Testlane to your coding agent instead.
