DEV Community

Cover image for ๐Ÿ” Money Movement When You Buy a Product Online ๐Ÿ›’๐Ÿ’ธ
Aditya Pandey
Aditya Pandey

Posted on

๐Ÿ” Money Movement When You Buy a Product Online ๐Ÿ›’๐Ÿ’ธ

One picture is worth more than a thousand words. This is what happens when you buy a product using PayPal or a bank card โ€” under the hood.

To understand this, we need to digest two concepts:

๐Ÿ“Œ Clearing โ€“ calculates who pays whom, and how much.

๐Ÿ“Œ Settlement โ€“ is when real money moves between reserves in the settlement bank.


๐Ÿ‘ค Letโ€™s say Bob wants to buy an SDI book from Claireโ€™s shop on Amazon.

๐Ÿ”น Pay-in Flow (Bob pays Amazon):

  1. Bob buys a book on Amazon using PayPal.
  2. Amazon sends a money transfer request to PayPal.
  3. PayPal, which has Bobโ€™s debit card token, transfers money on his behalf to Amazonโ€™s bank account in Bank A.
  4. Bank A and Bank B send transaction statements to the clearing institution.
    • This reduces the number of actual settlements.
    • If Bank A owes Bank B $100, and Bank B owes Bank A $500 โ†’ only $400 is settled.
  5. The clearing institution sends clearing & settlement info to the settlement bank.
  6. Actual money movement happens between reserve accounts at the settlement bank.

๐Ÿ”น Pay-out Flow (Amazon pays Claire):

  1. Amazon informs Claire sheโ€™ll get paid soon.
  2. Amazon sends a money transfer request from Bank A (its bank) to Bank C (Claireโ€™s bank).
    • Both banks record the transaction, but no real money moves yet.
  3. Bank A and Bank C send transaction statements to the clearing institution.
  4. The clearing institution sends clearing and settlement info to the settlement bank.
  5. ๐Ÿ’ฐ Money is transferred from Bank Aโ€™s reserve to Bank Cโ€™s reserve.

๐Ÿง  Three Layers in Play:

  1. Transaction layer โ€“ where online purchases happen
  2. Payment and clearing layer โ€“ where payment instructions/netting happen
  3. Settlement layer โ€“ where actual money moves

โœ… The first two are information flow

๐Ÿ’ฐ The third is fund flow

These flows are asynchronous โ€” which is why reconciliation is critical for consistency across systems.


๐ŸŒ It gets even more interesting when Bob shops internationally, like in the Indian market:

  • Bob pays in USD ๐Ÿ’ต
  • But Claire (the seller) receives INR ๐Ÿ‡ฎ๐Ÿ‡ณ

So much happens behind that one simple "Buy Now" button!


Top comments (0)