In the first part of our blog series we explored Central Limit Order Books, also known as CLOBs, and how they work at a basic level. If you haven’t read it and you’re new to DeFi, I encourage you to read it before proceeding.
Quick recap: a Central Limit Order Book allows us to create a marketplace which can easily match a buyer and seller with the help of limit orders on the book. In our previous post we used an apple market to understand how buyers and sellers can use the book. If you remember, we used the book to record the prices that the shops wanted to buy/sell at. Let us move away from apples and use Bitcoin (BTC) going forward.
A trade is only possible if there is someone who is either buying from you or selling to you. This person is a counterparty to your trade. Now the question arises when we go to make a trade, who is the counterparty?
If you want to buy BTC, you need to find someone willing to sell it to you at the best possible price and at the exact moment you’re ready to trade. This means a seller must not only exist but also actively have an order available at the right price when you want to trade. The order book is an elegant solution, but someone has to be placing the orders on the book for you to trade against.
On centralized exchanges (Binance, Coinbase, etc.) there are orders on the book, and the people who place these orders are willing to be our counterparty. But who are these people and why are they willing to trade with us?
Enter Market Makers
In this post we will explore how market making works on AMMs and CLOBs.
A(MM) - Automated Market Makers
To make trading easier, AMMs use liquidity pools instead of an order book. Let’s say there’s a BTC/USDC pool on an AMM. People, called liquidity providers (LPs) deposit BTC and USDC into this pool, creating a shared pot of funds.
Now, imagine you have some USDC and want to buy BTC. The AMM lets you trade directly with the pool. It uses a math formula to set the price of the trade. The most common type, the Constant Function Market Maker (CFMM), adjusts prices depending on the pool's balance of assets. This automated pricing is why it’s called an Automated Market Maker.
But why would people deposit their BTC or USDC into the pool?
Every time someone trades, like when you swapped USDC for BTC, the pool charges a small fee. This fee is split among all the LPs and paid in the asset being traded—BTC or USDC. Over time, these fees can grow, making it rewarding for LPs to provide liquidity.
Market Makers
Back to order books. Just like liquidity pools in AMMs, Market Makers (MMs) ensure you can trade at any time. Let’s take a BTC/USDC market on a centralized exchange. MMs place buy and sell orders on the book, ready to be your counterparty whenever you want to trade.
For example, if you have USDC and want to buy BTC, a MM might have placed an order to sell BTC at a price they decided. These prices aren’t random—they’re based on many factors like market trends, demand, and their own strategies. Once set, the MM keeps their funds on the book at specific prices, ready to buy BTC from you or sell BTC to you.
Why would someone become a Market Maker?
The answer is spread.
What is a spread? Let us understand spreads with an example.
Assume there’s only one Market Maker (MM) in the BTC/USDC market. The MM places orders on the book, offering to sell BTC at $90,100 and buy BTC at $90,000. These prices are carefully chosen, with a $100 difference between them—this is the spread.
Now, imagine someone wants to buy 1 BTC— they look at the order book and buy it from the MM by paying $90,100. (Note: The MM was willing to sell BTC at this price)
Later, another person comes along and wants to sell 1 BTC, so they sell to the MM at $90,000. (Note: the MM was willing to buy BTC at this price)
What does the MM end up with? The MM sold 1 BTC for $90,100 and bought 1 BTC for $90,000, pocketing the $100 difference.
This spread is the MM’s reward for being your counterparty. The spread is the MMs fee for providing liquidity. Similar to LPs on AMMs getting rewarded for providing liquidity.
Market Making isn’t exactly easy
MM’s are sophisticated actors that run strategies to make the most out of this market. They truly make the market and facilitate trades for people like us. Spread is the profit they make for providing this service and liquidity to the market.
Market Makers (MMs) aim to maintain a balance—they want to sell as much BTC as they buy. If they end up with too much BTC and the price crashes, they could be stuck holding the bag, leading to losses. That’s why MMs focus on consistently doing back-and-forth buy and sell trades. This constant activity is where they make the most money.
To achieve this, MMs use strategies to decide where to place their orders and how much liquidity to provide. These systems help them adjust quickly to changes in the market, ensuring they stay profitable while managing their risks.
When multiple MMs are providing liquidity on the same market, they are competing with each other to be the one who becomes the counterparty for a trade. Remember CLOBs follow Price-Time Priority. The MMs are racing against each other to make sure their order is in front of the queue.
What’s next?
Being a liquidity provider (LP) on an AMM is much easier to understand and participate in. You deposit your assets into a pool, and the AMM takes care of the rest. Market making on an order book, however, is a far more complicated and involved process.
But what if we told you there’s a way to provide liquidity to an order book without needing to do all the hard work?
Stay tuned for the next blog in the series where we explore one of Kuru’s core innovations!