TL;DR
Scryfall is the premier Magic: The Gathering card search API. Search over 100,000 unique MTG cards by name, set, color identity, mana value, format legality, and creature type. Returns card images, ruling text, price data, and Oracle-style wording. Supports fuzzy name matching, autocomplete, and advanced query syntax similar to Scryfall's web search. No API key required.
Quick start: https://api.scryfall.com/cards/search?q=combo
No API key needed — free and open MTG card data!
How to Use This API
1. Search Cards by Name
Search for any card using Scryfall's syntax — supports fuzzy matching, color filters, and more:
https://api.scryfall.com/cards/search?q=lightning+bolt+t:instant
2. Autocomplete a Card Name
https://api.scryfall.com/cards/autocomplete?q=black+lot
3. Get a Random Card
https://api.scryfall.com/cards/random
4. JavaScript — Search with Filters
fetch('https://api.scryfall.com/cards/search?q=c%3Ablue+t%3Amerfolk')
.then(r => r.json())
.then(data => {
data.data.forEach(card => {
console.log(card.name, '-', card.set_name);
console.log(' Mana:', card.mana_cost);
console.log(' Type:', card.type_line);
console.log(' Rarity:', card.rarity);
});
});
5. Python — Get Card Rulings
import requests
card = requests.get(
'https://api.scryfall.com/cards/named?exact=Counterspell'
).json()
rulings = requests.get(card['rulings_uri']).json()
for ruling in rulings['data']:
print(f"[{ruling['published_at']}] {ruling['comment']}")
https://api.scryfall.com/cards/search?q=combo
Frequently Asked Questions
- What card data does Scryfall return?
- Every card includes Oracle name, mana cost, type line, Oracle text, set name, collector number, rarity, artist, image URIs, prices (USD/EUR/TIX), and legalities for all formats.
- How do I search for cards in standard?
- Use
format:standardin the query string. Combine withf:standardto restrict to Standard-legal sets only. - Does it support image retrieval?
- Yes — each card object includes
image_uriswith PNG versions: small, normal, large, and art_crop. Borderless and extended-art variants are included where available. - Can I get price data?
- Yes. The
pricesfield contains USD, EUR, and TIX (MTGO) prices updated daily. Prices are in theusd,usd_foil,eur, andtixsubfields. - Is there a rate limit?
- Scryfall allows up to 10 requests per second. For bulk operations, use the /cards/search endpoint with pagination rather than many individual card lookups.
- Does Scryfall support bulk data exports?
- Yes — the /bulk-data endpoint returns downloadable JSON files for the entire card database (Oracle cards, unique cards, default cards, and rulings). Updated daily.
API Details
- API URL
https://api.scryfall.com/- Documentation
- scryfall.com/docs/api
- Category
- Games
- Authentication
- Not Required
- Rate Limit
- 10 requests per second
What You Can Build
- Deck builder with card search, filtering, and mana curve visualization
- Price tracker for collecting and monitoring MTG card values
- Format legality checker for tournament preparation
- Random card generator for drafting or commander challenges
- Collection manager with set completion tracking and wishlist