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

# Restore Roles

## Command

```txt theme={null}
/mod restore-roles <user>
```

## Description

Gives a Member the roles back they had before leaving the server.

When a Member leaves the server, the bot remembers their roles for 14 days. This covers Members who leave on their own as well as kicks and bans, whether made with `/mod`, in Discord itself or by another bot. Once the Member is on the server again, this command restores the stored roles.

If a Member leaves again before their roles were restored, the stored roles are replaced with the ones they had at that moment.

Some roles are left out:

* Roles that no longer exist, roles managed by an integration and roles the bot can't assign are skipped.
* Roles that are not below your own highest role are skipped and stay stored, so someone with a higher role can restore them.

## Permission

`MANAGE_ROLES`

## Arguments

| Name | Type | Description | Sample Data |
| - | - | - | - |
| user | User | The Member whose roles should be restored | @HerrTxbias |


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