Counting made effortless... and free!

Track monitors, blogs, hits, and more! No Signup, No Keys

---

Total Requests

---

Active Keys

---

SLA Uptime

Introduction

CountAPI is a spin-off of the beloved OG countapi.xyz. Unfortunately, the service is no longer available to the public as a free API due to widely unknown reasons. This service has been created as a very simple alternative to countapi.xyz in hopes of getting some users back on their feet again.

Although this API is a slightly more limited version than the original, it serves a very similar purpose, and I hope it will fulfill the needs of most users looking for something similar. If not, please feel free to email me directly at [email protected] and I would be happy to talk! Until the massive traffic explosion I am totally expecting, be satisfied with what you've got. It is free after all!

By the way, this project is open source! Feel free to check it out on GitHub.

TL;DR

Each "counter" is defined by a key.

Always use a very unique key, as namespaces don't exist, making overwriting a key very easy and very likely.

All keys and their values are public. Never store any confidential contents on these servers.

To increment a counter (by +1), send a GET request to:

https://countapi.mileshilliard.com/api/v1/hit/your_key

{
  "key": "your_key",
  "message": "Key updated successfully",
  "value": "3"
}

Overview

This API is hosted similarly to the OG countapi. The high-level overview can be seen below.

  • Python Backend (serverless)
    • "get"
      • Redis Backend Contacted
    • "set"
      • Redis Backend Contacted

Endpoints

/api/v1/get/your_key

Get the current value set to the key.

/api/v1/get/your_key - 200
{ "key": "your_key", "message": "Key requested successfully", "value": "3" }
/api/v1/get/your_key - 404
{ "error": "Key not found" }

/api/v1/set/your_key

Set the value of the key.

/api/v1/set/your_key?value=100 - 200
{ "key": "your_key", "message": "Key set successfully", "old_value": "4", "value": "100" }
/api/v1/set/your_key - 400
{ "error": "No value provided" }

/api/v1/hit/your_key

Hit (increase by +1) the value of your key.

/api/v1/hit/your_key - 200
{ "key": "your_key", "message": "Key updated successfully", "value": "101" }
/api/v1/hit/your_key - 400
{ "error": "No value provided" }

/api/v1/status

Get the current status of the API.

/api/v1/status - 200
{ "message": "API is running", "uptime": "0:00:00" }

/health

General ping-able endpoint. Good for monitoring uptime.

/health - 200
{ "message": "API is healthy" }
/health - 500
N/A

FAQ

This API is designed to provide a simple and free way to keep track of counts using unique keys.

Ping an endpoint.

There is no rate limiting on this API.
Not any more... someone had to ruin it for the rest of us. It's still generous, but you'll know when you hit it.

No. Keys do not expire. You can always just create a new one.

Please shoot me an email before you try to.