How to Set Up DiscordSRV on Your Minecraft Server
Install DiscordSRV to bridge your Minecraft Java server chat with a Discord channel — bot setup, channel ID, console mirroring, and account linking.
DiscordSRV is the most-installed plugin for connecting Minecraft and Discord. It bridges in-game chat to a Discord channel, mirrors join/leave/death messages, optionally streams console output to a private staff channel, and supports account linking so Discord roles can sync to in-game permissions.
What DiscordSRV Does
| Feature | Default state |
|---|---|
| Chat sync (Minecraft ↔ Discord) | Enabled |
| Join / leave / death announcements | Enabled |
| Player list in Discord (slash command) | Enabled |
| Console mirroring to a Discord channel | Optional |
| Account linking (Discord ↔ Minecraft) | Optional |
| Discord role → Minecraft group sync | Optional (requires LuckPerms) |
| Webhook avatars (player faces in Discord) | Optional |
Prerequisites
- A Discord server you have admin access to
- A Discord bot you create (this guide walks through it)
- Bukkit / Spigot / Paper Minecraft server
Step 1: Create the Discord Bot
Open the Discord Developer Portal
Go to discord.com/developers/applications and click New Application. Name it (e.g., "MyServer Bridge").
Add a bot user
In the left sidebar, click Bot. Click Add Bot → Yes, do it!.
Disable Public Bot (only you should be able to invite it).
Enable required intents
Still on the Bot page, scroll down to Privileged Gateway Intents and enable:
- ✅ Server Members Intent
- ✅ Message Content Intent
Click Save Changes.
Without these intents, DiscordSRV won't see chat messages or member updates. This is the #1 setup mistake.
Copy the bot token
Click Reset Token → Yes, do it! → Copy. Save this token somewhere private.
Critical: Treat the bot token like a password. Anyone with it can control your bot. Never paste it in a public chat or commit it to git.
Step 2: Invite the Bot to Your Discord
Open the OAuth2 URL Generator
In the left sidebar, click OAuth2 → URL Generator.
Select bot permissions
At minimum:
- ✅ Read Messages / View Channels
- ✅ Send Messages
- ✅ Manage Messages (for chat editing/deletion)
- ✅ Embed Links
- ✅ Read Message History
- ✅ Use External Emojis
- ✅ Add Reactions
For role sync also add:
- ✅ Manage Roles
Open the generated URL
Copy the URL at the bottom and open it in your browser. Select your Discord server and click Authorize. The bot is now in your Discord (offline until DiscordSRV starts).
Step 3: Get the Channel ID
Enable Developer Mode in Discord
In Discord (your client, not the dev portal): User Settings → Advanced → Developer Mode → ON.
Right-click your target channel
Right-click the chat channel where you want Minecraft messages to appear (e.g., #minecraft-chat) → Copy Channel ID.
Step 4: Install DiscordSRV
Stop the server
In the XGamingServer Panel, open Console and stop your server.
Upload to plugins/
Click Files in the sidebar. Upload DiscordSRV-Build.jar to plugins/.
Start once to generate config
Start the server. DiscordSRV creates plugins/DiscordSRV/config.yml. It will warn that the bot token is missing — that's expected. Stop the server again.
Step 5: Configure DiscordSRV
Edit config.yml
Open plugins/DiscordSRV/config.yml in Files.
Set the chat channel ID
Find the Channels section:
Channels:
global: "1234567890123456789"Replace with the channel ID from Step 3.
(Optional) Set up the console channel
For staff-only console mirroring, find:
DiscordConsoleChannelId: "0987654321098765432"Set it to a private channel ID — never make this public, as console output may contain sensitive information.
Save and start the server
Click Save Content. Start the server. DiscordSRV connects to Discord and the bot status changes to Online.
Test it
Send a message in the configured Discord channel — it should appear in Minecraft chat. Type something in Minecraft chat — it should appear in Discord.
Common Configuration Tweaks
Use Webhooks for Player Avatars
In config.yml:
Experiment_WebhookChatMessageDelivery: true
Experiment_WebhookChatMessageUsernameFormat: "%displayname%"
Experiment_WebhookChatMessageAvatarUrl: "https://crafatar.com/avatars/%uuid%?size=64&overlay"Now Minecraft messages appear as the player's skin avatar in Discord, not the bot.
Customize Join / Leave Messages
In messages.yml:
MinecraftPlayerJoinMessage:
Embed:
Color: "00ff00"
Author:
Name: "%displayname% joined"
ImageUrl: "https://crafatar.com/avatars/%uuid%"Disable Death Messages
MinecraftPlayerDeathMessage:
Enabled: falseAccount Linking
Players run /discord link in Minecraft, get a code, and message it to the bot in Discord. Once linked, you can sync Discord roles to in-game groups (requires LuckPerms).
Discord → Minecraft Role Sync
In synchronization.yml:
GroupRoleSynchronizationGroupsAndRolesToSync:
"vip": "111111111111111111" # in-game group: discord role ID
"donator": "222222222222222222"Players with the Discord role automatically get the Minecraft group on join.
Useful In-Game Commands
| Command | Description |
|---|---|
/discord | DiscordSRV info |
/discord link | Get a linking code |
/discord broadcast <message> | Send to chat channel |
/discord reload | Reload config |
/discord debug | Generate debug report |
Slash Commands in Discord
DiscordSRV registers Discord slash commands automatically:
| Command | Description |
|---|---|
/list | Show online players |
/link | Link your Discord account to Minecraft |
/linked | View your linked account |
Common Issues
| Problem | Fix |
|---|---|
| Bot stays offline | Wrong bot token, or intents not enabled — check Step 1 |
| Discord chat not appearing in Minecraft | Wrong channel ID, or Message Content Intent not enabled |
| Minecraft chat not appearing in Discord | Bot lacks Send Messages permission in that channel |
Channel ID isn't a valid number | Channel ID was pasted with quotes or whitespace — clean it up |
Error: 401 Unauthorized | Token is invalid — generate a new one in the dev portal |
Channel not found | Bot isn't in the server, or wrong channel ID |
| Account linking doesn't work | Players need to DM the bot — they can't /discord link from a server channel |
| Webhooks don't show avatars | Enable webhook experiment in config |
Common Mistakes
| Mistake | Fix |
|---|---|
| Forgetting to enable Message Content Intent | Enable in Discord Developer Portal → Bot → Privileged Intents |
| Using a public channel for console mirroring | Console output can contain sensitive info — use a private channel |
| Sharing the bot token publicly | Reset it immediately in the Dev Portal |
| Bot not in the Discord server | Re-run the OAuth2 URL invite |
| Putting quotes around the channel ID in YAML | DiscordSRV expects them — keep the quotes |
| Editing config while server is running | Stop server first, then edit |
| Turning on too many features at once | Start minimal — chat sync only — then add features as needed |
Related Guides
How is this guide?

How to Install and Configure ClearLagg on Your Minecraft Server
Install ClearLagg to auto-clear ground items and entities on your Minecraft Java server, reducing entity lag and improving TPS.
How to Install and Set Up Dynmap on Your Minecraft Server
Install Dynmap on your Minecraft Java server to render a live, browsable web map of your world with player tracking, multi-world support, and full renders.