API Directory › ₿ Cryptocurrency › CryptoCompare
API KeyHTTPSCORS

CryptoCompare API

Crypto price, historical and social data aggregated across exchanges.

Auth
API Key
HTTPS
Yes
CORS
Yes
Open CryptoCompare docs ↗

What it does

CryptoCompare (now part of the CoinDesk data suite) provides real-time and historical prices, OHLCV, order-book snapshots, blockchain and social data, and multi-exchange aggregates. The min-api endpoints are the classic, easy-to-use ones.

Base URL

https://min-api.cryptocompare.com/data

Authentication

Create a free account and generate an API key. Send it as authorization: Apikey YOUR_KEY (header) or ?api_key=YOUR_KEY. Some endpoints respond without a key but at a much lower shared rate.

Code examples

curl
curl -s "https://min-api.cryptocompare.com/data/price?fsym=BTC&tsyms=USD,EUR" \
  -H "authorization: Apikey $CC_KEY"
Python
import requests

r = requests.get("https://min-api.cryptocompare.com/data/v2/histoday",
    params={"fsym": "ETH", "tsym": "USD", "limit": 30},
    headers={"authorization": f"Apikey {KEY}"}, timeout=10)
for row in r.json()["Data"]["Data"]:
    print(row["time"], row["close"])

Rate limits & quotas

The free tier is on the order of 100,000 calls/month with separate per-second, per-minute and per-hour caps. Usage is reported at /stats/rate/limit. Errors come back as JSON with Response:"Error" even on HTTP 200 — check the Message field.

Key response fields

USD / EURIn /price, the value per requested tsym
RAW.<FSYM>.<TSYM>Full quote object from /pricemultifull (price, volume, change)
Data.Data[]OHLCV rows from histoday/histohour/histominute
Response / MessageSuccess or Error plus a reason

Common errors

Response="Error", type 1Missing/invalid parameter (e.g. unknown fsym).
Response="Error", type 99Rate limit exceeded.
401 / 429Bad key, or per-second/minute/hour cap hit.

When to use it (and alternatives)

Good for historical OHLCV and multi-exchange aggregate prices with a large free monthly budget. Compare with CoinGecko for coin metadata and Messari for fundamentals.

FAQ

How do I send the API key?

Either the header authorization: Apikey <key> (note the literal word Apikey) or the query parameter api_key. The header is preferred so the key stays out of logs.

My call returned HTTP 200 but no data.

Check the top-level Response field. When it is "Error", Message explains why (bad symbol, rate limit, etc.).

Which endpoint for candlesticks?

/data/v2/histoday, /histohour or /histominute with fsym, tsym and limit. Minute data is limited to the last 7 days on the free tier.

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.

Crypto PriceCryptoLarz app

Related Cryptocurrency APIs

← Back

More Cryptocurrency APIs · All 196 APIs