NewSchokr 13 is here. A whole new UI, seven locations, snapshots and more. Read more →

How to fix "Used disallowed intents" (privileged intents)

Fix the Used disallowed intents and PrivilegedIntentsRequired errors by enabling Message Content, Server Members or Presence intents in the Developer Portal.

Updated · 2 min read

"Used disallowed intents" (discord.js) and PrivilegedIntentsRequired (discord.py) mean your code asks for a privileged intent that isn't enabled for your bot in the Discord Developer Portal. Either turn the intent on in the portal or stop requesting it in code.

What the errors look like

discord.js:

Error: Used disallowed intents

discord.py:

discord.errors.PrivilegedIntentsRequired: Shard ID None is requesting privileged intents that have not been explicitly enabled in the developer portal.

The bot fails to log in and the process usually exits, so on Schokr you'll see the server stop right after starting.

The three privileged intents

Portal togglediscord.jsdiscord.pyNeeded for
Message Content IntentGatewayIntentBits.MessageContentintents.message_contentReading message text, attachments and embeds (prefix commands, auto-moderation, chat logging)
Server Members IntentGatewayIntentBits.GuildMembersintents.membersMember join and leave events, member updates, fetching the full member list
Presence IntentGatewayIntentBits.GuildPresencesintents.presencesOnline status and activities ("Playing...") of members

Without Message Content, your bot still gets message text in DMs, in messages that mention it, and in its own messages. Slash commands don't need it at all.

Fix: enable the intent in the portal

  1. Open the Discord Developer Portal and select your application.
  2. Go to the Bot page.
  3. Under Privileged Gateway Intents, turn on the intents your code requests.
  4. Save changes.
  5. Restart your server on Schokr.

The code and the portal must match: every privileged intent in your code needs its portal toggle on.

Or: remove intents you don't need

Requesting fewer intents means less data and less memory. If you only use slash commands, this is enough in discord.js:

const client = new Client({ intents: [GatewayIntentBits.Guilds] });

And in discord.py:

intents = discord.Intents.default()  # no privileged intents
bot = commands.Bot(command_prefix="!", intents=intents)

Avoid discord.Intents.all() unless you really use everything; it requests all three privileged intents.

Bots in 100 or more servers

Once a bot is in 100 or more servers it must be verified, and privileged intents then need approval from Discord with a reason for each one. Until approved, you can't simply flip the toggles. Plan for this early by using slash commands instead of reading message content where you can.

  • Bot logs in but ignores !commands: Message Content is missing in code. See bot online but not responding.
  • guildMemberAdd / on_member_join never fires: the members intent is missing in code or the portal.