An independent, source-linked guide to XRP. Not an official site of Ripple Labs or the XRP Ledger Foundation, and not financial advice.Independent guide · not financial advice

XRP $0.9535 +4.29%

XRP Basics

The XRPL DEX and AMM: How the Ledger's Built-In Exchange Works

The XRP Ledger has had an order-book exchange built in since 2012 and an AMM since March 2024. Here is how trust lines, tokens and liquidity pools work — and where they can cost you money.

Opens CEX.IO, an exchange operating since 2013 with US licences and a UK FCA registration. Availability depends on your country.

8 min read
Collage of a hand dropping a coin into a glass jar
An exchange that lives inside the ledger itself, explained with worked numbers
On this page
  1. The XRPL DEX: an order book built into the ledger
  2. Trust lines and XRPL tokens
  3. How XRPL AMM pools work
  4. Impermanent loss, worked through
  5. XRPL DEX vs a centralised exchange
  6. Stablecoins on the XRP Ledger: RLUSD
  7. The XRPL EVM Sidechain and Xahau: separate networks
  8. Risks on the XRPL DEX
  9. Using the XRPL DEX safely with Xaman
Illustration of a coin passing between two people — peer-to-peer trading on the XRPL DEX without a middleman

The XRPL DEX is not an app or a smart contract someone deployed. It is part of the XRP Ledger’s protocol: order books have existed in the ledger since 2012, and an automated market maker (AMM) was added in March 2024. If every wallet company disappeared tomorrow, the exchange logic would still be there. That design has real advantages, and some sharp edges. This guide covers how the order book and auto-bridging work, what trust lines and tokens are, how AMM pools price trades, what impermanent loss looks like in numbers, how the DEX compares with a centralised exchange, where RLUSD and the sidechains fit, and how to use it all without getting burned. For the ledger underneath, see what the XRP Ledger is.

The XRPL DEX: an order book built into the ledger

xrpl.org calls it “possibly the world’s oldest” decentralised exchange. Since launch, the ledger has had native order books for XRP and any token issued on it.

Trading starts with an offer. An OfferCreate transaction says “I’ll give this much of A for that much of B”. If matching offers exist, it fills immediately; any remainder sits on the book. A resting offer is a ledger object, so it ties up 0.2 XRP of owner reserve until it fills or you cancel it.

The clever part is auto-bridging. Say you want to swap a GBP-denominated token for a BRL-denominated one, and the direct GBP/BRL book is thin. The ledger checks whether going GBP → XRP → BRL gives a better rate and, if so, routes through XRP automatically — in a single transaction.

STEP 1Offer to sell GBP tokenLedger compares the direct book with the XRP route
STEP 2GBP → XRPFills against the GBP/XRP book
STEP 3XRP → BRLFills against the XRP/BRL book
STEP 4BRL token receivedSettles as one transaction
Auto-bridging: the ledger routes through XRP when that beats the direct book

Since the AMM arrived, a single trade can fill against order-book offers, AMM pools or a mix of both, depending on what is cheaper at that moment. Cross-currency payments use the same liquidity through payment paths. And since 18 February 2026, PermissionedDEX allows order books restricted to members of an approved domain. At our last check XRPScan counted about 184,000 open DEX offers and roughly 32,850 AMM pools on the ledger.

Trust lines and XRPL tokens

Everything on the XRPL other than XRP is an issued token. Anyone can issue one: a stablecoin, a loyalty point, a meme token. Holding one requires a trust line — your explicit opt-in to hold a particular token from a particular issuer. Without one, nobody can push that token into your balance.

The rules that matter:

  • Each trust line locks 0.2 XRP of owner reserve. An account holding no more than the base reserve can still open its first two.
  • XRP itself needs no trust line, and XRP cannot be frozen by anyone.
  • Issuers can freeze their own tokens. Deep Freeze, live since May 2025, stops a frozen account from sending or receiving that token at all.
  • With Clawback (live since February 2024), an issuer can recover tokens from holders — but only if it switched the feature on before issuing anything. It is off by default.

In other words, holding a token means trusting its issuer: its reserves, its redemption process and its use of those powers.

Since 1 October 2025 there is a second token type, Multi-Purpose Tokens (MPTs, XLS-33). MPTs skip trust lines entirely and are aimed at stablecoins and tokenised real-world assets. One catch: trading MPTs on the DEX needs a further amendment (MPTokensV2) that is still in development, so the order books and AMM pools today trade trust-line tokens.

How XRPL AMM pools work

The AMM amendment (XLS-30) went live on 22 March 2024. Instead of waiting for a counterparty on the order book, you trade against a pool holding two assets.

Collage of a man surrounded by banknote arrows labelled Liquidity — illustrating deposits into an XRPL AMM pool
In an AMM, other users' deposits are your counterparty
  • Pricing. The XRPL uses a geometric-mean AMM with a weight of 0.5, which behaves like a constant-product market maker: the product of the two balances stays fixed, so the more of one asset you take out, the more expensive it gets.
  • One pool per pair. There can be at most one AMM for any pair of assets. Creating one (AMMCreate) burns 0.2 XRP.
  • LP tokens. Depositors receive LP tokens representing their share; returning them withdraws the assets. The pool’s own account is special and is not subject to reserves.
  • Fee voting. The trading fee can be set from 0% to 1% in 0.001% steps. Liquidity providers vote, weighted by their LP tokens, and up to eight votes count.
  • Auction slot. Whoever wins the slot, bidding in LP tokens, trades at one tenth of the normal fee for 24 hours.
FeatureOrder bookAMM pool
Price set byMatching limit ordersRatio of pool balances
Liquidity fromAnyone placing offersLiquidity providers
Trader’s costNetwork feeNetwork fee + pool fee (0–1%)
Main risk for the providerGetting filled at a bad priceImpermanent loss

Impermanent loss, worked through

xrpl.org puts it plainly: “when the relative price between the assets shifts, liquidity providers can take a loss”. The loss compared with simply holding is called impermanent loss. Here it is with hypothetical numbers.

Suppose XRP were 2 RLUSD and a pool held 1,000 XRP and 2,000 RLUSD. You deposit 100 XRP and 200 RLUSD, a 10% share worth 400 RLUSD. Then the price moves. Traders rebalance the pool until it matches the outside market, and the constant-product formula decides what your 10% now contains. If XRP doubles to 4 RLUSD, your share becomes about 70.7 XRP and 282.8 RLUSD.

Hypothetical 10% share of an XRP/RLUSD pool

XRP price (RLUSD)Your LP share is worthJust holding is worthDifference
2 (start)4004000
4 (doubles)565.7600−5.7%
1 (halves)282.8300−5.7%
0.5 (quarters)200250−20%

Constant-product maths; trading-fee income not included. All prices are hypothetical.

Notice that the loss is symmetrical: a doubling and a halving both cost about 5.7% versus holding, and a four-fold move costs 20%. If the price returns to where you started, the gap closes, which is why it is called “impermanent”. Withdraw while the price is away and the loss becomes very permanent. Fee income is what you are betting will outweigh it, and in a small pool with little trading it may not.

XRPL DEX vs a centralised exchange

Neither is simply “better”. They trade different risks.

XRPL DEX compared with a centralised exchange

XRPL DEXCentralised exchange
Who holds the keysYou (self-custody)The exchange
Sign-up and KYCNone at protocol levelRequired
What you can tradeAny issued token, scams includedAssets the exchange lists
CostsNetwork, pool and app feesTrading fees or spreads
If something goes wrongNobody can reverse itSupport desk, possibly
Counterparty riskToken issuersThe exchange itself

Two practical notes. Taxes do not disappear on-chain: in Japan, the National Tax Agency treats crypto-to-crypto swaps as taxable disposals, so log every swap at its fiat value. Our Japan regulation and tax guide covers the Japanese rules. And residents of Japan can legally buy XRP only through FSA-registered exchanges.

Stablecoins on the XRP Ledger: RLUSD

The best-known stablecoin on the XRPL is Ripple USD (RLUSD). It is issued by Standard Custody & Trust Company, a New York limited-purpose trust company operating as Ripple Custody & Trust. Its NYDFS approval was announced on 10 December 2024, and it launched on 17 December 2024 on both the XRP Ledger and Ethereum. Ripple now lists eight chains, including the XRPL EVM Sidechain.

  • Reserves are held 1:1 in US dollar cash, US Treasuries and cash equivalents, with monthly attestations by an independent CPA. An attestation is not an audit.
  • Only eligible Ripple customers can redeem RLUSD for dollars. Everyone else sells it on a market.
  • In Japan, SBI VC Trade has offered RLUSD since 24 June 2026, but on Ethereum only. You cannot move XRPL-issued RLUSD in or out there.

To hold RLUSD on the XRPL you need a trust line to the genuine issuer, and you should take that address only from Ripple’s own pages. In May 2026 a fake “Season 1” RLUSD airdrop impersonating Xaman and the “XRPL Foundation” tricked people into signing hidden trust lines and drainer transactions. More detail on our RLUSD page.

The XRPL EVM Sidechain and Xahau: separate networks

Most “smart contracts on XRP” headlines are about neighbouring chains, not the XRPL itself.

XRPL EVM SidechainSeparate chain

Mainnet since 30 June 2025, built by Ripple, Peersyst and Axelar. Ethereum-compatible, XRP pays for gas, proof-of-authority consensus, connected to the XRPL via an Axelar bridge.

XahauSeparate network

Live since October 2023. Runs Hooks — lightweight smart contracts attached to accounts — with its own token (XAH) and its own validators.

Flare FXRPToken on another chain

An ERC-20 on Flare representing XRP, backed by agents’ collateral. It is not XRP, and it carries bridge and smart-contract risk.

Once your XRP crosses a bridge, the XRPL’s guarantees no longer apply. You now depend on the bridge, the other chain’s validators and whatever contracts you interact with.

Risks on the XRPL DEX

“No smart contracts” means there is no individual contract to exploit, and that genuinely removes a class of DeFi hacks. It does not make the DEX safe by default.

  • Scam tokens. Anyone can issue a token with any name. Look-alike tokens riding on real news headlines have circulated on the XRPL.
  • Trust-line spam. Phishing pages get you to sign hidden trust lines; each one also locks 0.2 XRP of your reserve.
  • Issuer risk. Freeze, clawback and redemption are in the issuer’s hands.
  • Thin liquidity. Small pools move sharply on small trades, and impermanent loss bites harder.
  • No undo. Validated transactions are final. “Recovery services” that contact you are scams.
  • Click 'claim your airdrop' links from DMs or social posts
  • Sign any transaction you did not start yourself
  • Trust a token because of its name or an explorer label
  • Type your secret (starts with 's') or recovery phrase into any site
  • Put a large amount into a thin pool in one go

Our XRP scams and safety guide goes through the common tricks in detail.

Using the XRPL DEX safely with Xaman

The most common way in is Xaman, the mobile wallet from XRPL Labs. For alternatives, see our XRP wallet comparison.

  1. Install from the official store and activate

    Get Xaman from the App Store or Google Play only, then receive at least 1 XRP to activate the account. Your spendable balance is what is left above the reserve.
  2. Verify the issuer, then add the trust line

    Find the issuer’s address on the issuer’s own website before adding a trust line. Budget 0.2 XRP of reserve per line.
  3. Start with a small swap

    Use the in-app trading tools with a small amount first. At our last check Xaman charged a 0.8% service fee on swaps and DEX trades; sending (up to $50k), receiving and trust-line changes were free.
  4. Treat AMM deposits as an investment decision

    Xaman also charged 0.8% on AMM deposits and withdrawals at our last check. Run the impermanent-loss numbers before you commit.
  5. Clean up afterwards

    Bring unwanted token balances to zero and remove those trust lines to unlock the reserve.
Get XRP for fees and reserves

Trading on the XRPL DEX needs a little XRP for network fees and the account reserve.

Frequently asked questions

Do I need an account or KYC to use the XRPL DEX?
Not at the protocol level. You trade straight from a self-custody wallet. The flip side is that no exchange stands behind you: mistakes and scams on the ledger cannot be reversed.
What is a trust line on the XRP Ledger?
It is your opt-in to hold a specific token from a specific issuer. Each trust line locks 0.2 XRP of owner reserve, which is released when you bring the balance to zero and remove the line.
Is providing liquidity to an XRP AMM pool like earning interest?
No. You earn a share of the pool's trading fees, but impermanent loss can leave you with less value than if you had simply held. Compare it with other options on our XRP staking page.
Can I use RLUSD on the XRPL DEX?
Yes, RLUSD is issued natively on the XRP Ledger as well as on Ethereum and other chains. You need a trust line to the genuine issuer, whose address you should copy only from Ripple's official pages. More on our RLUSD page.
Is the XRPL EVM Sidechain part of the XRP Ledger?
No. It is a separate, Ethereum-compatible chain that went live on 30 June 2025 and uses XRP for gas. Assets move between the two over a bridge, which brings its own risks.
Someone sent me a token I never asked for. What should I do?
Nothing. Token names prove nothing, and 'claim' links are a common route to malicious signing requests. Never sign a transaction you did not start yourself.

Sources

Links to official sites, regulators and news reports. Details can change, so check the original source before any important decision.

  1. XRPL.org — Decentralized Exchange
  2. XRPL.org — Auto-Bridging
  3. XRPL.org — Automated Market Makers
  4. XRPL.org — Reserves
  5. XRPL.org — Freezes
  6. XRPL.org — Clawing Back Tokens
  7. XRPL.org — Known Amendments
  8. Ripple — Ripple USD (RLUSD)
  9. Ripple — RLUSD launches globally
  10. Ripple — XRPL EVM Sidechain Mainnet is live
  11. Xahau
  12. Xaman — Service fees
  13. Xaman — Airdrop scams