Skip to main content

Cheat Sheet

0x Protocol Version

We are currently on v4 of the 0x protocol

Swap API Endpoints

Price API Endpoints

Gasless API Endpoints

Gasless API is supported on the following chains via Select the chain in your request by providing the corresponding chain id with the 0x-chain-id header.

ChainChain ID
Ethereum (Mainnet)1

Orderbook API Endpoints

Exchange Proxy Addresses

This is the primary contract for all interactions with the protocol. It is also the allowance-target/spender/operator for any ERC20, ERC721, and ERC1155 assets being traded. For most networks the address is identical, but be aware that a small number (marked with a *) are slightly different. The ABI can be found in the protocol repo's IZeroEx.json file. All 0x contract addresses can be found in the protocol repo's addresses.json file.

  • Ethereum (Mainnet): 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Ethereum (Sepolia): 0xdef1c0ded9bec7f1a1670819833240f027b25eff*
  • Polygon: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Binance Smart Chain: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Optimism: 0xdef1abe32c034e558cdd535791643c58a13acc10*
  • Fantom: 0xdef189deaef76e379df891899eb5a00a94cbc250*
  • Celo: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Avalanche: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Arbitrum: 0xdef1c0ded9bec7f1a1670819833240f027b25eff
  • Base: 0xdef1c0ded9bec7f1a1670819833240f027b25eff

Ancillary Contract Addresses

These contracts are used within the 0x ecosystem but are not intended for direct interaction with users except in rare circumstances. They are less likely to remain fixed (compared to the Exchange Proxy Address). The latest addresses can be found in the protocol repo's addresses.json file. A subset of commonly used addresses can be found in

0x Order Types

An order is a message passed into the 0x Protocol to facilitate a trade (see How does 0x work?). The order types that we support include:

Order TypeSummaryOrder StructureSupported Token Trade Types
Limit OrdersThese are the standard 0x Order, which encodes a possible trade between a maker and taker at a fixed price.Limit Order StructureERC20 <-> ERC20 trade
RFQ OrdersThese are a stripped down version of standard limit orders, supporting fewer fields and a leaner settlement process. These orders are fielded just-in-time, directly from market makers, during the construction of a swap quote on 0x API, and can be filled through the fillRfqOrder() function on the Exchange Proxy.RFQ Order StructureERC20 <-> ERC20 trade