Skip to content
yurna
  1. Documentation
  2. Moderation
  3. Automod: rules against invites, links, mentions and spam

Automod: rules against invites, links, mentions and spam

Let yurna set up Discord’s built-in AutoMod rules for you – in the dashboard or with /automod.

SetupCommandsDashboardModerationSecurity

Quick look

This is how it looks in Discord – with sample data.

A shield against scams and spam.

Scam links, spam waves or a raid at three in the morning: yurna steps in before your team wakes up and files everything in the case file.

Discord · #generalSample data

FreeNitro_42

Free Nitro! Get it here: disc0rd-gift.example

Interactive demo with sample data. Nothing is changed on a real server.

A scam link comes in. Step 1 of 3

Automod keeps your chat clean without anyone having to watch it. yurna creates rules in Discord’s own AutoMod and manages them for you. Because Discord enforces the rules itself, they apply instantly – before a message even shows up in the channel, and even if yurna is briefly offline.

There are five Discord rules and one filter of yurna’s own:

  • Anti-Invite – blocks messages containing Discord server invites (e.g. discord.gg/… or discord.com/invite/…).
  • Anti-Link – blocks messages containing links, server invites and other URLs.
  • Anti-Mention – blocks messages with too many unique user or role mentions.
  • Anti-Spam – turns on Discord’s spam detection.
  • Anti-Badwords – uses Discord’s word lists for profanity, sexual content and slurs (command only).
  • Bad-word filter – yurna’s own filter with German and English default lists, your own words and detection of disguises like “sh1t”.

In the dashboard#

How to set it up#

  1. Open Moderation & safety → Automod (/dashboard/<server>/automod).
  2. Turn a rule on with the switch at the top of its card. This takes effect immediately.
  3. Under Exemptions, pick the roles and channels the rule should ignore.
  4. Under Actions, choose what should happen. At least one action is required, otherwise you can’t save.
  5. Click Save.

Anti-Badwords has no card in the dashboard. Turn it on with /automod anti-bad-words enable in chat – or use the Bad-word filter, which you can fully configure in the dashboard.

Rule settings#

  • Ignored roles and Ignored channels – these roles and channels don’t trigger the rule. Members with Administrator or Manage Server permissions are always exempt.
  • Delete message – the triggering message is blocked and never appears.
  • Time out member – available for Anti-Invite, Anti-Link and Anti-Mention. You pick a duration between 1 minute and 1 week.
  • Log to channel – Discord posts an alert in the selected channel for every hit.
  • Mentions per message (Anti-Mention only) – 2, 5, 10 or 20 mentions in the dashboard; 1 to 50 via command (default 5). Discord’s mention raid protection is always on for this rule.

Bad-word filter#

The Bad-word filter card sits below the rules:

  • Words: Default list German, Default list English and Your own words (one word or phrase per line). Under Allowed words you add words that should never trigger. How many own words you can add depends on your plan.
  • Detection: Detect disguises (e.g. digits instead of letters) and Matching: Whole word (recommended) or Also inside words.
  • Actions: delete the message, Warn (1 point in the case file), timeout, Case in the case file, Short note in the channel and an Alert channel for your team.
  • Exemptions: roles as well as channels or whole categories.
  • Also as a Discord AutoMod rule: mirrors your list into Discord’s AutoMod as well.
  • Try it: enter a text and see whether and why the filter triggers.

View automod hits at the top of the page takes you to the server log, filtered to Automod.

By command#

Everything in the dashboard also works with /automod. You need "Manage Server", and yurna needs the same permission. If you leave an option out, it stays unchanged. For exemptions, add several roles or channels as mentions; - means “none”.

CommandWhat it doesImportant options
/automod settingsshows the current Automod settings–
/automod anti-invite enableturns on Anti-Inviteexempt-roles, exempt-channels (one role or one channel or category each), timeout (seconds, 5–120), log-channel
/automod anti-link enableturns on Anti-Linklike Anti-Invite
/automod anti-mention enableturns on Anti-Mentionlike Anti-Invite, plus limit (1–50, default 5)
/automod anti-spam enableturns on Anti-Spamexempt-roles, exempt-channels, log-channel
/automod anti-bad-words enableturns on Discord’s word listsprofanity, sexual-content, slurs (each on/off), plus exempt-roles, exempt-channels, log-channel
/automod anti-invite disableturns the rule off – likewise anti-link, anti-mention, anti-spam and anti-bad-words with disable–
/automod actions <rule>changes an existing rule like in the dashboardrule: invites, links, spam or mentions; enabled, block (block the message on/off – off only works if a timeout or alert channel stays), timeout (no timeout up to 1 week), alert-channel, remove-alert, mention-limit, exempt-roles, exempt-channels
/automod filter showshows the bad-word filter–
/automod filter settingsconfigures the bad-word filterenabled, list-de, list-en (default lists), leetspeak (disguises), mode (whole word or substring), alert-channel, remove-alert, exempt-roles, exempt-channels, discord-rule (also as a Discord rule)
/automod filter actionssets what happens on a hitdelete, warn, timeout (minutes, 0 = off), case-file (case in the case file), notice (note in the channel)
/automod filter word-add <words>adds your own wordswords: comma-separated
/automod filter word-remove <words>removes your own wordswords: comma-separated
/automod filter allow-add <words>allows words that never triggerwords: comma-separated
/automod filter allow-remove <words>removes allowed words againwords: comma-separated
/automod filter test <text>checks a text against the filtertext: the text

Note

If the rule already exists, enable simply turns it back on – new options are not applied. Change exemptions and actions with /automod actions or in the dashboard instead.

Common questions#

Why does yurna say “There is already a spam rule”?#

Discord allows only one spam rule, one word list rule and one mention rule per server. If another bot or someone manually already created such a rule, yurna won’t delete it but reports the conflict. Disable or delete the other rule under Discord → Server Settings → AutoMod.

Why can’t I add another rule?#

Discord allows at most six keyword rules. Anti-Invite and Anti-Link use one each, and so does the Discord rule of the bad-word filter.

Why aren’t moderators blocked?#

That’s intended – anyone with Manage Server or Administrator is always exempt from AutoMod.

The command reports missing permissions – what now?#

yurna needs the “Manage Server” permission to create and edit AutoMod rules. You need it too.

Where can I see what Automod blocked?#

In the server log as “AutoMod stepped in”. If you also want hits in a channel, enable the event in the event logs.

Automod is included in every plan. Only the number of your own words in the bad-word filter depends on your plan.

See also#

Last updated on 30 October 2026