Discord Bot Hosting: What a Bot Actually Needs
Discord bot hosting without the guesswork: what a bot really consumes, why free tiers keep dropping it, and how small a server you can honestly buy.
Discord bot hosting is the first server bill most communities ever pay, and it is usually paid twice. Once on a free tier that keeps going quiet, and again on the real thing a month later. A bot is a small program that stays logged in to Discord and reacts to what happens in your server. Small is the operative word. What it needs is not power. It is a machine that never stops.
What a Discord bot actually consumes#
A bot holds an open connection to Discord's gateway, which is a socket that stays up and streams events at your code. It does almost nothing between those events, so the CPU graph on a healthy bot is a flat line with occasional spikes. Memory is the number that moves, and it moves for reasons that have little to do with how many people are in your server.
- The library and runtime. A Node or Python process with discord.js or discord.py loaded starts at tens of megabytes before your own code does anything. That floor is fixed, and it is most of what a simple bot ever uses.
- The cache. Libraries keep members, channels, and roles in memory so your commands can answer without a round trip. Join a few large servers and that cache, not your code, becomes the biggest thing in the process.
- What you bolted on. Music is the classic surprise: audio encoding is real CPU work, and every concurrent voice connection is another stream. A music bot is a different sizing question from one that posts embeds.
- The database. If levels, economy, or moderation logs are involved, something is storing them. SQLite on the same disk costs nearly nothing. A Postgres container next to the bot is fine too, but budget for it rather than discovering it.
One knob on Discord's side changes the shape of all this. Gateway intents decide which events your bot is sent at all, so a bot that does not need message content should not ask for it, and one that does not need presence updates should not subscribe to the firehose of them. Discord treats the sensitive ones as privileged and gates them behind verification past a server count it sets; the current rules live in Discord's gateway documentation.
Why free tiers keep dropping your bot#
Free hosting is built around web apps that wake up when a request arrives and sleep when none does. A bot is the opposite shape: it has no inbound traffic at all, and it needs to be awake precisely when nothing is asking it for anything. Platforms that idle out quiet processes will idle out a working bot, and the symptom is the one everyone recognises, where the bot is offline until somebody nudges it.
The other half is the reconnect. Every restart means a fresh gateway login, and a bot that flaps through them looks to Discord like a bot behaving badly. A machine that simply stays on removes the whole class of problem.
How small a server you can honestly buy#
Small. This is not the workload to over-buy for. Our Foundational (F) line exists for exactly this shape of job: a process that must be up, does not need a fast core, and is not going to grow teeth overnight. These are live figures, read from the same pricing data the order pages use:
| Plan | vCPU | RAM | RAID-10 storage | Transfer | Monthly | Yearly |
|---|---|---|---|---|---|---|
| F10 | 1 | 2 GB | 24 GB | 4 TB | Annual terms | $43.20/yr |
| F20 | 2 | 3 GB | 36 GB | 6 TB | Annual terms | $64.80/yr |
| F30 | 2 | 6 GB | 72 GB | 12 TB | $12.00/mo | $129.60/yr |
| F40 | 2 | 8 GB | 96 GB | 16 TB | $16.00/mo | $172.80/yr |
| F50 | 3 | 12 GB | 144 GB | 24 TB | $24.00/mo | $259.20/yr |
| F60 | 4 | 16 GB | 192 GB | 32 TB | $32.00/mo | $345.60/yr |
| F70 | 6 | 24 GB | 288 GB | 48 TB | $48.00/mo | $518.40/yr |
The entry tier holds a text bot with room to spare, and gateway events are far too small to trouble the transfer allowance. Those plans run on enterprise Intel hardware with hardware RAID-10 SSD storage, one free automated backup, full root access, a web rescue console, and a credit-backed 99.9 percent network uptime SLA. Root access matters more than the specs here, because a bot needs a process supervisor and a place to keep secrets, and shared hosting gives you neither.
Move up a tier when the bot starts doing work rather than answering. Music, image generation, scraping, or a language model in the loop all turn a flat CPU line into a busy one. If that is the direction, the Performance (P) line is the better landing spot, and our post on running a self-hosted AI agent covers what changes once a bot starts thinking.
One server, several bots#
The economics only make sense once you notice a bot does not need a machine to itself. A single small server comfortably runs several bots, the database behind them, and a scheduled job or two, because they are all idle at the same time. That is the same argument we made for game server hosting versus a VPS: one box you control beats several subscriptions that each do one thing.
Run each bot as its own service so one crash does not take the others down. Our guide to running an app as a systemd service covers restart-on-failure and start-on-boot, which is the entire reason you are buying a server. To keep each bot's dependencies separate, Docker and Compose does the same job with more isolation.
The parts that actually break#
Nobody's bot dies of insufficient RAM in month one. It dies of these instead.
- The token in the repository. A bot token is a password. Keep it in an environment file the service reads, never in the code you push, and regenerate it the moment it leaks.
- Nothing restarting it. A bot started by hand in an SSH session dies with that session. That is what the service file is for.
- An unlocked front door. Bots do not need inbound ports. Close what you are not using with our firewall guide, and log in with SSH keys rather than a password. Both are ten-minute jobs on a fresh server, alongside the rest of first steps on a new Linux server.
- No copy of the database. The bot is replaceable. Two years of levels and warnings are not. See backups and data protection.
FAQ#
How much RAM does a Discord bot need?
Less than people expect. A text bot in one or two servers lives inside the entry tier of our Foundational line with headroom. The number climbs with library cache in large servers, and with music or media features, not with member count on its own.
Can I host a Discord bot for free?
You can start one for free. Keeping it up is the hard part, because free platforms are built to idle out processes with no inbound traffic, which is exactly what a bot is. If the bot matters to your community, buy the smallest real server instead.
Do I need a VPS, or will shared hosting do?
You need a VPS. Shared hosting runs web requests, not long-lived background processes, and it does not give you the root access a service supervisor requires. We covered the wider version of that trade in shared hosting versus a VPS.
Can one server run more than one bot?
Yes, and it usually should. Bots are idle most of the time, so several of them plus a database sit happily on one small machine. Give each its own service so they fail independently.
