API Directory › 🐾 Animals › Cataas
No authHTTPSCORS

Cataas API

'Cat as a service' — random cat images and gifs, optionally with text.

Category
Auth
No auth needed
HTTPS
Yes
CORS
Yes
Open Cataas docs ↗

What it does

Cataas (‘Cat as a Service’) returns a random cat image or GIF directly — no JSON needed — with optional caption text, tag filtering, resizing and image filters applied on the fly. Point an <img> tag at it and you have a cat.

Base URL

https://cataas.com

Authentication

None. /cat (random), /cat/gif, /cat/says/{text}, /cat/{tag} (e.g. /cat/cute), /cat/{id}. Add ?json=true to get metadata instead of the image.

Code examples

HTML
<img src="https://cataas.com/cat" alt="random cat">
<img src="https://cataas.com/cat/says/hello%20world?fontSize=40&fontColor=white">
curl (metadata)
curl -s "https://cataas.com/cat?json=true"
# { "_id": "...", "tags": ["cute"], "url": "/cat/...", ... }

Rate limits & quotas

No documented rate limit — it just serves images. Query params: ?width=, ?height=, ?fit=, ?filter= (mono, negate, custom), plus caption styling (fontSize, fontColor, fontBackground).

Key response fields

(image mode)The raw JPEG/PNG/GIF bytes — usable directly as an <img> src
(?json=true) _idImage id — reuse via /cat/{id}
(?json=true) tags[]Tags on that image
(?json=true) urlRelative path to the image

Common errors

404Unknown tag or id — list tags at /api/tags.
(caption not showing)URL-encode the text in /cat/says/ and check fontColor contrasts with the image.

When to use it (and alternatives)

The lowest-effort way to drop a cat into a page, a 404, a Slack bot or a demo — no JSON parsing, no key. For structured cat breed data use The Cat API; for dogs, dog.ceo.

FAQ

How do I add a caption?

https://cataas.com/cat/says/Your%20text, with optional ?fontSize=50&fontColor=white&fontBackground=black. Remember to URL-encode spaces and punctuation.

Can I get the same cat every time?

Yes — fetch once with ?json=true, store the _id, and use /cat/{id} thereafter.

Does it support GIFs?

Yes — /cat/gif, and you can combine with tags (/cat/gif/cute) and captions.

New to APIs?

Short guides for working with this API — and any other.

🛠️ Handy LarzOS tools

Free tools to help you work with this API.

JSON Formatter

Related Animals APIs

← Back

More Animals APIs · All 196 APIs