Ask coding questions

← Back to all posts
Hosting a Discord bot on Repl
Kiansjet

Hello!

Real quick, I have a stupidly simple NodeJS Discord.js Discord bot I wrote. Am I able to just run it on Repl? I remember seeing a banner saying I could host sites on Repl. Is there a rule against this? Is there an amount of time a Repl VM will run before terminating?

Answered by Zavexeon [earned 5 cycles]
View Answer
Voters
PandamasterLi
TwertleBwo
SuperTux20
Kiansjet
Comments
hotnewtop
Zavexeon

Yes, you can using uptimerobot, like @Vandesm14 and @ash15khng said. I'll give you step by step instructions. Please note that your repl will need a front end (an HTML page).

  1. ) Create an account at https://uptimerobot.com/
  2. ) Login and go to your dashboard on uptimerobot
  3. ) Click "Add New Monitor"
  4. ) In the menu that pops up, set monitor type as "HTTP(S)", give it a friendly name (can be anything you want), and set the URL as the link to the front end (the repl.co one).
  5. ) Set the monitoring time to 30 minutes or less.
  6. ) Click "Create Monitor" at the end of the form.
tradlimb

@Zavexeon How do I create the front end?

Zavexeon

@DomLowe What language?

tradlimb

@Zavexeon Node.JS

Zavexeon

@DomLowe An easy way to create a front end is

decomp

bots go offline at night for me and never are up 24/7

RiccardoGiorgi

@decomp at night: what time more or less?

Vandesm14

You are allowed to host a Discord bot on repl.it
If you use Uptime Robot and setup a ping/http monitor to ping your repl, you can keep it alive forever!

Please mark this as answered if I helped your problem 👍

ash15khng

It will terminate after a while, but you can use something called Uptime Robot to keep your repl up! (not sure how to use it tho only heard of people using it)