0x Protocol is open-source infrastructure for exchanging tokens on the Ethereum blockchain and other networks that run compatible code. It lets wallets, apps and trading interfaces offer token swaps without holding users' funds: orders are created and shared off-chain, and the final trade is settled on-chain by smart contracts. Developers use it as plumbing behind a swap button rather than as a destination in its own right.
The protocol sits in the decentralized finance stack between users and sources of liquidity. It is often compared with a decentralized exchange, but its main role today is aggregation: finding the best price across many venues and routing a trade through them. It was created by the company now known as 0x Labs, and the ZRX token is used for governance.
0x Protocol in plain terms
Picture a noticeboard where people pin up offers such as "I will swap 10 apples for 12 oranges". Anyone can read the board for free, and when someone accepts an offer, the swap happens through a locked box that only opens if both sides hand over exactly what was promised. 0x works the same way: offers are posted cheaply away from the blockchain, and only the final exchange is recorded on it.
Over time 0x also became a kind of price comparison service. When an app asks it for a quote, it checks many markets at once and splits the order where needed so the user gets more of the token they want. The user still signs the trade from their own wallet, so nobody else ever holds their coins.
History of 0x
0x was founded in 2016 by Will Warren and Amir Bandeali, and its whitepaper described a standard message format for token orders that anyone could relay. The project raised funds in an August 2017 initial coin offering of ZRX, during the wave of Ethereum token sales that year. Early versions focused on "relayers", third-party websites that hosted order books and earned fees for matching orders, which then settled through 0x contracts.
As automated market makers such as Uniswap drew most on-chain trading after 2020, 0x shifted towards aggregation. It launched the 0x API, which pulls prices from AMM pools, professional market makers and its own order types, and Matcha, a consumer swap interface built on that API. The protocol has since been deployed on several networks beyond Ethereum, including Polygon and other compatible chains.
How 0x works
The design separates the cheap and expensive parts of a trade:
- Off-chain orders. A maker signs an order stating what they will give, what they want, an expiry time and any conditions. The signed message travels over ordinary internet channels, so creating it costs no gas fee, and an order left to expire costs nothing to withdraw.
- On-chain settlement. A taker who accepts the order submits it to the 0x exchange contract, which checks the signature and moves both tokens in one step, so neither side can walk away halfway.
- Request-for-quote liquidity. Professional market makers can stream firm quotes for a specific trade, which can give tighter prices on large orders than an AMM pool.
- Routing. The API compares sources and may split one order across several pools to cut slippage.
Tokens traded through 0x are typically ERC-20 tokens, and the contracts also support some non-fungible token trades.
The ZRX token and governance
ZRX is a governance token. Holders can vote on protocol upgrades and treasury decisions through 0x's governance process, and earlier versions of the protocol tied ZRX to staking rewards for market makers who provided liquidity. Much of the protocol's day-to-day development has remained with 0x Labs, which also earns revenue from fees charged to integrators through its API. That split between token-holder governance and a company-run product is common in DeFi and is a regular point of debate.
Risks and criticism
Using 0x carries the general risks of on-chain trading. Smart contract bugs can expose funds, and token approvals granted to exchange contracts can be abused if a contract is compromised. Trades that sit in the public mempool can be targeted by front-running bots, although request-for-quote orders and private routing reduce this. Aggregation also means users depend on the quality of the underlying venues: a swap routed through a thin liquidity pool or a malicious token contract can still go wrong. Finally, critics note that heavy reliance on a single company's API sits uneasily with claims of decentralization, even when the settlement contracts themselves are open and permissionless.