> For the complete documentation index, see [llms.txt](https://docs.mochi.bot/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mochi.bot/levels-and-engagement/leveling.md). Agents can also search and read this documentation through its [MCP server](https://docs.mochi.bot/~gitbook/mcp).

# Leveling

Reward activity with XP, levels and a little friendly competition.

Chatting, hanging out in voice, reacting to a great meme: it all keeps a community going. Leveling turns all that activity into progress members can actually see! 📈

With Mochi's <mark style="color:$primary;">**Leveling**</mark>, members earn <mark style="color:$primary;">**XP**</mark> (experience points) as they take part. Collect enough XP and they <mark style="color:$primary;">**level up**</mark>, with a celebration message, a shiny rank card, and maybe a new role or some currency as a reward.

***

## <mark style="color:$primary;">What it does</mark>

Members earn XP in up to three ways:

* 💬 **Message XP**: for chatting in text channels
* 🎙️ **Voice XP**: for spending time in voice channels *(Mochi Prime)*
* 💖 **Reaction XP**: for adding reactions, receiving them, or both *(Mochi Prime)*

When a member has enough XP for the next level, Mochi announces it with a **level-up message**.

You decide:

* How much XP each activity gives, and how often
* How quickly levels get harder (see [XP Curve & Calculator](https://docs.mochi.bot/levels-and-engagement/xp-curve-and-calculator.md))
* What the level-up message says and where it goes
* Which roles and channels **don't** earn XP
* What members win at each level (see [Level Rewards & XP Boosters](https://docs.mochi.bot/levels-and-engagement/level-rewards-and-boosters.md))

{% hint style="info" %}
💎 [**Mochi Prime**](https://docs.mochi.bot/mochi-prime/what-is-mochi-prime.md): Voice XP and Reaction XP are part of Mochi Prime. Message XP is free for everyone.
{% endhint %}

***

## 🔐 <mark style="color:$primary;">Permissions Mochi needs</mark>

| Where                                                         | Permissions                                                               |
| ------------------------------------------------------------- | ------------------------------------------------------------------------- |
| Your level-up channel (or every chat channel, if none is set) | **View Channel** · **Send Messages** · **Embed Links** · **Attach Files** |
| Voice channels                                                | **View Channel** (for Voice XP)                                           |
| Server-wide (Mochi's role)                                    | **Manage Roles** (for role rewards)                                       |

{% hint style="info" %}
💡 **Troubleshooting tip:** Something not working? Don't panic, it's usually just a permission! Check the channel itself (⚙️ **Edit Channel → Permissions**) and Mochi's role in **Server Settings → Roles**, because a channel setting can block something her role allows. See [Roles & Permissions](https://docs.mochi.bot/getting-started/roles-and-permissions.md).
{% endhint %}

***

## <mark style="color:$primary;">How to set it up</mark>

{% stepper %}
{% step %}
Open the [**Mochi Dashboard**](https://mochi.bot) and choose your server.
{% endstep %}

{% step %}
In the sidebar, open **Server Management** and click **Leveling**.
{% endstep %}

{% step %}
In **Leveling Alert**, write your level-up **Message**, choose a **Channel** (or leave it empty, see below), and click **Save**.
{% endstep %}

{% step %}
Check **Message XP** is **Enabled**, adjust the numbers if you like, and click **Save**.
{% endstep %}

{% step %}
*(Prime)* Turn on **Voice XP** and **Reaction XP** if you'd like, and click **Save** on each.
{% endstep %}

{% step %}
In **No XP Options**, add any roles or channels that shouldn't earn XP, like a bot-commands channel.
{% endstep %}
{% endstepper %}

Each section has its own **Save** button, so remember to save the section you've changed.

<figure><img src="https://2165914094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNXPRKMDw2wWy4K61hBPv%2Fuploads%2Fgit-blob-4dff04125d6844568addfb28d51722c75a9a3791%2Flv-01.png?alt=media" alt="Leveling → edit the Leveling Alert message → choose a Channel → Save → scroll to Message XP → change Maximum XP → Save."><figcaption><p>Leveling → edit the Leveling Alert message → choose a Channel → Save → scroll to Message XP → change Maximum XP → Save.</p></figcaption></figure>

<figure><img src="https://2165914094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNXPRKMDw2wWy4K61hBPv%2Fuploads%2Fgit-blob-4c6c12d76f189d2ac419163a3f38aeac912f8fcb%2Flv-02.png?alt=media" alt="In Discord, a member levels up and Mochi posts the level-up message."><figcaption><p>In Discord, a member levels up and Mochi posts the level-up message.</p></figcaption></figure>

***

## <mark style="color:$primary;">Commands</mark>

The main leveling commands are:

* `/rank`: check your level, XP and rank
* `/leaderboard`: see who's on top
* `/level …`: staff tools for adding or removing XP and levels, and more
* `/toggle leveling message`: turn level-up messages on or off

👉 Every command, with examples: [Leveling Commands](https://docs.mochi.bot/levels-and-engagement/leveling-commands.md).

***

## <mark style="color:$primary;">Settings explained</mark>

### Leveling Alert

*Configure how level-up alerts are sent, including message content and channel.*

| Setting              | What it does                                                                                                         |
| -------------------- | -------------------------------------------------------------------------------------------------------------------- |
| **Message**          | *A short message displayed when a user levels up.* The default is *"{user.mention} has reached level {user.level}!"* |
| **Message Template** | *A customizable format for the level-up message*. Use a saved, designed message instead                              |
| **Channel**          | *The channel where the level-up message will be sent*                                                                |

> Example message: *"🎉 Woohoo, {user.mention}! You're now level {user.level}!"*

If you don't choose a **Channel**, Mochi posts the level-up message in the channel where the member leveled up.

### Message XP

*Grant members XP for sending messages.*

| Setting        | What it does                                                     | Default    |
| -------------- | ---------------------------------------------------------------- | ---------- |
| **Enabled**    | Turns Message XP on or off                                       | On         |
| **Minimum XP** | *The minimum XP rewarded* for a message                          | 1          |
| **Maximum XP** | *The maximum XP rewarded* for a message                          | 10         |
| **Cooldown**   | *The time in seconds that must pass before XP is rewarded again* | 60 seconds |

Each time a member chats, Mochi gives them a random amount of XP between the minimum and maximum, but only once per cooldown. That way, sending lots of tiny messages doesn't earn any extra.

### Voice XP 💎

*Grant users XP for spending time in voice channels.*

| Setting                         | What it does                                                                                  | Default    |
| ------------------------------- | --------------------------------------------------------------------------------------------- | ---------- |
| **Enabled**                     | Turns Voice XP on or off                                                                      | Off        |
| **Minimum XP** / **Maximum XP** | The range of XP given each time                                                               | 1 / 10     |
| **Cooldown (seconds)**          | How often XP is given while in voice                                                          | 60 seconds |
| **Minimum voice members**       | *The minimum number of active members required in a voice channel before voice XP is awarded* | 1          |
| **Anti AFK**                    | *Gradually reduce voice XP after multiple hours in one voice session*                         | On         |

{% hint style="info" %}
💡 **Tip:** Set **Minimum voice members** to `2` so members only earn voice XP when they're actually talking with someone.
{% endhint %}

### Reaction XP 💎

*Reward members for adding reactions, receiving reactions, or both.*

| Setting                         | What it does                                                                                                                     | Default              |
| ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | -------------------- |
| **Enabled**                     | Turns Reaction XP on or off                                                                                                      | Off                  |
| **Reward for**                  | *Choose which reaction activity awards XP:* **Receiving reactions**, **Adding reactions**, or **Adding and receiving reactions** | Adding and receiving |
| **Minimum XP** / **Maximum XP** | The range of XP given each time                                                                                                  | 1 / 10               |
| **Cooldown (seconds)**          | *The shared cooldown for adding and receiving reactions*                                                                         | 300 seconds          |

### No XP Options

*Roles and channels that do not trigger XP increase.*

* **Roles**: members with these roles never earn XP, like `@Muted` or `@Unverified`
* **Channels**: activity in these channels never earns XP, like `#bot-commands` or `#spam`

### Manage User XP

*Search for a server member or enter their user ID, then add or remove XP.*

1. Search for the member, or paste their Discord ID.
2. Enter the **XP amount**.
3. Click **Add XP** or **Remove XP**.

Handy for rewarding an event winner, or fixing a mistake.

***

## 🌱 <mark style="color:$primary;">Best practices</mark>

* **Keep the cooldown.** 60 seconds stops spam from paying off.
* **Exclude bot and spam channels** in **No XP Options**, so levels reflect real conversation.
* **Use a dedicated channel for level-ups** in busy servers, so they don't interrupt chat.
* **Set Minimum voice members to 2** so nobody farms XP alone in a voice channel.
* **Pair levels with rewards**: a role at level 5, 10 and 25 gives members something to aim for.
* **Check the** [**XP Curve & Calculator**](https://docs.mochi.bot/levels-and-engagement/xp-curve-and-calculator.md) before changing how hard levels are.

***

## 🛠️ <mark style="color:$primary;">Troubleshooting</mark>

<details>

<summary>Members aren't earning XP.</summary>

* Is **Message XP** **Enabled** and saved?
* Is the member's role, or the channel, listed in **No XP Options**?
* They might be chatting faster than the **Cooldown**, XP only comes once per cooldown.

</details>

<details>

<summary>No level-up messages appear.</summary>

* Check level-up messages haven't been switched off with `/toggle leveling message`.
* Check the **Leveling Alert** channel, and that Mochi can **Send Messages** and **Embed Links** there.

</details>

<details>

<summary>Voice XP isn't working.</summary>

* Voice XP is part of Mochi Prime.
* Check **Minimum voice members**, if it's `2`, someone else needs to be in the channel too.

</details>

{% columns %}
{% column width="33.33333333333333%" %}

<figure><img src="https://2165914094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNXPRKMDw2wWy4K61hBPv%2Fuploads%2Fgit-blob-fa50d1e36c23a82929fe13087b832029ac007239%2Fcta-support-kagami-square.jpg?alt=media" alt="Kagami, ready to help" width="200"><figcaption></figcaption></figure>
{% endcolumn %}

{% column width="66.66666666666667%" %}
**Need some help? 🩷**

Pop into the Mochi Support Server and we'll happily take a look with you.

<a href="https://discord.gg/krsFJDS2hA" class="button primary" data-icon="discord">Join the Support Server</a>
{% endcolumn %}
{% endcolumns %}

***

## ✨ <mark style="color:$primary;">Why it matters</mark>

Levels give members a fun way to see how far they've come, and with rewards on top, reaching a new level feels like a real little win! 🎉

Every message is a step up! ⭐
