Most exchanges that have the option to deposit crypto offer individual wallets for every customer. What is the benefit of moving that money to a "central" wallet? Could they also just combine thousands of addresses to make their transactions? Is the benefit just for the overview or is there a technical reason?
2 Answers
Note: This answer applies to Bitcoin, not "crypto" generically.
On terminology
I think you may be conflating "wallets" and "addresses". Addresses are used to communicate the payment instructions from receiver to sender and identify a payment's context. A more suitable name instead of "addresses" would have been "invoice identifiers". A "wallet" is an abstract construct that tracks a user's funds and corresponding transactions. Wallets often also manage private key material, although that is sometimes split into a "watch-only wallet" and a personal hardware signing device (or "hardware wallet").
In this context, some people insist that the term wallet only refers to situations in which the user has full control of their own funds, and relations in which a service has taken custody of their funds should be referred to as user accounts.
Replicating user balances on-chain
Having separate addresses per customer is a business necessity, having separate wallets for each customer is a scalability nightmare.
E.g. Coinbase handled their (custodial!) wallets that way for a long time: they would try to map user balances on chain in addition to accounting for them on the books. They'd redirect funds from the separate wallets to their main wallet after deposits came in, and before sending withdrawals/payments first stage funds in a user's specific address "to have the correct 'sender address'". This added unnecessary transactions and was a horrible privacy leak due to the address reuse. Also users were confused about "funds moving from/to their addresses".
Omniwallets
It's much cleaner to explicitly take custody: Since exchanges (and many online-wallets) take custody of deposits, they give out distinct addresses for each user to learn whom they should credit when payments come in, but all of the user addresses are part of a single "omniwallet". This allows the service to benefit from their operation's scale: they can use all UTXOs from the omniwallet to efficiently build transactions, can consolidate the smaller UTXOs opportunistically when blockspace is abundant, and keep the majority of the funds in cold storage. In Bitcoin, a transaction can spend UTXOs received to many different addresses together (which is not true for some other cryptocurrencies which operate under an account model rather than a UTXO model).
-
Thank you for the answer. Do you happen to have an address that was used by the old coinbase system to understand the payment system through looking at transaction? Or is there some documentation on the payment system? Commented Jun 17, 2022 at 11:01
The Omniwallets mentioned in the previous answer can be thought of as a form of limited-scope L2 (second-layer) payment network, albeit one with much more required trust than a decentralized global L2 such as the Lightning Network. Transfers within an exchange, that is, between two parties who are both customers of the exchange, can be effected by simply updating a database within the exchange, without touching the blockchain.
The usual form this would take is, Alice wants to buy bitcoin using part of her fiat balance on the exchange, while Bob wants to do the opposite. The exchange can simply decrement Alice's fiat balance and Bob's BTC balance, and increment Alice's BTC balance and Bob's fiat balance, according to the current exchange rate. This is much less expensive than posting on-chain transactions.
This arrangement does open the possibility of fractional-reserve asset management (either of fiat or bitcoin); many of the larger exchanges seek to allay these concerns, at least as far as their bitcoin holdings are concerned, by periodically revealing proofs of reserve to the public.