Games & Comics — entry 075 of 75
Yu-Gi-Oh!
YGOPRODeck's API covers the full Yu-Gi-Oh! TCG/OCG card pool — stats, card text, archetypes, banlist status, and images at multiple resolutions — backing the same database that powers the ygoprodeck.com deck-building site. It's fully keyless with no registration or paid tier; the old `db.ygoprodeck.com` docs subdomain now redirects to the current `ygoprodeck.com/api-guide/` reference.
YGOPRODeck's API covers the full Yu-Gi-Oh! TCG/OCG card pool, queryable by exact name. A live GET this run against /cardinfo.php?name=Dark%20Magician returned a genuine 11,215 B card object at HTTP 200, content-type: application/json, access-control-allow-origin: * — no key or signup of any kind.
GreatAPIs Score
Auth quickstart
- No API key, signup, or credit card required — the live GET above returned real card data with no auth header attached, and the docs ask only that callers cache results rather than re-querying identical lookups.
Your key is stored only in this browser (localStorage) and sent directly to the API — never to greatapis.
Look up a card by exact name
GEThttps://db.ygoprodeck.com/api/v7/cardinfo.php?name=Dark%20Magician
{
"data": [
{
"id": 46986414,
"name": "Dark Magician",
"typeline": ["Spellcaster", "Normal"],
"type": "Normal Monster",
"humanReadableCardType": "Normal Monster",
"frameType": "normal",
"desc": "''The ultimate wizard in terms of attack and defense.''",
"race": "Spellcaster",
"atk": 2500,
"def": 2100,
"level": 7,
"attribute": "DARK",
"archetype": "Dark Magician",
"ygoprodeck_url": "https://ygoprodeck.com/card/dark-magician-4003",
"...": "card_sets (dozens of printings), card_images, card_prices omitted -- full object is 11,215 B"
}
]
}A live GET this run against /cardinfo.php?fname=Blue-Eyes&num=1&offset=0 (fuzzy-name search) returned a real card ("Blue-Eyes Abyss Dragon") at HTTP 200 — num requires offset to be present alongside it, confirmed live, or the fuzzy search parameters are rejected.
Try it
Developer reference
https://db.ygoprodeck.com/api/v720 requests/second per IP; a 1-hour block follows if exceeded -- per ygoprodeck.com/api-guide/.
- GET/cardinfo.php
- GET/cardsets.php
- GET/checkDBVer.php
Gotchas & limits
- The live API is served from
db.ygoprodeck.com, not the entry's ownurlhost — a live GET this run againsthttps://ygoprodeck.com/api/v7/cardinfo.php?name=Dark%20Magicianreturned 404 with an 80,329 B HTML page, not a redirect. The docs subdomain itself is different: a live probe this run founddb.ygoprodeck.com/anddb.ygoprodeck.com/api-guide/both 301-redirect to theirygoprodeck.comequivalents — only the/api/v7/...path stays put ondb.. - A no-match query is HTTP 400, not 404 — a live GET this run against
?name=NotACardreturned 400,application/json, 136 B:{"error":"No card matching your query was found in the database. Please see https://db.ygoprodeck.com/api-guide/ for syntax usage."}. - Flavor text wrapped in doubled apostrophes is not a systematic rule — Dark Magician's
descabove reads''The ultimate wizard...''live this run, but two other classic Normal Monsters checked the same way this run, Mystical Elf and Baby Dragon, came back with plain unwrappeddesctext and no apostrophes at all. Don't strip or unwrap apostrophes from every card's flavor text. typeline(array) andtype(string) carry different information on the same object, confirmed live above: Dark Magician'stypelineis["Spellcaster", "Normal"]whiletypeis the plain string"Normal Monster". Treating them as duplicates loses data.GET /randomcard.phpis not itself a data endpoint — a live probe this run returned HTTP 301, redirecting to/cardinfo.php?num=1&offset=0&sort=random&cachebust(a plaincardinfo.phpquery with a random sort). Following it live returned a real single-card object (200, 3,212 B this run), but a client that doesn't follow redirects only sees the 301.