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

# Profiles

> Use local CLI profiles for multiple SiteGPT accounts, environments, and permission sets.

Profiles are local named configurations. Each profile stores:

* API base URL
* Token
* Whether it is the default profile

Profiles are useful when you manage multiple SiteGPT accounts, keep separate production and local environments, or create least-privilege tokens for different agents.

Reference: [profile commands and aliases](/cli/command-reference#profiles).

## List profiles

```bash theme={null}
sitegpt profiles list
sitegpt profiles list --json
```

Human output shows the profile name, default marker, API base, and a masked token preview.

## Show one profile

```bash theme={null}
sitegpt profiles show <profile>
sitegpt profiles show <profile> --json
```

If you omit the profile name, the CLI shows the selected/default profile:

```bash theme={null}
sitegpt profiles show
```

## Create a profile

Profiles are created by logging in with `--profile`:

```bash theme={null}
sitegpt login --profile work
sitegpt login --profile support-agent --scope conversations:read --scope conversations:write
```

Use `--api-base` only when you need a non-default environment:

```bash theme={null}
sitegpt login --profile local --api-base http://127.0.0.1:8787
```

## Change the default profile

```bash theme={null}
sitegpt profiles use <profile>
```

Alias:

```bash theme={null}
sitegpt profiles set-default <profile>
```

After this, commands without `--profile` use the selected profile.

## Run a command with a specific profile

```bash theme={null}
sitegpt --profile work whoami
sitegpt chatbots list --profile work
sitegpt knowledge documents list --profile support-agent --chatbot <chatbot-id>
```

`-p` is an alias for `--profile`:

```bash theme={null}
sitegpt -p work chatbots list
```

## Delete a profile

```bash theme={null}
sitegpt profiles delete <profile>
```

Alias:

```bash theme={null}
sitegpt profiles remove <profile>
```

Deleting a profile removes the token from your local machine. It does not revoke the token in SiteGPT. To revoke a token server-side:

```bash theme={null}
sitegpt tokens list
sitegpt tokens revoke <token-id>
```

## Environment overrides

Environment variables override the saved profile for a single command:

```bash theme={null}
SITEGPT_PROFILE=work sitegpt whoami
SITEGPT_API_BASE=https://sitegpt.ai sitegpt chatbots list
SITEGPT_API_TOKEN=<token> sitegpt whoami
```

## Recommended profile pattern for agents

Create separate profiles for separate responsibilities:

| Profile            | Example scopes                                                                                                 |
| ------------------ | -------------------------------------------------------------------------------------------------------------- |
| `setup-agent`      | `chatbots:read`, `chatbots:write`, `knowledge:write`, `settings:write`, `personas:write`, `instructions:write` |
| `knowledge-agent`  | `chatbots:read`, `knowledge:read`, `knowledge:write`, `knowledge:delete`                                       |
| `support-agent`    | `chatbots:read`, `conversations:read`, `conversations:write`, `leads:read`, `leads:write`                      |
| `billing-readonly` | `account:read`, `billing:read`, `usage` access through the account token                                       |

<Tip>
  Use `sitegpt profiles list` at the start of agent sessions so the agent knows which profile is currently active. For a full agent setup workflow, see [Use with AI agents](/cli/use-with-ai-agents).
</Tip>
