Google Analytics logo

uabot is a google analytics discord bot. It allows you to link your Discord server to a Google Analytics account and track some information. It tracks messages sent, members added, and members removed. It also tracks voice channel entry, games being played, and when users come online. It does not provide accurate information on anything beyond these metrics, because the analytics portion is not being run on the end-user’s system.

In addition, the bot will provide analytics to me, bot developer, on Discord servers added and removed.


Once you’ve invited the bot to your server, your first step will be to sign up for a Google Analytics account and create a property.

Configure the property as a Website, and give it some name that makes sense to you. The Website URL is also not important, so again make it something that makes sense to you. Once you’ve entered the required information here, click the Get Tracking ID button at the bottom of that page.

Once you have the Tracking ID, go back to your Discord server and use the track command from uabot to provide your tracking ID.

uabot Dashboard

I have also developed a Google Analytics dashboard template that you can import into your property. This dashboard provides a decent run-down of the information that uabot reports on.


  • .ua help – Get a DM from the bot providing details on the bot and help information for the commands.
  • .ua track – Provide the Google Analytics tracking ID for your property.
    Example: .ua track UA-XXXX-YY
  • .ua test – Will send a test event to your Google Analytics property with the category of test and the action of sent.


Since I do not intend to actively develop and update this bot, I have decided to make the code available here. If you intend to use it, you’ll want to edit config.json and package.json to enter your own values there for author and various IDs. This bot was developed using the following: