Coins: 14,042
Exchanges: 1,073
Market Cap: $2.404T 3.4%
24h Vol: $87.532B
Gas: 15 GWEI
Go Ad-free
Guides
TABLE OF CONTENTS

What Are Liquidity Pools and Crypto Market Liquidity in DeFi

4.8 | by Sankrit K

What Is a Liquidity Pool?

A liquidity pool is a crowdsourced pool of a set of cryptocurrencies that are locked in a smart contract and are used to facilitate trades between the assets on decentralized exchanges. Liquidity providers receive a share of trading fees as incentives for providing liquidity, although they are exposed to risks such as impermanent loss and slippage.


Key Takeaways

  • Liquidity pools are crucial in DeFi, allowing decentralized, intermediary-free trading.

  • Users lock pairs of cryptocurrencies in pools, providing the needed liquidity for trades.

  • Liquidity pools offer open access, letting anyone contribute liquidity and earn fees.

  • Risks include faulty smart contracts, impermanent loss, and high slippage in low liquidity pools.

  • Contributing to a pool involves choosing a platform, depositing token pairs, and managing the position to mitigate risks.


Liquidity Pools DeFi

Acting as a backbone of many protocols, Automated Market Makers (AMMs), synthetic assets, and more, liquidity pools have become critical financial instruments in DeFi by ensuring market stability and inclusivity. Untethered by the centralized entities and middlemen that have long dominated liquidity in traditional finance, liquidity pools recalibrate financial transactions by ensuring more equitable, transparent, and inclusive financial markets. 

In this article, we will look at what liquidity pools are, why they are crucial in DeFi, and how they ensure prices are balanced without human intervention.

Liquidity Pools: Enabling Trades in DeFi

What are Liquidity Pools by CoinGecko

Credits: Sankrit

A liquidity pool is like a mixed bucket of two different cryptocurrencies that allow users to trade freely, unsupervised, and at any time on decentralized exchanges.

So, what are these ‘buckets’?

These buckets are created using smart contracts, where two tokens are locked in a smart contract, thus creating a liquidity pool. These tokens can then be used for trading on decentralized purposes, i.e., they provide ‘liquidity.’ These pools make tokens available so that users can trade freely in a decentralized environment, circumventing the need for an intermediary or a central authority, such as a traditional exchange.

Traditional exchanges often use an “order book” where, for every buyer, there should exist a seller and vice versa.

A DEX, on the other hand, must function without any intervention of third parties or intermediaries. It should be trustless. Therefore, the traditional order-matching system would fail when it comes to trading an illiquid trading token. While it could still be made to work, order-matching becomes a challenge when the trading volume is very low, which is characteristic of new and niche cryptocurrency projects. Hence the development of liquidity pools, which crowdsource liquidity by incentivizing liquidity providers with a share of trading fees in exchange for depositing liquidity into a liquidity pool.

With smart contracts and liquidity pools, an individual can buy or sell without the existence of a counterparty because the trades are executed against the liquidity pool instead of an individual seller or buyer.

How Do Liquidity Pools Work?

There are three parts to the working of liquidity pools in the DeFi ecosystem:

  1. Creation and funding

  2. Trading and pricing

  3. Earning and withdrawal

Creation and Funding

Funding a LIquidity Pool by CoinGecko

Credits: Sankrit

To create a liquidity pool, users must lock up a pair of cryptocurrencies within the smart contract that governs the pools.

The amount being funded (or locked up) must be equal value amounts of both tokens. 

For example, if you are creating a WBTC/ETH liquidity pool, then you must lock up equal values of WBTC and ETH. Note that the value should be equal and not the quantity itself.

Users who lock up their cryptocurrency are known as liquidity providers and receive “liquidity pool tokens (LPTs).” LPTs are digital assets that are representative of the users’ share in the liquidity pool and can be used to withdraw from the liquidity pool in the future.

Trading and Pricing

Trading in a Liquidity Pool by CoinGecko

Credits: Sankrit

The cryptocurrencies in the liquidity pools can be traded by anyone without the need for a counterparty buyer or seller. This works with the help of Automated Market Makers, which facilitate trades directly against the liquidity pool.

The price of the asset is determined based on the supply-demand dynamics of the cryptocurrencies making up the liquidity pool. It is an algorithm that is embedded within the smart contract — the price of an asset goes up as more users buy it and vice versa.

Most liquidity pools us as a constant product market maker (CPMM). Popularized by Uniswap, the CPMM dictates that the product of values of the two assets in a liquidity pool is constant.

Token A * Token B = K

where;

Token A: Value of Token A

Token B: Value of Token B

K: Constant

To purchase Token A, users need to contribute an equivalent value of Token B, ensuring that the product of the two tokens' values or quantities always equates to the constant, K. This mechanism ensures sustained liquidity within the pool. As more of Token A is acquired, the required deposit of Token B escalates, theoretically approaching infinity, making it practically unfeasible to deplete the pool entirely, although it may result in slippage.

This design ensures a self-balancing, perpetual liquidity system, where the scarcity of one token automatically adjusts the required input of the other, preserving the equilibrium and integrity of the decentralized market environment.

Earning and Withdrawal

Earning from Liquidity Pool by CoinGecko

Credits: Sankrit

Liquidity providers (LPs) earn an interest proportional to their share in the liquidity pool. Every time a trade is made in the liquidity pool, the transaction incurs a small fee, which is then fully or partly redistributed to the LPs.

This process of earning cryptocurrencies by providing liquidity to the decentralized market is called “yield farming” or “liquidity mining.”

When needed, LPs can exit the liquidity pool by cashing out their LPTs. They will get the amount back in the pairs of tokens they deposited, plus the interest accrued from the trading activity.

Benefits of Liquidity Pools

While liquidity pools can be volatile, they are a key part of the DeFi ecosystem and offer even small investors an opportunity to earn a share of trading fees. Now, let's take a closer look at some of the benefits of liquidty pools. 

Inherently Decentralized

Liquidity pools are inherently decentralized. This allows them to circumvent constraints and risks that are typically associated with centralized exchanges, such as the exchange holding custody of all customers' funds and the possibility of mismanagement of funds. 

Liquidity pools are an inclusive and accessible financial system that allows users to engage in financial activities with complete autonomy. Anybody can deposit funds to a liquidity pool, thereby creating new markets for people. There is no review or approval process — it is completely permissionless.

Such openness fosters a more inclusive and equitable financial system where anyone can own a stake in the market and power decentralized trading activity.

Low Entry Barrier

Anybody, big investor or small investor, can become a liquidity provider and earn a share of the market. By depositing tokens into the liquidity pool, they become fractional owners of the market, which they can exit by redeeming their liquidity pool tokens. It also provides liquidity providers with a stream of passive income as they can deposit tokens that they aren't actively using to generate interest by depositing them into liquidity pools. 

How Safe Are Liquidity Pools?

While liquidity pools emerged as a solution to power decentralized trading markets, they are not without their risks.

Here are a few risks typically associated with liquidity pools.

Faulty Smart Contracts

Since liquidity pools are governed by smart contracts, they are only as good as the code that makes them up.

A liquidity pool with a bugged smart contract can invite malicious actors to exploit its vulnerabilities and potentially even drain all the funds.

A classic example is that of a flash loan. Flash loans are uncollateralized DeFi loans that one can use and return within a single transaction. Due to the enormous size of the loan, it becomes easy for attackers to manipulate a market by tipping off the asset ratio of a liquidity pool in their favor and leaving the market adversely affected.

Since transactions are irreversible, it is impossible to regain the funds through technical patchwork. The unregulated nature of DeFi and the ability for attackers to be anonymous further add to the damage.

Therefore, before you interact with a smart contract, dig deeper to check if it has been audited by a reputed and independent entity.

Impermanent Loss

The risk of an impermanent loss is inevitable when engaging in yield farming through liquidity pools. Impermanent loss is when the price of assets locked in a liquidity pool deviates adversely from the price they were initially deposited. Since liquidity pools operate based on the ratio set when Liquidity Providers deposited their assets, they don't have an order book which features a permanently updated price for every asset based on buy and sell orders. This means that the price of an asset on DEX could be signifantly lower than its market value. 

Let's take a simplified example of how this could happen:

Say you created a market by depositing 20,000 USDT and 1 BTC. In this example, let's say the price of 1 BTC is 20,000 USDT at the time of creation.

Later, the external markets could have pushed the price of 1 BTC to 25,000 USDT. Arbitrageurs swarming the space will notice this price difference and immediately buy BTC from your pool at a price lower than that of the market until the price balances out.

Now, your pools would have more USDT than BTC.

Let’s put this in numbers, assuming the entire BTC supply has been exhausted.

Initial Deposit

20,000 USDT + 1 BTC

Total pool value in USDT = 40,000 USDT

External Market

1 BTC becomes 25,000 USDT.

At this rate, the value of the liquidity pool should be = 45,000 USDT (because BTC increased by 5,000 USDT)

However, since the pool’s BTC has been exhausted, it will be left with 40,000 USDT and 0 BTC.

Hence, the new pool value = 40,000 USDT. This is 5,000 USDT less than the external market.

This difference of 5,000 USDT is called “impermanent loss.”

It is called “impermanent” because the value of assets in the pool can still achieve their state equivalent of external markets. The loss is permanent only if the liquidity providers exit the pool at the time of an impermanent loss.

If you want to minimize the risk of impermanent loss, then consider providing liquidity to pools with stable assets (low volatility). Stablecoins are an excellent example. Liquidity pools like USDT/USDC or DAI/USDT would experience little to no impermanent loss. Doing so allows liquidity providers to collective incentive rewards and trading fees without exposing themselves to the risk of price volatility.

You can better understand this concept by punching in some numbers in CoinGecko’s impermanent loss calculator to see for yourself.

High Slippage

Slippage is the difference between the expected price of a trade and the actual price at which the trade is executed. This happens because the price of assets in the pool are never constant. For each unit of cryptocurrency that the pool trades, the price of assets in the pool re-adjusts to attain equilibrium with the market maker.

When you initiate a trade, be it buying or selling an asset, the transaction isn’t instantaneous. 

During the finite span between the initiation and confirmation of your transaction on the blockchain, multiple other trades could be occurring concurrently. 

Each of these trades nudges the price, causing a dynamic and perpetual flux.

In a pool teeming with liquidity, individual trades, unless exceedingly voluminous, barely make a ripple, resulting in minimal slippage. However, in a pool characterized by low liquidity, even trades of modest volume can create substantial waves, causing significant price alterations and, consequently, higher slippage.

You can use GeckoTerminal to explore liquidity and volumes across different liquidity pools and trading pairs.

Let’s understand this with an example where we have 2 liquidity pools, A and B.

Pool A (High Liquidity)

  • Total Liquidity: 1,000,000 USDT

  • Trade Value: 5,000 USDT

Scenario

Assuming a trader expects to buy an asset at 10 USDT per unit in Pool A.

  • Expected Price: 10 USDT/Asset

  • Trade Volume: 500 Assets

  • Slippage: 0.1% (negligibly small due to high liquidity)

  • Actual Price Received: 10.01 USDT/Asset

Here, due to high liquidity, the price impact and hence slippage is minimal, allowing the trader to execute the trade almost at the expected price.

Pool B (Low Liquidity)

  • Total Liquidity: 10,000 USDT

  • Trade Value: 5,000 USDT

Scenario

Assuming a trader expects to buy the same asset at 10 USDT per unit in Pool B.

  • Expected Price: 10 USDT/Asset

  • Trade Volume: 500 Assets

  • Slippage: 10% (substantially high due to low liquidity)

  • Actual Price Received: 11 USDT/Asset

Here, due to low liquidity, the price impact and hence slippage are substantial, making the actual price deviate considerably from the expected price. To overcome these limitations, DEXs have been introducing innovative models like Trader Joe's Liquidity Book model that allows liquidity providers to define custom price ranges, enabling greater trading fee generation, while minimizing slippage through "active bins" that are based on the asset's current market value. 

How to Contribute to a Liquidity Pool

Contributing to a liquidity pool is fairly straightforward once you understand the concept and you are familiar with interacting with blockchain networks and using cryptocurrency wallets.

Step 1: Choose a Platform

Select a decentralized exchange platform that supports the creation of liquidity pools, like Uniswap or SushiSwap.

Step 2: Connect Wallet

Connect your cryptocurrency wallet, such as MetaMask or Trust Wallet, to the chosen platform.

Step 3: Choose the Liquidity Pool and Add Liquidity

Choose the liquidity pool you want to contribute liquidity to, and make sure you have a sufficient balance of both tokens in your connected wallet before depositing equal value amounts of both tokens into the pool to add liquidity.

Step 4: Confirm & Approve Transaction

Review the details of the pool and the amount of liquidity you are providing. Approve the transaction from your wallet, confirming the contract interaction.

Step 5: Receive Liquidity Tokens

After confirmation, you will receive liquidity tokens representing your share of the pool. These tokens can be used to reclaim your share of the pool’s assets and any accrued fees. Some platforms will also require you to stake your liquidity tokens in order to collect your rewards.

Step 6: Monitor Pool

Monitor the performance of your liquidity pool and any accrued fees through the platform’s interface.

Evaluate the impact of impermanent loss and consider adjusting your position if necessary.

Optional: Remove Liquidity

If you wish to exit the liquidity pool, you can remove your liquidity by redeeming your liquidity tokens on the platform.

What Are the Different Types of Liquidity Pools?

 

Type of Liquidity Pools

How They Work

Example

Constant Product Pools

Maintain a constant product of the quantities of two tokens, adjusting prices as the ratio changes due to trades.

Uniswap

Stablecoin Pools

Specialized for stablecoins, often utilizing low slippage and low fees, maintaining stable values.

Curve Finance

Smart Pools

Allow pool creators to adjust parameters like fees and weights dynamically, providing flexibility.

Balancer

Lending Pools

Users deposit assets to earn interest and borrowers can take loans against collateral.

Aave

Algorithmic Pools

Uses algorithms to manage pool parameters dynamically, balancing between different assets.

Shell Protocol

Leveraged Liquidity Pools

Enable users to leverage their positions to earn higher returns with increased risk.

Compound

Yield Aggregator Pools

Automate yield farming strategies to find the best returns across different platforms.

Yearn Finance

 

Conclusion

These simple mathematical-constructs-turned-financial-instruments now form the fabric of decentralized finance — enabling asset trading and ownership by removing intermediaries and counterparties.

Liquidity pools are rewriting the fundamental dialogues of trade and transaction, replacing the dialects of restriction and control with lexicons of freedom and autonomy.

They are, however, not without their risks and downsides. With research and knowledge, you can participate as a liquidity provider in a global DeFi landscape.

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
Tell us how much you like this article!
Vote count: 17
Sankrit K
Sankrit K

Sankrit is a content writer and a subject matter expert in web3. He has worked with notable companies, including Ledger, Alchemy, and MoonPay. Sankrit specializes in helping web3 brands create content that is easy to understand while accurately explaining technical concepts.

More Articles

coingecko
Continue in app
Track prices in real-time
Open App
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
繁體中文
Login to track your favorite coin easily 🚀
By continuing, you agree to CoinGecko Terms of Service and acknowledge you’ve read our Privacy Policy
or
Forgot your password?
Didn't receive confirmation instructions?
Resend confirmation instructions
IT'S FREE! Track your favorite coin easily with CoinGecko 🚀
By continuing, you agree to CoinGecko Terms of Service and acknowledge you’ve read our Privacy Policy
or
Password must contain at least 8 characters including 1 uppercase letter, 1 lowercase letter, 1 number, and 1 special character
Didn't receive confirmation instructions?
Resend confirmation instructions
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