Entertainment — entry 005 of 9

JokeAPI

Verified Jul 2026

JokeAPI (Sv443) serves programmable jokes across 7 categories — Misc, Programming, Dark, Pun, Spooky, Christmas, and a catch-all Any — with content filtering by flag (nsfw, religious, political, racist, sexist, explicit) so integrators can enforce a safe-mode. A single GET can return the response as JSON, XML, YAML, or plain text via a `format` query parameter, and jokes come as either single one-liners or two-part setup/delivery pairs. It's free, keyless, open source, and self-hosted by its maintainer with no paid tier.

JokeAPI (Sv443) is a keyless joke API filterable by category and content flags. A live GET to `/joke/Programming?type=single` returned one one-liner joke as JSON, and the same call with `format=xml` returned the identical joke re-serialized as `application/xml` — both confirmed by this run's probes, not carried over from the stored summary.

jokeshumorcontent-filteringmulti-formatkeyless
AuthenticationNone requiredCall it straight away — no key, no signup.
HTTPSSupportedTraffic is encrypted in transit.
CORSEnabledCallable directly from browser JavaScript.
PricingFreeNo paid tier — free for the documented use case.
FormatsJSON, XML, YAML, TextResponses can be requested as JSON or XML or YAML or Text.

GreatAPIs Score

Score80out of 100
Authentication25/25No authentication required
Pricing20/20Free to use
Docs0/20No docs or spec available
Formats15/15Supports 4 response formats
Freshness20/20Verified within 6 months

Embed this badge

Scored 80 on greatapis.com
<a href="https://greatapis.com/api/jokeapi/"><img src="https://greatapis.com/badge/jokeapi.svg" alt="Scored 80 on greatapis.com"></a>

Auth quickstart

  1. No API key required — the live probes above returned data with no auth header sent at all.
  2. Every response carries live rate-limit headers — `ratelimit-limit: 120`, `ratelimit-remaining`, `ratelimit-reset`, and `retry-after: 60` — confirmed on this run's probes, so read `ratelimit-remaining` before looping calls rather than guessing at a budget.
Stored keyNo key stored

Your key is stored only in this browser (localStorage) and sent directly to the API — never to greatapis.

Get a single Programming joke as JSON

GEThttps://v2.jokeapi.dev/joke/Programming?type=single

200 application/json; charset=UTF-8

{
    "error": false,
    "category": "Programming",
    "type": "single",
    "joke": "Eight bytes walk into a bar.\nThe bartender asks, \"Can I get you anything?\"\n\"Yeah,\" reply the bytes.\n\"Make us a double.\"",
    "flags": {
        "nsfw": false,
        "religious": false,
        "political": false,
        "racist": false,
        "sexist": false,
        "explicit": false
    },
    "id": 34,
    "safe": true,
    "lang": "en"
}

Captured byte-for-byte from this run's live probe; JokeAPI picks randomly from the matching pool per call, so a repeat request can return a different `id`/`joke` from the same category.

Developer reference

Base URLhttps://v2.jokeapi.dev
Rate limit

120 requests per 60s window, confirmed live via response headers (ratelimit-limit: 120, ratelimit-remaining, ratelimit-reset, retry-after: 60)

Gotchas & limits

  • `format=xml` genuinely changes the wire format, not just a label: a live probe of `/joke/Programming?format=xml&type=single` returned `content-type: application/xml; charset=UTF-8` with a `<data><joke>...</joke></data>` body, re-serializing the same fields JSON returns.
  • A filter combination with zero matches 400s with a structured error, it doesn't fall back to a random joke: a live probe of `/joke/Programming?type=single&contains=zzzznonexistentxyz123` returned HTTP 400 with `{"error":true,"internalError":false,"code":106,"message":"No matching joke found",...}`.
  • Rate-limit headers are real and live, confirmed on every probe this run: `ratelimit-limit: 120`, a decrementing `ratelimit-remaining`, and `retry-after: 60` (seconds until the window resets) — the field this category's `rateLimit` entry now cites.
  • The `api-info` response header self-reports the exact running version — this run's probes all returned `api-info: JokeAPI v2.3.3 (https://v2.jokeapi.dev)` — useful for confirming which server build served a given response.