Bitcoin CoinJoin Explained: How Collaborative Transactions Work
Deep dive into Bitcoin CoinJoin protocol. Learn how collaborative transactions break the chain of ownership, anonymity sets, and CoinJoin implementations.
Uvin Vindula — IAMUVIN
Published 2026-06-07
Bitcoin CoinJoin: Breaking the Chain of Ownership
CoinJoin is a privacy protocol proposed by Bitcoin developer Gregory Maxwell in 2013. It allows multiple Bitcoin users to combine their transactions into a single joint transaction, making it difficult for blockchain observers to determine which inputs correspond to which outputs. CoinJoin is the most widely used and practically effective privacy technique available on Bitcoin today.
The CoinJoin Concept
In a standard Bitcoin transaction, the flow of funds is clear: specific inputs map to specific outputs. CoinJoin breaks this deterministic mapping by having multiple independent users contribute inputs and receive outputs in the same transaction.
Before CoinJoin
Three separate transactions: Alice sends 0.1 BTC to merchant, Bob sends 0.1 BTC to exchange, Carol sends 0.1 BTC to friend. Each transaction is individually traceable.
After CoinJoin
One combined transaction with 3 inputs (Alice, Bob, Carol) and 3 equal outputs of 0.1 BTC. An observer sees the combined transaction but cannot determine which input paid which output. The anonymity set is 3 — each output could belong to any of the 3 participants.
Anonymity Sets
The anonymity set is the number of participants in a CoinJoin. A larger anonymity set provides stronger privacy:
- Anonymity set of 5: Each output has a 1 in 5 chance of belonging to any specific input (20% probability).
- Anonymity set of 50: Each output has a 1 in 50 chance (2% probability).
- Anonymity set of 100+: Extremely difficult to trace specific flows.
Multiple rounds of CoinJoin compound the anonymity set exponentially. After 3 rounds with an anonymity set of 50 each, the effective anonymity set grows dramatically.
CoinJoin Implementations
Whirlpool (Samourai/Sparrow)
Whirlpool is the CoinJoin implementation used by Samourai Wallet and Sparrow Wallet:
- Fixed denomination pools: 0.001, 0.01, 0.05, and 0.5 BTC pools.
- Zero-link architecture: No link between your transaction inputs and CoinJoin outputs.
- Free remixes: After the initial mix, subsequent remix rounds are free (you only pay the mining fee).
- Toxic change handling: Separates the non-private change output from mixed UTXOs.
- Continuous mixing: UTXOs can sit in the mix pool and automatically participate in new rounds.
WabiSabi (Wasabi Wallet)
Wasabi Wallet uses the WabiSabi protocol, an evolution of the original ZeroLink framework:
- Variable amounts: Unlike Whirlpool's fixed pools, WabiSabi supports variable output amounts.
- Large rounds: Can support hundreds of participants in a single round.
- Coordinated mixing: Uses a central coordinator for round management (though the coordinator cannot steal funds or link inputs to outputs).
JoinMarket
A decentralized CoinJoin marketplace:
- Maker/Taker model: Makers offer liquidity for mixing and earn fees. Takers pay fees to mix their coins using makers' liquidity.
- No central coordinator: Fully decentralized, peer-to-peer mixing.
- Flexible amounts: No fixed pool sizes.
- Earn yield: Makers earn Bitcoin by providing CoinJoin liquidity — one of the few ways to earn non-custodial yield on Bitcoin.
The CoinJoin Process (Whirlpool Example)
- TX0 (Pre-mix): Your Bitcoin is split into pool-sized UTXOs plus toxic change. A coordinator fee is paid at this stage.
- Initial Mix: Your pool-sized UTXOs enter the mixing pool and participate in a CoinJoin with 4 other participants (5-participant rounds).
- Remixing: Mixed UTXOs automatically re-enter the pool for additional rounds, increasing your anonymity set with each remix.
- Post-Mix: When ready to spend, you use your mixed UTXOs from the post-mix wallet.
Post-CoinJoin Best Practices
CoinJoin privacy can be undone by poor post-mix behavior:
- Never merge mixed and unmixed UTXOs: This links your CoinJoin outputs back to your identity.
- Use separate wallets: Maintain distinct wallets for mixed and unmixed funds.
- Spend to new addresses: Never send mixed funds to addresses previously used with KYC exchanges.
- Consider timing: Don't spend immediately after mixing — allow time to pass to avoid timing analysis.
CoinJoin Costs
| Implementation | Coordinator Fee | Mining Fees | Remix Cost |
|---|---|---|---|
| Whirlpool | 3.5-5% of pool size (one-time) | Per transaction | Free (mining fee only) |
| WabiSabi (Wasabi) | 0.3% of mixed amount | Per transaction | 0.3% per round |
| JoinMarket (Taker) | ~0.1-0.5% to makers | Per transaction | Pay per round |
Legal and Ethical Considerations
CoinJoin is a privacy tool, not a money laundering tool. The right to financial privacy is recognized in many jurisdictions. However, some regulators have taken actions against CoinJoin coordinators. Stay informed about the legal status of privacy tools in your jurisdiction.
CoinJoin for Sri Lankan Users
Sri Lankan Bitcoin users can benefit from CoinJoin for personal security and financial privacy. Sparrow Wallet with Whirlpool integration provides the most user-friendly experience for desktop users. Always be mindful of local regulations and use privacy tools responsibly. Visit our learning center for privacy tutorials and our tools page for recommended privacy wallets.
Disclaimer: This article is for educational purposes only. Privacy tools should be used in compliance with all applicable laws. This is not legal or financial advice. Use privacy-enhancing tools responsibly.

By Uvin Vindula — IAMUVIN
Sri Lanka's leading Bitcoin educator. Author of "The Rise of Bitcoin".
Learn more →Related Articles
The Bitcoin Brief: LK
Weekly Bitcoin insights, market analysis, and Sri Lanka crypto news. Join 1,000+ readers.
Unsubscribe anytime · Educational content only