Upload and start your Discord bot
Published on 3 October 2026
You get your bot online by uploading your files, putting your token in a .env file and letting the server install your packages. Then you start it from the console. This guide assumes a Node.js bot built with discord.js; the differences for Python and Java are in the questions at the bottom.
What do you need?
- Your bot code with a
package.json, pluspackage-lock.jsonif you have one. - Your bot token from the Discord Developer Portal.
- The name of your entry file, for example
index.js.
Which language and version should you pick?
Open your bot in the game panel and go to Startup. Under Discord Bot Runtime, choose Node.js Bot; the game panel then sets the matching Docker Image for you. Pick Node.js 24 or 26 under Docker Image: according to its own documentation, discord.js 14.27 needs Node.js 24.17.0 or newer. Enter your entry file under Startup File.
How do you upload your files?
- Go to File managers, click Upload and choose Upload Folder for your project folder. SFTP works too.
- Make sure
package.jsonsits in the main folder. - Don’t upload the
node_modulesfolder. The server builds it for you.
How do you keep your token safe?
Never put your token in your code. Open Bot Studio and choose Env Editor. Click Add Variable, name it TOKEN, paste your token as the value and click Save .env. It’s stored in the .env file in your main folder. In your code, load it with the dotenv package: require('dotenv').config(), then use process.env.TOKEN.
How do you install your packages and start the bot?
- Go to Settings and choose Reinstall Server. Your own files stay where they are.
- The server reads your
package.jsonand installs your packages. With apackage-lock.jsonyou get exactly the versions listed in it. - Once the installation has finished, go to Console and click Start.
- When you see the message your bot prints on login, such as
Logged in as ..., it’s online. It keeps running after you close the game panel.
To update: stop your bot, upload the changed files and start it again. Added packages to package.json? Run Reinstall Server again first.
What if your bot won’t start?
Everything your bot reports shows up in the console. Find the first error message. If it says Cannot find module with the name of your own entry file, Startup File is wrong. If it names a package, the installation didn’t work: run Reinstall Server again and watch the console to see where it fails. Intents and Discord error codes are covered in Keep your Discord bot online 24/7.
What are the common mistakes?
- Uploading
node_modulesfrom your own computer. Our bots run on Linux servers with ARM processors, so packages with compiled code from a Windows PC won’t work there. Let the server install them. - Packages under devDependencies. The installation skips those. Put what your bot needs under dependencies.
- Your token in your code or on GitHub. If it leaks, click Reset Token in the Discord Developer Portal and put the new token in
.env.