# Authentication

> Authentication — Turso documentation.
> Canonical HTML: https://tursodb.cn/docs/cli/authentication/
> Upstream Source (MIT): https://docs.turso.tech/cli/authentication
> Language: en

---
## `login`

The Turso CLI uses an access token to authenticate with Turso. You can login using the command:

```bash
turso auth login
```

This will open a browser window, asking you to log into your account with GitHub.

<div class="doc-callout doc-callout-info"><div class="doc-callout-title">NOTE</div><div class="doc-callout-body">

If you're using Windows with WSL or a remote CI/CD environment, pass the `--headless` flag.

</div></div>


Once you're logged in, you can manage your account and databases. You can explore all of the commands via the docs, or by using the `--help` flag for each subcommand:

```bash
turso
```

<div class="doc-callout doc-callout-info"><div class="doc-callout-title">NOTE</div><div class="doc-callout-body">

The Turso CLI requires you to reauthenticate after one week. Don't share your token.

</div></div>


## `signup`

If you're new to Turso, you can create an account using the Turso CLI:

```bash
turso auth signup
```

## `logout`

You can logout of the Turso CLI using the `logout` command:

```bash
turso auth logout
```
