Skip to content

Discord Bot: Common Issues

Learn how to fix common Discord bot issues, from invalid tokens and missing intents to entry files, packages, and slash commands

24 November 20266 min read8 Views0 helpful

Introduction

Is your Discord bot not coming online, crashing, or not responding? Don't worry—most issues are easy to fix yourself. This guide covers the most common problems, their causes, and what you can do about them in your Discord bot server dashboard and the Discord Developer Portal.

Problems and solutions

Your most important tool is the Console tab. It shows the bot's complete output, including the error message that caused startup to fail. Lines with [discord-bot] come from ZapX and show what happens during startup, such as which runtime and entry file are used.

Bot won't start or crashes

If your bot crashes immediately after every startup and restarting doesn't help, ZapX stops it. The page header will show Crashed along with the detected cause. Under Crashed — what now?, you'll find the appropriate next step. Your bot files and settings are preserved.

Invalid token

Discord rejects your bot's login. The Console might show An invalid token was provided (discord.js) or Improper token has been passed (discord.py).

  • In the Discord Developer Portal, go to Bot → Token → Reset Token to create a new token. Resetting it immediately invalidates the old token.
  • Enter the token in the Bot Configuration section of the Settings tab, save, and restart your bot.
  • Make sure you copy the Bot Token, not the Application ID or Client Secret.

If your bot was migrated from the old panel and uses its own code, it often reads the token from its own files, usually config.json or .env. In that case, change it there in the Files tab.

Missing intents

Your bot is requesting permissions that aren't enabled in the Developer Portal. Discord then immediately disconnects it. The Console might show Used disallowed intents (discord.js) or PrivilegedIntentsRequired (discord.py).

Open your application in the Developer Portal, go to Bot, and enable the intents your bot uses under Privileged Gateway Intents. These are usually the Message Content Intent, and often the Server Members Intent or Presence Intent as well. Click Save Changes and restart your bot.

Discord logins are blocked

Discord limits the number of times a bot can log in within 24 hours. If a bot keeps restarting, it can quickly use up this quota. The Console will then show Not enough sessions remaining.

The dashboard shows when you can start the bot again. In the meantime, fix the underlying cause of the crash, or the quota will be used up again as soon as the bot starts.

Entry file not found

The Console might show Cannot find module '…/index.js' (Node.js) or can't open file 'main.py' (Python). The configured entry file isn't where ZapX expects it to be.

  • In the Settings tab, check whether Runtime and Entry File match your bot. The path is relative to the top-level folder of your bot, for example, index.js or src/index.js.
  • If you uploaded a ZIP archive, extract it in the Files tab using Extract. If your files end up in a subfolder, move them to the top-level folder. ZapX only looks for your package.json or requirements.txt there.
  • ZapX runs a .ts entry file directly with the Node.js runtime, so you don't need to compile it first.
Missing packages

The Console might show Cannot find module 'discord.js' (Node.js) or ModuleNotFoundError: No module named 'discord' (Python).

  • ZapX installs packages on every startup from package.json (Node.js, Bun) or requirements.txt (Python). The file must be in the top-level folder of your bot.
  • For Node.js, ZapX only installs dependencies. Packages your bot needs to run must not be listed only under devDependencies.
  • In the Dependencies tab, you can add packages directly from npm or PyPI using Add Package.
  • If the audioop module is missing with Python 3.13, your bot is using an older version of discord.py. Update discord.py or select Python 3.12 under Runtime.
Disk space is full

If your bot has run out of disk space, ZapX stops it automatically and won't let it start again until space is available. In the Files tab, delete files you no longer need, such as old log files or downloads created by your bot. Keep an eye on usage in the Statistics tab. If you need more space on an ongoing basis, you'll find larger plans under Manage Plan.

Required settings are missing

If you see the message Required settings are missing when starting your bot, a required value is missing—usually the Discord Bot Token. Marketplace bots may also require another field, such as the Owner User ID. Fill in the specified fields in the Settings tab, save, and start your bot.

Bot is online but not working

My bot isn't on my Discord server

A bot doesn't join a Discord server by itself. You need to invite it once using an invite link:

  1. Open your application in the Developer Portal and go to OAuth2 → URL Generator.
  2. Select the bot and applications.commands scopes, then select the permissions your bot needs.
  3. Open the generated link, choose your server, and confirm by clicking Authorize.

If you want to make your bot private and Discord says “Private application cannot have a default authorization link,” first set the Install Link to None under Installation. Then you can turn off Public Bot under Bot.

My bot doesn't respond to messages
  • If your bot needs to read messages, the Message Content Intent must be enabled in the Developer Portal and requested in your code. In discord.js, use GatewayIntentBits.MessageContent; in discord.py, use intents.message_content = True.
  • If your bot doesn't have permissions in a channel, Discord will report Missing Access or Missing Permissions in the Console. Check your bot's role and the channel permissions on your Discord server.
Slash commands aren't showing up
  • Globally registered commands can take up to an hour to appear everywhere in Discord. To test them, register commands for a single server—they'll appear immediately.
  • Check that you invited your bot with the applications.commands scope.
  • Reload your Discord client so it fetches the command list again.

See How to Program a Discord Bot with JavaScript and How to Program a Discord Bot with Python for registration examples.

Commands end with “Unknown interaction”

Your bot must respond to a slash command within three seconds, or Discord rejects the request. The Console will then show Unknown interaction. If a task takes longer, such as a database query, acknowledge the command first using interaction.deferReply() in discord.js or interaction.response.defer() in discord.py, then send the actual response afterward.

Changes don't take effect or are missing

My file changes are gone after a restart
  • Git repository connected: On every startup, ZapX downloads the latest version of your branch. Any files you changed manually are overwritten; only files such as .env and config.json are kept. Make changes to your code in the repository and sync it.
  • Marketplace bot: ZapX writes values you enter in the Settings tab, such as tokens or IDs, to the bot's configuration on every startup. Make changes to those values there, not in the file. If Load latest template version before every startup is enabled, starting the bot also resets its files to the latest version.
New settings aren't applied

Changes in the Settings tab only take effect after a restart. If your bot is running when you save, ZapX briefly restarts it. For Marketplace bots, the preset determines Runtime and Entry File; you can't change these fields there.

Preventive measures

Regular backups can save you a lot of stress and trouble. We already back up your Discord bot automatically every day. With ZapX Pass, you can also create your own backups at any time in the Backups tab and restore them with a click. Be sure to create a backup before making major changes to your code or switching runtimes.

Warning

Never share your bot token or upload it to a public Git repository. If it does become public, reset it immediately in the Developer Portal using Reset Token.

Can't find a solution or need clarification?

Still having problems after troubleshooting? Our support team is here for you every day. Just start a Support Chat in your ZapX customer account and describe your issue in as much detail as possible, preferably with an excerpt from the Console. We'll look into it as soon as possible and help you resolve the issue!

Conclusion

With these tips, you can solve the most common issues with your Discord bot yourself. For step-by-step instructions on setting up your bot, see Set Up Your Discord Bot. If you have more questions or need help, our support team is available every day! 🙂

Free tools

Tools for Discord servers and bots

View all

FAQ

Frequently asked questions

Check the Console tab for the error message. Common causes include an invalid bot token, missing Privileged Gateway Intents, an incorrect entry file, or missing packages.
Your bot is requesting Privileged Gateway Intents that aren't enabled in the Discord Developer Portal. Enable them under Bot—usually the Message Content Intent—save, and restart your bot.
After too many restarts, Discord temporarily blocks a bot from logging in. The dashboard shows when you can start it again. Fix the cause of the crash in the meantime.

Feedback

Was this article helpful?

Your feedback helps us prioritize and improve content.

0 of 0 people found this article helpful.

Personal support

Need more help than the guide provides?

Our ZAP-Hosting support team knows your product — briefly describe your issue and we'll help you personally.

Zappy knows this guide and answers you right in the chat.