> For the complete documentation index, see [llms.txt](https://infinitybot.gitbook.io/infinitybot-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://infinitybot.gitbook.io/infinitybot-docs/guides/infinitybot-guides/command-guides/how-prefix-commands-work.md).

# How Prefix Commands Work

InfinityBot uses a few prefix commands. You can read more about them below.

### About Prefix Commands

Prefix commands are basically commands that have a symbol infront of them. Instead of sending them via Discord like [slash commands](/infinitybot-docs/guides/infinitybot-guides/command-guides/how-slash-commands-work.md) (`/`), you send them directly in chat. InfinityBot uses `!` as prefix.&#x20;

You can get a list with all prefix commands you can use by sending `!prefix` in chat or by visiting [the prefix page](/infinitybot-docs/server-tools/prefix-commands.md).&#x20;

<figure><img src="https://2255898787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FZqXmdaTQZknKkvcG0Uxz%2Fuploads%2FUUCgAhigNL0IlDCdD9ox%2FClyde's%20gif.gif?alt=media&amp;token=3ff83e87-9472-416c-b7ba-15ef013915a8" alt="" width="375"><figcaption></figcaption></figure>

### Setup

#### Custom Prefix

You can set a custom prefix with the `!set-prefix` command.&#x20;

#### Command Channel

You can select a command channel with the `!cmnd-channel` command. Users will then only be able to use prefix commands in that channel.&#x20;

### Prefix Command Options

Prefix commands can also have options. These can be added after the command, for example to ban a user, the option would be the user and the reason of the ban.&#x20;

This would be the template of the ban command: `!ban @user reason`

This would be the way you use it in a channel: `!ban @knight spamming`, replacing the options.&#x20;

<figure><img src="https://2255898787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FZqXmdaTQZknKkvcG0Uxz%2Fuploads%2FI59GPeam1v2AqnnvzqPl%2Fimage.png?alt=media&amp;token=57aa77c1-6797-4b18-835f-736da8f7eb9d" alt="" width="396"><figcaption></figcaption></figure>

#### Reply Option

You can also target a message with prefix commands by replying to it. This can only be done if you need to target a message, for example when using the `!pin` command.&#x20;

<figure><img src="https://2255898787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FZqXmdaTQZknKkvcG0Uxz%2Fuploads%2F61e2uN3wndunHFdNnhWj%2Fimage.png?alt=media&amp;token=6f1b9b00-9955-478c-8dad-a60400c7a05b" alt="" width="558"><figcaption></figcaption></figure>
