This is the website that is hosted at https://http.cat.
The code for the older version hosted at the heroku platform is at the http-status-cats-api repo.
This version does not need any server side code. The API behavior is provided by a Nginx server config.
On v2.0.0 the website was built with React and pre-rendered with react-snap.
As of v3.0.0 it's built with Next.js 13.
There's a Postman collection with requests for the HTTP status cats, created by @SubramanyaRaj5. Use the button below to import it into your Postman app.
You can make your own Nginx server show HTTP Cats on its error pages with the integrations/nginx/http-cats.conf snippet. Download it to your Nginx snippets folder:
sudo wget -O /etc/nginx/snippets/http-cats.conf https://raw.githubusercontent.com/httpcats/http.cat/master/integrations/nginx/http-cats.conf
Then include it in the server block(s) where you want the cats:
server {
# ...
include snippets/http-cats.conf;
}Reload Nginx with sudo nginx -t && sudo systemctl reload nginx, and visit a page that doesn't exist to see the 404 cat.
A few things to keep in mind:
- The original status code is kept, only the response body is replaced by the cat image.
- A
locationthat defines its ownerror_pagedoesn't inherit these. - If Nginx is a reverse proxy for an app, add
proxy_intercept_errors on;to thatlocationso the app's error responses also get cats. - Each error page is fetched from http.cat, so if it's unreachable Nginx falls back to its default error page.
Based on this gist by @mjmeyer, suggested by @mishailovic in #126.
npm run dev
Runs the tests.
npm run build
Creates a build of the project.
Currently not all HTTP status codes are covered. You are welcome to create an issue or PR to cover them.
We've prepared some templates to make this process easier.
You can clone it, replace the information with the new one and export as a JPG image.
Then, upload it to both public/images and public/images-original folders and update the statuses.js file.
Finally you need to add a markdown file in /content/<status-code>.md with a
description of the status code and links to official documentation. Please
follow the format of already existing files.
Also, copy this file over to /content/ca and ask Copilot, ChatGPT or Google,
etc to translate the content to Catalan.
Thanks to @girliemac for creating the amazing http status cats images.
Thanks to @pfdborges for creating the http.cat logo (RIP my friend).
Please consider sponsoring or donating via the following options:
You can also adopt an HTTP Cat and have your name in the chosen cat image!
MIT