How to Give Roles Automatically When Members Level Up

Milestones, stacking, and the hierarchy problem

· · 2 min read

Automatic role rewards are what make a leveling system worth participating in. The XP number on its own doesn't do anything, whereas a role is visible to everyone, changes how a member appears in the member list, and can unlock something.

The configuration itself takes a few minutes. The decisions behind it are worth a little more thought, because two of them are annoying to change later.

Fix the role hierarchy first

Before anything else, your bot's role must be positioned above every role it will assign. Discord will not report an error when this is wrong, so what happens is that the bot tries to assign the role, Discord refuses, and nothing visible happens at all.

This is the most common reason a leveling system appears to be working while handing out nothing, so check it before you announce the system rather than after the first member asks why they didn't get their role.

Pick milestones, not every level

A role for every level from 1 to 50 produces 50 roles that mean nothing individually and make your member list unreadable.

Four to six milestones works much better. Space the first one so a new member reaches it within a day or two, which is early enough to show them the system exists, and space the last one so it takes months, which gives long-term members something to still be working toward.

Decide whether roles stack

When a member reaches a new milestone, the bot either removes the previous role or leaves it in place.

Stacking shows progression history and lets you address "everyone who has ever hit level 10" as a group, while replacing keeps each member to a single visible rank and a shorter role list. Most servers are happier with stacking, but the important part is deciding before you launch, because changing your mind later means editing roles on every member who has already progressed.

Make the colors escalate

A ramp from gray through green, blue, purple, and gold reads as progression instantly, without anyone having to check a leaderboard to know who's been around. Random colors per tier lose that for no benefit.

Give the top tier something real

A cosmetic-only top role stops feeling special within a few weeks, so attach something functional to it: access to a members-only channel, permission to use external emoji, a discount if your bot has an economy, or the ability to start events.

It doesn't have to be large. It just has to be something a member at that level can do that others can't.

Test with an alt before announcing

Set the first milestone to level 1 temporarily, send a few messages on a second account, and confirm the role actually lands, then set it back afterward. This takes two minutes and catches the hierarchy problem, the permission problem, and any typo in the configuration before your members find them for you.

More from the Gamebot blog