From Ripple Wiki
Jump to: navigation, search

Target Audience

This is an intermediate description for people who want to understand conceptually how Ripple payments work.


Ripple supports two kinds of currencies: XRP and IOUs.

Ripple's native currency.
Every currency except, XRP, are represented by IOUs.


The Ripple network started off with 100 billion XRP. XRP are currently divisible to 6 decimal places. The smallest unit is called a drop. 1 million drops equals 1 XRP.

Every account has an XRP balance. XRP can be sent directly from account to account.

Like most things, you can obtain XRP from anyone who has them.


Non-XRP currencies are represented by IOUs. Conceptually, an IOU might be considered a hand written note declaring debt:

  • "IOU 25 USD -signed Alice"

Anyone who trusts Alice can accept this note with the belief Alice will later redeem it for $25 worth of value.

The IOU metaphor is only used because it is easy to visualize and explain the apparent functionality. In actuality, Ripple does not use IOUs internally. Instead, Ripple maintains a list of balances between parties for the various currencies.

The real world vs the virtual world

Ripple is merely a trusted ledger. The Ripple ledger records transactions. The ledger can not actually enforce anything in the real world.

Ripple works with the real world because in the real world people agree on the meaning of what is reflected in the ledger and to respect what is recorded in the ledger.

A real world transaction often works like this:

  1. A sale is agreed to.
  2. The seller delivers goods to the buyer.
  3. The buyer pays for the goods with a declaration.
    • This could be the signing of a credit card receipt or a check.

The buyer's payment is in essence virtual, there is no real world money be moved, only a declaration of payment due is being made.

In the Ripple version of a payment, value is transfered by making a signed declaration to transfer XRP or IOUs from the signer's account to the receiver.

The basis for IOUs

To represent real world currencies, like USD and EUR, Ripple uses IOUs. Every IOU in the system is backed by someone's promise to redeem them.

Because not everyone's promise is as good as everyone else's promises, every IOU has an issuer. So, Alice's $25 IOU may actually be worth more the Bob's $25 IOU for a variety reasons. For example, we might know Bob likes to swim with sharks.

Spending other parties IOUs

One day, Alice, Carol go to lunch. Carol is short $5. Carol also has a $5 IOU from Bob. Alice has $5 and trusts Bob, but not Carol. Even so, Alice can pay the $5 Carol is short in exchange for getting Bob's $5 IOU from Carol. In a sense, Bob's IOU has just become a private currency between Alice and Carol.

Trust lines

The balance owed between two Ripple accounts is represented as a trust line. We avoid calling it a "credit line" as credit has all sorts of associations we wish to avoid. In particular, we don't want to have any associations with interest or APR. This balance is merely a record of what is owed between the two parties.

A typical use of trust line might be as follows. Alice and Bob go out for lunch every day. One day, Alice is $5 short. Bob agrees to pay for Alice's short fall of $5 and Alice now owes Bob $5. The next day Bob is $8 short. Alice agrees to pay for Bob's short fall. Because Alice previously owed Bob $5, when the transaction is over, Bob will now owe Alice $3.

In Ripple, this balance would be recorded in the ledger. Each time someone wanted to owe the other person some money, they would declare to the ledger that they owed the other person the amount of money. The Ripple ledger would then adjust the balance appropriately.

Trust paths

If Alice accepts Bob's credit and Bob accepts Carol's credit, then Carol can pay Alice through Bob:

  • C ⇒ B, B ⇒ A

The double arrow (⇒) is used to indicate a trust line.

The Ripple network can automatically manage the balance changes if not all parties are present. One person simply makes a payment declaration and the network will adjust the balances.

Confusingly, we call this kind of a payment a ripple payment.

Trust limits

To protect people from obtaining IOUs they don't want, the Ripple network allows people to declare the limits of trust the have for particular IOUs.

A trust line has the following information:

  • The first parties limit of trust.
  • The second parties limit of trust.
  • The balance between the two parties.
  • The name of the kind of currency of the balance (e.g. USD, YEN)

As result of having trust limits, user will never receive IOUs they don't pre-authorize. For example, if the user chooses to only trust Wells Fargo bank, then all payments will be denominated in Wells Fargo bank IOUs and the user will have no other liabilities.

Rippling rules

The Ripple networks integrates the ripple payment concept for all currencies except XRP.

To use Ripple:

  • You pre-approve a credit limit to another account.
    • If the person defaults, you are responsible for that amount.
  • You agree on settlement terms with someone else.
    • If you have no agreement, you have no obligation to settle.
  • You can create your own IOUs.
  • You can hold other people's IOUs.
  • You can pay anyone in IOUs that they accept.
  • You must accept your own IOUs as payment.

Catalog of payments

This shows the variety of ways payments can be arbitrarily constructed.

Direct XRP Payment

The single arrow (→) represents a direct payment between accounts, no trust line is necessary. This shows how XRP can transfer from Alice's account to Bob's account. Or, how XRP payments always work.

  • Send credits directly between all accounts:
    • aliceXRP → bobXRP

Direct Ripple IOU Payment

The double arrow (⇒) is used to indicate a trust line. This illustrates, direct payment over a mutual trust line.

  • Ripple between accounts via a trust line:
    • aliceUSD ⇒ bobUSD

Indirect Ripple IOU Payment

This illustrates how trust lines can be used to make an indirect payment.

  • Indirect Ripple payment between accounts via a path of trust lines:
    • aliceYEN ⇒ bobYEN ⇒ carolYEN

Ripple payment bridged by credits

A network of trust lines can form a community for exchanging a currency. Imagine a community in Russia which has a trust network that allows them to spend USD among themselves. Also imagine, a similar community in the United States. If there is no trust path between them, then payment can not be made between the disparate Ripple networks.

Ripple has a solution for this. Because Ripple has a built in exchange, someone the Russia network can make an offer to exchange XRP for Russia network USD IOUs and someone in the US can also make an offer to exchange XRP for United States network USD IOUs.

This illustrates the bridging of a Ripple payment through offers converting from IOUs to XRP to IOUs:

  • Ripple payment bridged by credits:
    • aliceUSD ⇒ offerUSD,XRP → offerXRP,USD ⇒ bobUSD

Cross currency payment

Ripple allows cross currency payments. We call this feature "preferred currency" because it allow each party to transact in their preferred currency.

This illustrates a cross currency payment which converts currency via an offer.

  • Prefered Currency:
    • aliceUSD ⇒ offerUSD,EUR ⇒ bobEUR

Gateways & Transfer fees

Because it is unlikely, that anyone will want IOUs from any random person, Ripple has the concept of a gateway. A gateway is a reputable business that many people trust to issue and redeem IOUs.

To allow gateways to earn a profit for providing their service, the Ripple network lets IOU issuers specify a fee that is to be paid whenever the gateway's IOUs are transfered between third parties. This is call the transfer fee. For example, Bitstamp currently charges a transfer fee of 0.20% to sender whenever someone sends one of their IOUs to someone else.

Overview of making a payment

  1. The user enters a destination address, destination currency, and destination amount.
  2. The network gets an estimate of how much the payment will cost for each currency the user has.
  3. The user authorizes payment for the estimated amount plus a margin for slippage.
  4. The payment is submitted to the network.
  5. The payment may fail or clear.

Putting it all together

This is an end to end walk through of receiving a payment:

  1. A person creates a Ripple wallet.
  2. The person finds their Ripple address in the wallet.
  3. The person arranges for an XRP payment to be made to fund their account. At least 76 XRP are recommended for basic functionality.
  4. The person then sets a trust limit to their gateway of choice for the currency they want to receive.
    • The person should choose a highly liquid gateway to make sure that others will have no problems making payments to them.
    • The person can receive payments up to this amount into their account.
  5. The person can then supply people making payments to them with their Ripple address.
  6. Their Ripple address balance will increase when payments are made.

This is a walk through of cashing out an IOU to a regular bank account:

  1. Having IOUs for a gateway, the account owner finds the Ripple deposit address for their gateway account.
  2. They make a payment to the gateway for the amount they which to deposit with the gateway.
    • Their Ripple account balance is reduced.
    • Their gateway account balance is increased.
  3. They can then ask the gateway to make withdrawal to a regular bank account.
    • For example, via check, wire, ACH, or SEPA payment.