# Telegram: Profiles and bots (/en/docs/tg/profiles)

Choose the right account or bot when you have more than one. This guide explains named profiles and their settings so a task runs with the intended account.

[Choose an account or bot](/llms.mdx/docs/configuration/content.md#profiles-and-bots)

A **profile** is a name for one login of `tg` on this computer: a Telegram account or a bot, with its
own session and its own settings. `tg` never picks one for you: a command that uses an account
names its profile as the first word (`tg personal chats list`) or through `TG_PROFILE`, every
time, even with only one account.

Read this page when you want a second account, want your AI agent to have fewer rights than you, or
want to run a bot. At the end you know how to pick a profile for a command, how to give it its own
settings, and how to switch to a bot.

## What profiles let you do [#what-profiles-let-you-do]

| You want to | How |
|---|---|
| Use two Telegram accounts on one computer | Log in once per profile: `tg work session start` |
| Give your agent fewer rights than you have | A profile with its own [permissions](/llms.mdx/docs/tg/permissions/content.md) |
| Keep an agent on that one profile | `TG_PROFILE_LOCK` ([profiles in login and sessions](/llms.mdx/docs/tg/sessions/content.md#profiles)) |
| Run a Telegram bot next to your account | A bot profile: `tg support bot api get-me` |
| See every profile on this computer | `tg account list` |

## Choose a profile [#choose-a-profile]

Put the profile name before the command:

```sh
tg work config show
```

`tg account list` shows every profile on this computer and the account each is logged in as;
`tg work session end` logs the profile `work` out.

A setting under `profiles.work` in the config file applies to that profile; values under `defaults`
apply when it has no value of its own. The rules for profile names, and the order in which `tg`
picks a profile, are in [profiles in login and sessions](/llms.mdx/docs/tg/sessions/content.md#profiles).

Profiles are not separate operating-system users: an agent with unrestricted file access can still
reach other data on that computer.

## Switch to a bot [#switch-to-a-bot]

Put `bot` after the profile name:

```sh
tg support bot api get-me --json
```

These commands need a bot profile that is already connected. The bot's account and rights come
from Telegram, not from your personal account. [A Telegram bot](/llms.mdx/docs/tg/bot/content.md) explains how to connect a
bot, with examples.

## Settings and access [#settings-and-access]

- [Configuration](/llms.mdx/docs/tg/configuration/content.md) explains saved values, environment variables and options.
- [Permissions](/llms.mdx/docs/tg/permissions/content.md) controls what each profile may do.
- [Login, sessions and profiles](/llms.mdx/docs/tg/sessions/content.md) explains how to log a profile in.
