Articles on: Community Tutorials

How to make a live status page for your bot (Node.js)

Welcome to SomethingHost!

In this guide, you will learn how to create a live status page that tracks uptime and can notify when your bot is down.

So how it works?

We will be using an express app to display an OK status on some page for your server. Find where you created your express app, if you do not have that yet, you can check out our subdomain guide. We will send an OK status to that specified page, and when your bot is offline it the entire page will be down. Enter in the following code near your express app.

app.get("/ping", function (request, response) {
  response.sendStatus(200) // display's "OK" on the page

Head over to Freshping and enter your service's URL e.g. and email. Once you are logged in you can navigate to the Dashboard to view all of your checks. Click Add Check in the top right corner to open the checks menu.

Then we need to add your service URL. It is best to add a slug at the end of the URL in case you want to use other pages for your bot. You can change the slug, /ping, to whatever you'd like, as long as it matches the code we will use later on in this guide. The other settings can be useful, but that isn't the main goal of this article.

Once you add your check, it may take a few moments to connect. You'll then want to create an actual Status page to display the check. Simply go to the Status tab and create your page. Make sure to enable the check for the page you made before.

Updated on: 28/12/2022

Was this article helpful?

Share your feedback


Thank you!