Every Discord bot starts the same way, and it isn't with code. Before your bot can do anything, it has to exist as an application in Discord's own dashboard, get a secret token, and be invited to a server. This guide covers that whole half — the part every language-specific guide assumes you've already done. At the end you'll have a token in hand and a (still offline) bot sitting in your server, ready for code to bring it to life.
| At a glance | |
|---|---|
| You need | a Discord account and a server you own or have Manage Server permission on |
| Time | about ten minutes |
| Plan | none — no Falix server needed yet, this all happens on Discord's side |
1. Create the application
Go to the Discord Developer Portal and click New Application. Give it a name (this is the bot's name to start with — you can change it later) and accept the terms. You now have an application: a container for one bot, its token, and its permissions.
2. Open the Bot page and copy the token
In the left sidebar, open Bot. Discord attaches a bot user to every application, so it's already there waiting.
Under the username you'll see the token controls. Click Reset Token, confirm, and Discord shows you the token once. Copy it now and keep it somewhere safe. Three things to burn into memory:
- You only see it once. Navigate away without copying and you'll have to reset again.
- Resetting invalidates the old token. If a running bot was using the previous token, it stops working until you paste the new one in.
- Never share it or commit it to Git. The token is your bot — anyone who has it can control it completely. Treat it like a password.
That string is what you'll paste into your code's .env file later. If you're not setting up hosting today, just save it securely.
Optional: give it a face and decide who can invite it
While you're on the Bot page, two quick extras worth doing now:
- Avatar and description. Click the bot's avatar to upload an image — that's the face people see in the member list. The application's description, set on the General Information page, shows up in the bot's About Me profile.
- Public Bot toggle. Just below the token, Public Bot is on by default, meaning anyone who has your invite URL can add the bot to their own server. If this bot is only for you, switch it off — then only you, the app owner, can invite it anywhere.
3. Decide which intents you need
Intents are Discord's way of asking "what kinds of events does this bot actually need?" Most stay on by default. Three are privileged and have their own toggles on this same Bot page:
| Intent | You need it when |
|---|---|
| Message Content | your bot reads the text of messages — prefix !command bots, auto-moderation, reacting to what people type (not slash commands) |
| Server Members | you want member join/leave/update events |
| Presence | you want members' online status and activities |
Turn on only what your code uses. And if you're just building slash commands (which the starter guides do), you can leave all three off.
⚠️ Heads up: If your code asks for a privileged intent you haven't enabled here, Discord rejects the login outright.
4. Build the invite link
A bot can't add itself — you generate an invite URL and open it. In the sidebar go to OAuth2 → URL Generator:
- Under Scopes, tick
botandapplications.commands. The second one is what lets your slash commands register in the server, so don't skip it. - A Bot Permissions box appears below. Tick what your bot needs — Send Messages at minimum, plus things like Embed Links, Connect/Speak (for voice), or Manage Roles depending on your plans. Grant the least you need.
- Copy the generated URL at the bottom.
5. Invite it to your server
Paste that URL into your browser. Discord asks which server to add the bot to — pick one you have Manage Server on — then confirm the permissions and Authorize.
Verify it worked
Open your Discord server and look at the member list. Your bot is there — shown offline (grey). That's exactly right. The application exists, it's a member of your server, but nothing is running it yet.
🎯 Good to know: A bot is just a program somewhere on the internet holding a connection open with that token; until that program is running, the bot is dark.
That "somewhere" is what the next guides set up on Falix.
Troubleshooting
- Closed the token dialog before copying — no way to recover it; click Reset Token again and copy the new one.
- The URL Generator only offers a few permissions — you didn't tick the
botscope; select it and the Bot Permissions box appears. - Bot never showed up in the server — the invite only works on servers where you have Manage Server; also re-open the URL and make sure you clicked Authorize.
- Can't toggle a privileged intent — you don't need to for slash-command bots. Only enable one when your code actually requests it.
Pick your language
You have a token and an invited bot. Now give it code to run:
- Host a discord.js bot — JavaScript, the most popular choice.
- Host a discord.py bot — Python.
- Host a TypeScript Discord bot — typed JavaScript.