Overview

The Dog CEO API serves random dog images from the Stanford Dogs Dataset, organized by breed. No auth needed—it returns direct image URLs, perfect for building a dog photo app.

Beginner Tip

Use /api/breeds/image/random for one image. Append a breed name like /api/breed/husky/images/random for breed-specific photos.

Available Data

The kind of data this API exposes, based on its documentation. We could not call the endpoint to confirm the exact field names.

random dog image URLs
breed and sub-breed lists
breed-specific images

Example Response

Illustrative shape only — we were not able to call this endpoint (it requires credentials or exposes no public sample URL), so the fields below show the kind of data this API returns rather than a recorded response.

JSON Response · Illustrative
{
  "message": "https://images.dog.ceo/breeds/retriever-golden/n02099601_1.jpg",
  "status": "success"
}

Field Reference

message URL of the random dog image—use this as your img src attribute
status API response status, always "success" on valid requests

Implementation Example

Calls a real endpoint of this API. Replace any placeholder credentials with your own key.

Request
const url = "https://dog.ceo/api/breeds/image/random";
const response = await fetch(url);
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

Generated guidance based on this API's documentation, not observed by us. Treat it as a starting point and check against the provider's own error reference.

404 breed not found Using a breed name not in the dataset or with incorrect casing
First call /api/breeds/list/all to get the exact list of valid breed names
Slow image load Images are large JPEGs hosted on dog.ceo CDN
Display a loading spinner while the image fetches; consider caching URLs client-side
Sub-breed 404 Using /breed/spaniel without specifying a sub-breed when multiple exist
List sub-breeds via /api/breed/spaniel/list before requesting images

Metadata Score Breakdown

Estimated from metadata — endpoint not independently tested

This score is estimated from observable metadata — HTTPS support, authentication model, declared CORS, and documentation reachability — because the API requires authentication or exposes no publicly testable endpoint. The five-signal breakdown is only shown for live-tested APIs.

Metadata estimate · endpoint not independently tested

Technical Specifications

Auth No Auth
HTTPS REQUIRED
CORS YES
Category Animals
Difficulty Beginner
Listing details not endpoint-verified

Related Tags

Recipes Using Dogs

Build something with this API. Each recipe includes step-by-step instructions and code outlines.

Similar APIs

View All →