# getstream login & logout

Manage the CLI's session with the [Stream Dashboard](https://getstream.io/signin/). The session is stored at `~/.stream/auth.yaml`.

## `getstream login`

```bash
getstream login
```

Opens a browser and completes a PKCE flow. Writes a refreshing session to `~/.stream/auth.yaml`.

| Flag          | Effect                                                             |
| ------------- | ------------------------------------------------------------------ |
| `-g, --guest` | Create a temporary guest account backed by a throwaway app.        |
| `--upgrade`   | Open the dashboard to convert a guest account into a personal one. |

```bash
getstream login --guest
getstream login --upgrade
```

## `getstream logout`

```bash
getstream logout
```

Clears `~/.stream/auth.yaml`. Logging out of a guest account discards it permanently, so the CLI asks for confirmation.

| Flag          | Effect                                                                           |
| ------------- | -------------------------------------------------------------------------------- |
| `-f, --force` | Skip the confirmation. Required to log out of a guest account non-interactively. |

## See also

- [Authenticate interactively](https://getstream.io/cli/docs/authentication/): how-to
- [Projects and credentials](https://getstream.io/cli/docs/concepts/projects-and-credentials/): how the session composes with a project
- [Use the CLI in CI](https://getstream.io/cli/docs/ci/): the headless path, which uses no session

---

For the most recent version of this documentation, visit [https://getstream.io/cli/docs/commands/login/](https://getstream.io/cli/docs/commands/login/).