Documentation
Complete reference for Honeypot — from adding the bot to a server to self-hosting your own instance with a custom web dashboard.
Introduction
Honeypot is a passive spam-bot detection system for Discord. Instead of using keyword filters, rate limits, or CAPTCHA challenges — which all have significant false-positive rates — it uses a fundamentally different approach: a trap channel.
The idea is borrowed from cybersecurity. In networking, a "honeypot" is a system intentionally left vulnerable to attract attackers — when something touches it, you know it's malicious, because nothing legitimate would go near it. Honeypot applies this exact principle to Discord channels.
The trap channel (#honeypot) is visible to everyone, but has @everyone
Send Messages permission denied. The bot's role is the only one that can write there. The channel
contains a visible warning message telling human members not to write in it. Real users read
and comply. Automated spam bots don't — they scan every visible channel and blast their message
into all of them without reading a word.
The moment a bot sends a message there, its nature is revealed with zero ambiguity. There is no need to analyse content or check account age — the action of sending a message in that channel is the proof.
How it works
The full detection and response flow, step by step:
The bot does not need to scan message content, check invite links, or look at account age. The trap channel is a binary signal: if you sent a message there, you're automated.
Why it works so well: Most Discord spam bots use a "spray all channels" strategy because it maximises reach. Honeypot exploits this exact behaviour. A more sophisticated bot that reads channel descriptions before writing would avoid the trap — but those are rare, and the warning in the channel name still catches anything that only filters by permission.
Prerequisites
Before adding Honeypot to your server, make sure of the following:
- You have Manage Server or Administrator permission on the server.
- The server has at least one channel visible to
@everyone(so the bot can be seen). - You can assign the bot's role to a position above regular member roles.
Role hierarchy is critical. Discord prevents banning users whose highest role is equal to or above the bot's highest role. If the bot cannot act on a user, it will send an informational message instead. See the Role hierarchy section for how to set this up correctly.
Quick start
From zero to a protected server in under two minutes:
Invite the bot
Click Add to Discord in the navigation. Select your server and authorise the requested permissions — Ban Members, Manage Channels, Manage Messages, Read/Send Messages.
Let the bot set up
The bot automatically creates a #honeypot channel with the correct permissions and posts a Components V2 warning message inside it. Check your channel list — it should appear under your existing channels.
Move the bot's role up
Go to Server Settings → Roles and drag the Honeypot role above all your regular member roles. This is required for the bot to ban users whose role is lower than its own.
Done
The bot is now actively monitoring the channel. Optionally run /honeypot to change the channel, log channel, or moderation action, and /honeypot-messages to customise the messages.
Tip: Consider renaming the channel to something innocuous like #welcome-info or
#bot-spam. Spam bots don't care about names, but a name like #honeypot
makes it slightly more obvious to humans what it is. Choose based on whether you want
visible deterrence or silent detection.
/honeypot
Opens an interactive configuration panel. Only members with Manage Server or Administrator permission can run this command.
#mod-log) where the bot posts a log entry after
every action. Includes the user's mention, Discord ID, account creation date, join date,
and the action taken. Leave empty to disable logging.
softban (default),
ban, or disabled. See the Actions section
for a full comparison.
After submitting:
- Config is saved to
data/config.jsonatomically (no corruption risk on crash). - The warning message in the honeypot channel is edited in-place with the new settings.
- If you changed the honeypot channel, the old warning message is deleted and a new one is sent.
- The interaction reply is ephemeral — only you can see the confirmation.
/honeypot-messages
Opens a Discord modal to customise the three messages the bot sends. Requires Manage Server.
Default: "This is a honeypot channel — do not write here. Any message automatically triggers account removal."
Default: "You were {{action:text}} from {{server:name}} for sending a message in the honeypot channel…"
Leave any field blank to reset it to its default. Changes apply immediately — the warning message in the honeypot channel is edited in-place.
Example DM message
Hi {{user:mention}},
You were automatically {{action:text}} from **{{server:name}}** because your account
sent a message in our honeypot channel ({{honeypot:channel:link}}).
If your account was compromised, please:
1. Change your Discord password immediately
2. Enable two-factor authentication
3. Request an unban in our support server
Account created: {{user:created}}
Joined server: {{member:joined}}
Template variables
Template variables are placeholders replaced with live values when the bot sends messages. They work in the warning, DM, and log messages. Variables are case-sensitive and must use exactly double curly braces.
| Variable | Description | Example output |
|---|---|---|
{{user:mention}} |
Mentions the user — links their profile and sends them a notification | @SpamBot#0001 |
{{user:id}} |
The user's full Discord snowflake ID — useful for audit logs | 123456789012345678 |
{{user:created}} |
When the Discord account was created (Discord relative timestamp) | <t:1234567890:R> → 2 months ago |
{{action:text}} |
The action taken: softbanned or banned |
softbanned |
{{server:name}} |
The display name of the server | My Awesome Server |
{{honeypot:channel:link}} |
A clickable Discord jump-URL to the honeypot channel | https://discord.com/channels/… |
{{honeypot:channel:mention}} |
Inline channel mention — renders as a clickable #channel tag |
#honeypot |
{{member:joined}} |
When the user joined the server (Discord relative timestamp) | <t:1234567890:R> → 3 days ago |
{{user:created}} and {{member:joined}} use Discord's native
<t:UNIX:R> timestamp format, which renders automatically in the user's
local timezone and language as a relative time ("2 months ago", "il y a 3 jours", etc.).
Actions
Three actions are available. The default is Softban, which covers most use cases without permanently locking out potentially-recovered accounts.
Bans the user then immediately unbans them. Deletes the last hour of their messages across all channels. The account can rejoin via an invite link.
Best for: most servers. Compromised accounts can be recovered. Leaves the door open for an appeal.
Permanently bans the user. Also deletes the last hour of messages. The account cannot rejoin until manually unbanned by an admin.
Best for: zero-tolerance servers, high-value communities, or when you consistently see the same bots re-joining.
The bot monitors the channel but takes no moderation action. The warning message is still shown and the trigger counter is still incremented. Useful for testing your setup, or when you want to manually review triggers before taking action.
Regardless of the action setting, the bot always:
- Deletes the trigger message immediately (before anyone else can see it).
- Increments the kick counter on the warning message embed.
- Pushes a live stats update to the web dashboard.
- Attempts to DM the user (silently skipped if DMs are disabled).
- Posts a log entry if a log channel is configured.
Role hierarchy
Discord enforces a strict role hierarchy: you can only moderate users whose highest role is below your own. This rule applies to bots too. If the Honeypot role is position 3 and a user has a role at position 4, the bot cannot ban them.
How to fix it
- Open Server Settings → Roles.
- Find the Honeypot role in the list.
- Drag it as high as possible — below your own admin/moderator roles, but above everyone else.
- Save changes.
A good placement looks like this (higher = more powerful):
If the bot cannot act on someone (server owner or role too high), it will send a visible warning in the honeypot channel rather than silently failing. This is intentional — it lets you know something is wrong with your setup.
Permissions
The following permissions are requested during the invite flow. Each one has a specific purpose — the bot will not work correctly without them.
- Ban Members Required to execute softban and ban actions. Without this, the bot detects the trigger but cannot remove the user — it will send a warning message instead.
- Manage Messages Used to delete the trigger message immediately after it is sent. This prevents the spam content from being visible to other members, even briefly.
-
Manage Channels
Needed on first join to create the
#honeypotchannel with the correct permission overrides (@everyonecan view but not send). - Read Message History Allows the bot to fetch the existing warning message by its saved ID, so it can edit the kick counter in-place rather than sending a new message every time.
- Send Messages Required to post the warning message inside the honeypot channel, log entries in the log channel, and error messages when the bot cannot act.
- View Channels Basic visibility — required to read MessageCreate events in the honeypot channel.
Troubleshooting
The bot joined but didn't create the #honeypot channel
The bot needs Manage Channels permission to create channels. Check that you granted it during the invite flow (Server Settings → Integrations → Honeypot → Permissions). If you denied it, remove the bot and re-invite it, making sure to tick Manage Channels.
Alternatively, create a channel manually and run /honeypot to point the bot at it. The bot will set the correct @everyone permission overrides automatically when the command is saved.
The bot says it can't ban someone
Two possible causes:
1. The user has a role equal to or higher than the bot's role. Fix it by dragging the Honeypot role above all regular member roles in Server Settings → Roles.
2. The bot lacks Ban Members permission. Check Server Settings → Integrations → Honeypot.
The warning message keeps getting reposted instead of edited
This happens when the original warning message was deleted. When that happens, the bot falls back to sending a new one and saves the new ID. To prevent it, make sure ordinary members cannot delete messages in the honeypot channel (they can't by default, since they can't send messages there either).
You can also prevent accidental deletion by any admin by pinning the message — the bot will self-heal regardless.
Slash commands are not appearing in my server
Global slash commands can take up to one hour to propagate to all servers after the bot first joins. Wait a bit and try again — they will appear.
If the command appears but shows "This interaction failed", make sure Honeypot's role is still on the server and it still has the required permissions.
A legitimate user got caught — how do I unban them?
If the action was Softban, the user was already unbanned automatically — they can rejoin immediately via any invite link.
If the action was Ban, go to Server Settings → Bans, find their username or ID, and click Revoke Ban. Then send them a new invite link.
The bot is in the server but the honeypot channel isn't protected
Run /honeypot and check the configured channel. If you changed the channel name or moved the channel to a different category, the bot still tracks by ID — so the channel itself is fine.
If the channel's permission overrides were reset (e.g. by a role restructure), run /honeypot again and re-submit the form without changes. The bot will re-apply the correct @everyone overrides.
FAQ
Can a real user accidentally trigger the honeypot?
Yes, in theory — if they read the warning message in the channel and still send a message, or if they don't notice the channel name and warning. In practice it's extremely rare with a well-named channel and a clear warning message.
If it does happen: with Softban, the user can rejoin immediately via any invite link. With Ban, you'll need to go to Server Settings → Bans and manually unban them. This is one reason Softban is the default.
Why not just use a verification bot?
Verification bots (CAPTCHA, reaction roles, etc.) add friction for all new members — including legitimate ones. Honeypot adds zero friction to real users and only catches bots in the act. The two approaches are complementary: use both for maximum coverage.
What about bots that don't send messages?
Honeypot only catches bots that send messages. It doesn't detect lurkers, selfbots that only read, or bots that use other attack vectors (inviting to external servers, DM spam, etc.). It's one layer of defence, not a complete solution.
Can I use the same honeypot channel for multiple purposes?
Technically yes, but it's not recommended. Any message triggers the action, so even a bot with legitimate access to your server could trigger it if it writes there. Keep the channel exclusively for the trap.
Does the bot see the content of trigger messages?
The bot receives the full message object (it needs it to delete the message), but it doesn't log or store message content anywhere. Only the user ID, action, and timestamps are saved.
How does the kick counter work?
The counter is per-server and increments on every successful moderation action. It's displayed on the warning message embed inside the honeypot channel as a button ("Kicks: N"). Clicking the button shows an ephemeral stats popup with the server total and a link to the web dashboard.
What is "Components V2" and why does it matter?
Components V2 is Discord's newer message composition system that allows structured layouts —
containers, sections, separators, and thumbnails — rather than just embeds. Honeypot uses it
for the warning message and stats popup to create a cleaner, more informative UI. It requires
the IS_COMPONENTS_V2 message flag (1 << 15) to be set.
Older Discord clients don't support it, but all current clients do.