EN

Locking funds on the ledger

4 minDifficulty Checked 2026-11-10
Key takeaways
  • An escrow locks funds for a named recipient. The ledger is the only middleman.
  • Three kinds: time-based, conditional, or both combined.
  • Create it, then finish it to pay out or cancel it after expiry.

In an ordinary escrow, two people use a neutral third party. The third party holds the money and hands it over when the deal's terms are met.

On the XRP Ledger, the ledger itself is the third party. You lock funds in a box with one name on it. The box opens for that person when a rule is met. Until then nobody can spend what is inside. That includes you.

There are three kinds of rule:

  • Time. "Not before June 1." After that date the box can be opened.
  • Secret. "Only with the right password." Whoever shows the password can open the box.
  • Both. "Not before June 1, and only with the password."

You can also set an expiration. If the box is not opened by then, it can no longer pay the recipient. The funds can go back to you.

Three steps make up an escrow's life:

  1. Create. You lock the funds and set the rules. The rules cannot be changed afterward.
  2. Finish. Once the rule is met, someone sends a transaction that opens the box. The funds go to the recipient.
  3. Cancel. If the escrow expired first, someone sends a transaction that returns the funds to you.

The box does not open by itself. A finish or cancel transaction has to be sent. Anyone may send it, and the funds can only go where the escrow says.

Check yourself3 questions
1. Who holds the funds while an escrow is open?
2. A time-based escrow has passed its finish time. Who can finish it?
3. An XRP escrow has no expiration. Can the sender cancel it?
Sources
Next lessonTime locks and conditions4 min