Coins: 17,148
Exchanges: 1,272
Market Cap: $3.566T 0.8%
24h Vol: $178.549B
Gas: 1.469 GWEI
Go Ad-free
API
TABLE OF CONTENTS

How to Use the CoinGecko API Megafilter Endpoint

4.6
| by
Cryptomaton
|
Edited by
Carissa Tan
-

The cryptocurrency ecosystem is vast and fragmented, featuring thousands of DEXs and other protocols that operate in isolation. Additionally, onchain data—especially around liquidity pools—is raw and unfiltered, often containing low-quality pools, such as scam tokens or inactive projects.

To help users navigate this noisy landscape, CoinGecko has introduced the Megafilter API endpoint. It aggregates data across multiple chains, liquidity pools, and DEXs into a single, unified view, allowing users to query and filter everything in one request. This makes it easier to surface relevant data tailored to their specific use cases and products.

In this article, we'll explore how to use the Megafilter endpoint and its many filtering options in order to sort, filter, and identify promising liquidity pools for different use cases.

What is the Megafilter Endpoint?

The CoinGecko Megafilter is a robust API endpoint that aggregates data from multiple blockchains, liquidity pools, and decentralized exchanges (DEXs) into a single query. Instead of making separate requests for each network or DEX and having to orchestrate multiple wrappers and RPC gateways, users can retrieve comprehensive market data—including token prices, trading volumes, and liquidity details—through one streamlined endpoint.

It's designed to simplify on-chain data retrieval, making it easier for developers, traders, and analysts to access, sort, and filter cross-chain liquidity pool data. The Megafilter endpoint abstracts away the often overwhelming complexity of aggregating on-chain data. With 200+ blockchain networks, 1,500+ DEXs, 8 million liquidity pools, and 6 million tokens, retrieving relevant data in a standardized format is not a trivial challenge.

The Megafilter endpoint simplifies this by allowing users to slice and dice on-chain data based on their specific needs—filtering by chain, DEX, liquidity pool, or token—all in a single, efficient query. To use it, you will need a CoinGecko API key that you can generate from the Developer Dashboard. The Megafilter is a premium endpoint, and it’s available on the Analyst tier or above.

Let’s dive into the various filtering options the Megafilter provides and how you can leverage its power in your web application, trading bots, and scripts.

Megafilter Basics

One of the Megafilter's core features is its ability to slice and dice on-chain data with ease. When interacting with the Megafilter, users may add one or multiple filtering options; however, any filtering parameters are optional, and users can choose to return the full, unfiltered dataset if desired.

The Megafilter endpoint returns a paginated list of liquidity pool data and can be called via the following route:

https://pro-api.coingecko.com/api/v3/onchain/pools/megafilter

Since it’s paginated, each request must include the ?page= parameter, with any additional parameters chained using the ampersand (&) symbol.

A successful Megafilter endpoint response will look like this, with additional properties nested under the collapsed objects:

The easiest way to experiment with the endpoint firsthand would be to use a tool like Postman to make authenticated requests to the Megafilter.

We’ve put together a simple Postman Collection to help you get started. Simply download the file as JSON and import it into Postman. Note that you will need to configure your API credentials in the top directory.

Chains, DEXs, and Pool Data Filters

With over 8 million liquidity pools across 200+ networks, filtering this data down can be challenging. The Megafilter endpoint allows users to easily create complex filters to find liquidity pools of interest and cut right through the noise.

Filtering by Networks and DEXs

To filter by blockchain networks, use the &networks= parameter and specify either a single network or a comma-separated list of networks. This ensures you retrieve liquidity pool data only from the chains that matter to you.

For instance, to return a paginated list of all available liquidity pools on Solana, your query should look like this:

/v3/onchain/pools/megafilter?page=1&networks=solana

To include other networks, such as Arbitrum, Aurora, and Binance Chain, you simply append those to the original request:

/v3/onchain/pools/megafilter?page=1&networks=solana,aurora,bsc

The networks parameter accepts a comma-separated list of network IDs. These are CoinGecko’s own references to the networks, so you may need to call the Supported Networks List endpoint to fetch the correct ID for the chain (or chains) you’re looking to filter by, as these don’t always reflect the name of the chain.

For instance, the correct Id for Polygon is polygon_pos and will be returned by the networks endpoint in an array that looks like so:

The Networks List endpoint is also useful when filtering by DEXs. To refine results in the Megafilter endpoint based on specific DEXs, use the &dexes= parameter with a comma-separated list of DEXs you would like to refine your search with. 

The &dexes= filter requires exactly one network to be specified in the &networks= parameter—it cannot be empty or contain multiple networks.

Here is an example of retrieving liquidity pools from specific DEXs on Solana:

/v3/onchain/pools/megafilter?page=1&networks=solana&dexes=raydium,orca,meteora

This way, the megafilter will only return liquidity pools from the Raydium, Orca, and Meteora DEXs on Solana.

Since the Megafilter relies on the network IDs for these top-level filters, it may be a good idea to store a list of valid IDs locally so you don’t have to fetch them from the API every time you need them. In a production environment, you may assign a worker to fetch and update those periodically so your application stays up to date with CoinGecko.

Pool Metrics and Advanced Filtering Options

The real power of the Megafilter lies in its ability to refine searches based on pool performance metrics. By combining multiple filters, users can pinpoint pools that align with their specific trading or research strategies.

The Megafilter enables filtering based on:

  • Fully Diluted Valuation: fdv_usd_min, fdv_usd_max

  • Trading Volume: h24_volume_usd_min, &h24_volume_usd_max

  • Reserves: reserve_in_usd_min, reserve_in_usd_max

  • Pool Age: pool_created_hour_min, pool_created_hour_max

  • Transactions: tx_count_min, tx_count_max, buys_min, buys_max, sells_min, sells_max

  • Taxes: buy_tax_percentage_min, buy_tax_percentage_max, sell_tax_percentage_min, sell_tax_percentage_max 

Users can mix and match these filters, along with network and DEX filters. The Megafilter can process any number of filters you throw at it, making it ridiculously simple to cut through the noise and help traders and researchers find the right pools for their respective use cases.

For instance, let’s build on the previous request and narrow down the pool data to only include pools with a fully diluted valuation between $10,000 and $1,000,000, a minimum trading volume of $50,000 and exclude any pools that were created less than 24 hours ago:

/v3/onchain/pools/megafilter?page=1&networks=solana&dexes=raydium,orca,meteora&fdv_usd_min=10000&fdv_usd_max=1000000&h24_volume_usd_min=50000&pool_created_hour_min=24

If you use a tool like Postman, you can visualise your params like this, which is easier to read than query string params:

The great thing about the Megafilter is that you are not restricted in the filters that you choose to include. You may include none, some, or all of the filters as needed. In our example above, we only wanted to filter pools older than 24 hours, so we didn't need to include the pool_created_hour_max param.

Remember to paginate accordingly (page=1, page=2, etc.) to get the next set of results, as the Megafilter endpoint will only return 20 records at a time.

The Megafilter supports sorting in addition to powerful pool data filters. Like any other parameter, the sort option can be layered on top of your existing query filters, adding an extra dimension to your dataset and helping you zero in on the most active or noteworthy pools.

This is done using the sort= parameter, which can help further refine the data with any of the following options:

  • Trending Sorters: m5_trending, h1_trending, h6_trending, h24_trending

  • Pool Data Sorters: h24_tx_count_desc, h24_volume_usd_desc, h24_price_percentage_change_desc, pool_created_at_desc

The trending sorters organize your filtered dataset based on web visits and onchain activities within a specified timeframe. For example, using m5_trending will rank pools by their trending performance over the past five minutes, helping you spot what’s currently gaining momentum. This can be used to find pools that are rising in popularity or identify a potential early entry.

Beyond trending metrics, pool data sorters let you rank results by on-chain performance indicators. You can sort pools by transaction count, trading volume, price change, or creation time. These sorters help surface high-activity pools, fast movers, or newly launched pairs—depending on your use case—and can be layered with other filters for more targeted discovery.

For instance, we can apply any of the sorters above in combination with our chosen filters:

/v3/onchain/pools/megafilter?page=1&networks=solana&sort=m5_trending

This will return a sorted list of all liquidity pools on Solana that have been trending in the last 5 minutes. However, in a practical scenario, you'll likely want to combine this with pool data filters—such as minimum liquidity, volume, or FDV—to narrow down the results, for instance:

/v3/onchain/pools/megafilter?page=1&networks=solana&dexes=raydium,orca,meteora&fdv_usd_min=1000&fdv_usd_max=100000&h24_volume_usd_min=5000&pool_created_hour_max=24&sort=pool_created_at_desc

This query retrieves the most recently created liquidity pools on Solana from Raydium, Orca, and Meteora. It filters for pools that are less than 24 hours old, have a fully diluted valuation between $1,000 and $100,000, and have seen at least $5,000 in trading volume over the past 24 hours. The results are sorted to show the newest pools first, making it easy to spot fresh, active listings with meaningful liquidity.

Note that, as of now, only one sorting option can be selected at a time.

Security & Fraud Protection Filters

There’s one more powerful dimension you can add to your Megafilter queries: trust and social proof filters. These help you cut out suspicious or low-quality pools by filtering for things like honeypot scams, unverified tokens, or pools without community presence. 

By using checks like no_honeypot, on_coingecko, good_gt_score, or has_social, you can refine your results to focus only on pools that meet a baseline of credibility—especially useful when navigating the trenches.

Checks is a parameter that accepts one or more values as comma-separated strings. Adding these security and trust signals to your Megafilter query is as simple as appending the &checks= parameter to your request.

Applied to the previous example, the query would look like this:

/v3/onchain/pools/megafilter?page=1&networks=solana&dexes=raydium,orca,meteora&fdv_usd_min=1000&fdv_usd_max=100000&h24_volume_usd_min=5000&pool_created_hour_max=24&sort=pool_created_at_desc&checks=no_honeypot,good_gt_score,on_coingecko

Or as visualised below:

Final thoughts

The CoinGecko API's Megafilter endpoint provides an advanced tool for exploring liquidity pools across multiple networks and DEXs, making it a fantastic, that can be leveraged in web applications, DEX aggregators, trading bots, and research.

The Megafilter's applications are as varied as the filtering options themselves, and not having to deal with RPC gateways and other chain-specific protocols is a big plus.

If you’re curious to see the Megafilter in action, check out this article where I’ve used SvelteKit, TypeScript, and TailwindCSS to build a modern liquidity pool finder app and display the data in a paginated table. The app is open source and easy to get started with, so you can explore the Megafilter right away.

CoinGecko's Content Editorial Guidelines
CoinGecko’s content aims to demystify the crypto industry. While certain posts you see may be sponsored, we strive to uphold the highest standards of editorial quality and integrity, and do not publish any content that has not been vetted by our editors.
Learn more
Want to be the first to know about upcoming airdrops?
Subscribe to the CoinGecko Daily Newsletter!
Join 600,000+ crypto enthusiasts, traders, and degens in getting the latest crypto news, articles, videos, and reports by subscribing to our FREE newsletter.
Tell us how much you like this article!
Vote count: 10
Cryptomaton
Cryptomaton
Cryptomaton (Andrei Badoiu) is the Co-founder of Aesir, an algorithmic cryptocurrency trading platform. Andrei's expertise lies in working with the evolving intersection of finance and technology, driving innovation that empowers traders and transforms the way they engage with the market. Follow the author on Twitter @cryptomatonblog

More Articles

Select Currency
Suggested Currencies
USD
US Dollar
IDR
Indonesian Rupiah
TWD
New Taiwan Dollar
EUR
Euro
KRW
South Korean Won
JPY
Japanese Yen
RUB
Russian Ruble
CNY
Chinese Yuan
Fiat Currencies
AED
United Arab Emirates Dirham
ARS
Argentine Peso
AUD
Australian Dollar
BDT
Bangladeshi Taka
BHD
Bahraini Dinar
BMD
Bermudian Dollar
BRL
Brazil Real
CAD
Canadian Dollar
CHF
Swiss Franc
CLP
Chilean Peso
CZK
Czech Koruna
DKK
Danish Krone
GBP
British Pound Sterling
GEL
Georgian Lari
HKD
Hong Kong Dollar
HUF
Hungarian Forint
ILS
Israeli New Shekel
INR
Indian Rupee
KWD
Kuwaiti Dinar
LKR
Sri Lankan Rupee
MMK
Burmese Kyat
MXN
Mexican Peso
MYR
Malaysian Ringgit
NGN
Nigerian Naira
NOK
Norwegian Krone
NZD
New Zealand Dollar
PHP
Philippine Peso
PKR
Pakistani Rupee
PLN
Polish Zloty
SAR
Saudi Riyal
SEK
Swedish Krona
SGD
Singapore Dollar
THB
Thai Baht
TRY
Turkish Lira
UAH
Ukrainian hryvnia
VEF
Venezuelan bolívar fuerte
VND
Vietnamese đồng
ZAR
South African Rand
XDR
IMF Special Drawing Rights
Cryptocurrencies
BTC
Bitcoin
ETH
Ether
LTC
Litecoin
BCH
Bitcoin Cash
BNB
Binance Coin
EOS
EOS
XRP
XRP
XLM
Lumens
LINK
Chainlink
DOT
Polkadot
YFI
Yearn.finance
Bitcoin Units
BITS
Bits
SATS
Satoshi
Commodities
XAG
Silver - Troy Ounce
XAU
Gold - Troy Ounce
Select Language
Popular Languages
EN
English
RU
Русский
DE
Deutsch
PL
język polski
ES
Español
VI
Tiếng việt
FR
Français
PT
Português
All Languages
AR
العربية
BG
български
CS
čeština
DA
dansk
EL
Ελληνικά
FI
suomen kieli
HE
עִבְרִית
HI
हिंदी
HR
hrvatski
HU
Magyar nyelv
ID
Bahasa Indonesia
IT
Italiano
JA
日本語
KO
한국어
LT
lietuvių kalba
NL
Nederlands
NO
norsk
RO
Limba română
SK
slovenský jazyk
SL
slovenski jezik
SV
Svenska
TH
ภาษาไทย
TR
Türkçe
UK
украї́нська мо́ва
ZH
简体中文
ZH-TW
繁體中文
Welcome to CoinGecko
Welcome back!
Login or Sign up in seconds
or
Sign in with . Not you?
Forgot your password?
Didn't receive confirmation instructions?
Resend confirmation instructions
Password must contain at least 8 characters including 1 uppercase letter, 1 lowercase letter, 1 number, and 1 special character
By continuing, you acknowledge that you've read and agree fully to our Terms of Service and Privacy Policy.
Forgot your password?
You will receive an email with instructions on how to reset your password in a few minutes.
Resend confirmation instructions
You will receive an email with instructions for how to confirm your email address in a few minutes.
Get the CoinGecko app.
Scan this QR code to download the app now App QR Code Or check it out in the app stores
coingecko
Continue in app
Track prices in real-time
Open App