1 credit per call7 endpoints5 datapointsChecked working 25 Nov 2026
CoinGecko API
CoinGecko API for coin search, coin details, price history, listings, markets, exchanges and trending coins as JSON. 1 credit per successful call.
{
"success": true,
"data": {
"query": "bitcoin",
"search": [
{
"id": "bitcoin",
"name": "Bitcoin",
"symbol": "btc",
"image": "https://coin-images.coingecko.com/coins/images/1/large/bitcoin.png",
"rank": 1
},
{
"id": "bitcoin-cash",
"name": "Bitcoin Cash",
"symbol": "bch",
"image": "https://coin-images.coingecko.com/coins/images/780/large/bitcoin-cash-circle.png",
"rank": 23
},
{
"id": "bitcoin-cash-sv",
"name": "Bitcoin SV",
"symbol": "bsv",
"image": "https://coin-images.coingecko.com/coins/images/6799/large/BSV.png",
"rank": 123
}
],
"pagination": {
"page": 1,
"per_page": 100,
"total": 25,
"total_pages": 1,
"has_more": false
}
},
"meta": {
"endpoint_family": "search",
"source": "coingecko",
"request_id": "req_21ed862f82f6429dbc64faa5211564f3",
"credits_charged": 1,
"credits_remaining": 999
}
}Sample data
What one call returns
A recorded run of search: the fields and shapes you will get, shortened to 3 items.
| # | idstring | namestring | symbolstring | imageurl | rankinteger |
|---|---|---|---|---|---|
| 1 | bitcoin | Bitcoin | btc | https://coin-images.coingecko.com/coins/images/1/large/bitcoin.png | 1 |
| 2 | bitcoin-cash | Bitcoin Cash | bch | https://coin-images.coingecko.com/coins/images/780/large/bitcoin-cash-circle.png | 23 |
| 3 | bitcoin-cash-sv | Bitcoin SV | bsv | https://coin-images.coingecko.com/coins/images/6799/large/BSV.png | 123 |
[
{
"id": "bitcoin",
"name": "Bitcoin",
"symbol": "btc",
"image": "https://coin-images.coingecko.com/coins/images/1/large/bitcoin.png",
"rank": 1
},
{
"id": "bitcoin-cash",
"name": "Bitcoin Cash",
"symbol": "bch",
"image": "https://coin-images.coingecko.com/coins/images/780/large/bitcoin-cash-circle.png",
"rank": 23
},
{
"id": "bitcoin-cash-sv",
"name": "Bitcoin SV",
"symbol": "bsv",
"image": "https://coin-images.coingecko.com/coins/images/6799/large/BSV.png",
"rank": 123
}
]id,name,symbol,image,rank bitcoin,Bitcoin,btc,https://coin-images.coingecko.com/coins/images/1/large/bitcoin.png,1 bitcoin-cash,Bitcoin Cash,bch,https://coin-images.coingecko.com/coins/images/780/large/bitcoin-cash-circle.png,23 bitcoin-cash-sv,Bitcoin SV,bsv,https://coin-images.coingecko.com/coins/images/6799/large/BSV.png,123
Recorded from our API · 3 items shown · 5 datapoints per itemGET /v1/coingecko/search?q=bitcoin
5 datapoints
Identity
- idstring
- namestring
Reputation
- imageurl
Other
- symbolstring
- rankinteger
Playground
Run this API
curl "https://api.perceptlayer.com/v1/coingecko/search?q=bitcoin" \
-H "X-API-Key: $API_KEY"CoinGecko · 7 endpoints
Endpoints
Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.
| Endpoint | Required parameters | Returns | Cost |
|---|---|---|---|
GET/v1/coingecko/coin | id+1 optional | coin | 1 credit |
GET/v1/coingecko/exchanges | none+2 optional | idnamecountryurlimagetrust_score+3 more | 1 credit |
GET/v1/coingecko/history | id+2 optional | iddayscurrencypointshistory | 1 credit |
GET/v1/coingecko/listings | none+5 optional | idsymbolnameimagerankprice+16 more | 1 credit |
GET/v1/coingecko/markets | id+2 optional | idmarketspagination | 1 credit |
GET/v1/coingecko/search | q+2 optional | idnamesymbolimagerank | 1 credit |
GET/v1/coingecko/trending | none+1 optional | idcoin_idsymbolnameimagerank+4 more | 1 credit |
Overview
About the CoinGecko API
What you can get
The CoinGecko API returns CoinGecko crypto market data as JSON through 7 endpoints.
- Search:
searchtakes aq, withpageandper_page. - One coin:
cointakes anid, withcurrency(USD,EUR,GBPorBTC). - Price history:
historytakes anid, withdaysandcurrency. - Listings:
listingstakespage,per_page,currency,categoryandorder(market_cap_desc,volume_desc,volume_asc,id_ascorid_desc). - Markets:
marketstakes anid, withpageandcurrency, and lists the trading pairs for that coin. - Exchanges and trending:
exchangestakespageandper_page;trendingtakes an optionalcurrency.
The recorded search for "bitcoin" returns query, search and pagination. Each result has id, name, symbol, image and rank, and pagination reports a total of 25 matches on one page. The first result is bitcoin at rank 1, followed by bitcoin-cash and bitcoin-cash-sv.
How a call works
Search, then read the coin: GET /v1/coingecko/search?q=bitcoin, with your key in the X-API-Key header, returns each coin's id. Pass that to coin, history or markets, for example GET /v1/coingecko/history?id=bitcoin&days=30, which returned 31 points, each with timestamp, price, market_cap and volume. Check has_more in pagination before asking for the next page. Every successful call costs 1 credit; failed calls cost nothing.
More finance APIs
Use cases
Rank coins by market cap or volume with `listings`
Use the CoinGecko API to rank coins by market cap or volume with `listings`Chart a coin's price, market cap and volume over `days`
Use the CoinGecko API to chart a coin's price, market cap and volume over `days`Compare a coin's price and volume across trading pairs with `markets`
Use the CoinGecko API to compare a coin's price and volume across trading pairs with `markets`Watch which coins are trending
Use the CoinGecko API to watch which coins are trendingFAQ
Questions
How much does the CoinGecko API cost?
Each successful call costs one credit, whichever endpoint you call, and each page is one call. New accounts get free credits to start, and credit packs bring the price down as you scale.
Which currencies can prices come back in?
`coin`, `history`, `listings`, `markets` and `trending` take a `currency` of `USD`, `EUR`, `GBP` or `BTC`.
What format are responses in?
Every endpoint returns JSON, with no HTML parsing on your side.
Do I need a CoinGecko account?
No. You call this CoinGecko API with your Perceptlayer key in the `X-API-Key` header, with no CoinGecko login.
Is this the official CoinGecko API?
No. Perceptlayer is an independent service and is not affiliated with CoinGecko. It returns CoinGecko data as JSON with a Perceptlayer key, so there is no CoinGecko developer account, app review or partner approval to get first. It only reads data: if CoinGecko has an official API and you need to act on your own CoinGecko account, such as posting, managing orders or reading private data, use that one.
Should I build a CoinGecko scraper instead?
You can, but a CoinGecko scraper is code you maintain: page changes break it, requests get blocked, and CoinGecko's terms govern how you collect data. The CoinGecko API gives you 7 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first.
Try the CoinGecko API with 100 free credits
No credit card. Failed calls are never billed.