Telegram
Free Telegram bot hosting.
Get a token from BotFather, upload your code, press start. No domain, no certificate, no webhook to configure unless you want one.
Choose a runtime
Pick your language
All three are installed and tested. Each page covers the libraries, the deployment and what fits in 256 MB for that runtime specifically.
Long polling is why this is easy
Telegram lets a bot receive updates two ways. A webhook means Telegram makes an HTTPS request to you, which means a public domain, a valid certificate and a port the internet can reach. Long polling means your bot asks Telegram for updates over an outbound connection it opens itself.
Long polling needs none of the infrastructure a webhook does, and it is what every library here does by default. On a free allocation that is not a compromise — it is the reason a Telegram bot deploys in about the time it takes to upload the files.
Telegram bots are light
There is no equivalent of Discord's member cache. Telegram sends you the updates addressed to your bot and nothing else, so the memory your bot uses is roughly the memory your own code asks for. A bot handling a few thousand users a day rarely troubles 256 MB.
The two things that do cost you are state you keep yourself and files you move. Conversation state held in a dictionary for every user who ever messaged the bot will grow forever unless you expire it, and media passing through your server has to land on disk before it goes back out.
What to watch instead of memory
Rate limits. Telegram enforces its own, roughly a message a second to a given chat and a much lower ceiling for broadcasts, and a bot that ignores them gets throttled no matter how good its hosting is. Every serious library has a queue or a limiter; use it.
Disk, if you handle media. You have 512 MB, which is plenty for a bot that passes photos through and deletes them, and not enough for one that archives every file it is sent. Clean up after yourself, or write to somewhere else.
FAQ
Questions
Do I need a domain or an SSL certificate?
Not for long polling, which is what almost every self-hosted Telegram bot uses and what the libraries default to. You would only need a domain and a certificate if you specifically wanted Telegram to push updates to you over a webhook.
Can I use webhooks here?
It is not what this is set up for. You get an allocated port rather than a public HTTPS hostname, so a webhook would need you to put your own terminating proxy in front of it. Long polling avoids the whole question and behaves identically from your users' point of view.
Where do I get a bot token?
From BotFather inside Telegram itself. Message it, create a bot, and it hands you a token. That token goes into an environment variable on your server here, never into your source code.
Can my bot send files, photos or voice notes?
Yes. Be deliberate about the disk: anything you download lands in your 512 MB, and a bot that saves everything it is sent will fill that quota faster than you expect. Delete temporary files once you have forwarded them.
Node.js, Python or Bun for a Telegram bot?
Both ecosystems are strong here, which is not true of every platform on this site. Pick the language you already write. If you are choosing from scratch, Python has the longer-established libraries and Node has the lighter memory baseline. Bun runs the same npm packages as Node.js with a faster start; if a library misbehaves under it, Node.js is the fallback.
Hosting something else?