> ## Documentation Index
> Fetch the complete documentation index at: https://docs.braintrust.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# bt switch

> Switch the active Braintrust profile, organization, and project context.

`bt switch` saves your active Braintrust profile, organization, and project context. Commands use that saved context unless you override it with flags or environment variables.

```bash theme={null}
bt switch
bt switch my-project
bt switch personal-org/my-project
```

Without a target, `bt switch` prompts you to choose a compatible profile, organization, and project.

## Arguments

| Argument | Description |
| - | - |
| `TARGET` | Project name, or `org/project` |

## Flags

| Flag | Description |
| - | - |
| `--global`, `-g` | Save the context to `~/.config/bt/config.json` (or `$XDG_CONFIG_HOME/bt/config.json`) |
| `--local`, `-l` | Save the context to the nearest `.bt/config.json`. Requires a local `.bt` directory |

When you run `bt switch` without a target and a `.bt/config.json` exists in the current directory or a parent directory, the command prompts you to save the context locally or globally. Otherwise, it saves the context globally. When you provide a target, use `--local` to save it to the nearest `.bt/config.json` instead of the global config.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.