Design a Retail Stock Trading Platform (Robinhood-like)
Design a mobile-first retail stock trading platform for U.S. equities, similar to Robinhood. The platform acts as an introducing broker, partnering with a clearing broker for custody and settlement. Market data is sourced from a third-party vendor (SIP / top-of-book), and orders are routed to market makers and exchanges.
At launch, the platform supports individual cash accounts only (no margin, no options, no crypto) for trading U.S. equities, which settle on a T+1 basis. Walk through the end-to-end design, focusing on areas such as onboarding & funding, real-time balances and buying power, market-data ingestion and quote streaming, the order lifecycle (validation, risk checks, idempotency, routing, post-trade), portfolio/positions with cost basis and corporate actions, the data model and storage choices, service decomposition and sync-vs-async APIs, consistency and latency guarantees, scale and reliability during market-open surges, observability and compliance/audit, and potential future extensions to options and crypto.
Constraints & Assumptions:
- Scope at launch: U.S. equities only, individual cash accounts (no margin/options/crypto), settling T+1. Extended-hours sessions and 24/5 trading support are included.
- Custody/settlement: Introducing broker model with a single clearing broker partner (not self-clearing).
- Market data: Third-party vendor providing SIP / top-of-book (NBBO, last sale); no proprietary direct feeds at launch.
- Scale: Low single-digit-millions of users; market-open quote rates can exceed ~100k messages/sec per region; order submission bursts in the thousands/sec at the open; ~10× baseline burst factor at 9:30 ET.
- Latency targets: Order accept ack < ~50 ms server-side; fill notification to client within a few hundred ms (vendor/network dependent); quote fan-out coalesced to ~100–250 ms windows.
- Invariants: Settled cash must never go negative; no order may reserve buying power it doesn't have; every execution must post to the ledger exactly once.
AI interview prep
Core dilemma
Balancing the strict, low-latency, strongly-consistent requirements of financial transactions (order execution, ledger updates) with the high-throughput, eventually-consistent demands of real-time market data and user-facing portfolio views, all while adhering to stringent regulatory and audit requirements.
4 tradeoffs and 3 stress tests locked
Interview prep
Unlock the interviewer X-Ray rubric, tradeoff matrix, stress tests, clarifying questions, and key concepts.
Design a Retail Stock Trading Platform (Robinhood-like)
Design a mobile-first retail stock trading platform for U.S. equities, similar to Robinhood. The platform acts as an introducing broker, partnering with a clearing broker for custody and settlement. Market data is sourced from a third-party vendor (SIP / top-of-book), and orders are routed to market makers and exchanges.
At launch, the platform supports individual cash accounts only (no margin, no options, no crypto) for trading U.S. equities, which settle on a T+1 basis. Walk through the end-to-end design, focusing on areas such as onboarding & funding, real-time balances and buying power, market-data ingestion and quote streaming, the order lifecycle (validation, risk checks, idempotency, routing, post-trade), portfolio/positions with cost basis and corporate actions, the data model and storage choices, service decomposition and sync-vs-async APIs, consistency and latency guarantees, scale and reliability during market-open surges, observability and compliance/audit, and potential future extensions to options and crypto.
Constraints & Assumptions:
- Scope at launch: U.S. equities only, individual cash accounts (no margin/options/crypto), settling T+1. Extended-hours sessions and 24/5 trading support are included.
- Custody/settlement: Introducing broker model with a single clearing broker partner (not self-clearing).
- Market data: Third-party vendor providing SIP / top-of-book (NBBO, last sale); no proprietary direct feeds at launch.
- Scale: Low single-digit-millions of users; market-open quote rates can exceed ~100k messages/sec per region; order submission bursts in the thousands/sec at the open; ~10× baseline burst factor at 9:30 ET.
- Latency targets: Order accept ack < ~50 ms server-side; fill notification to client within a few hundred ms (vendor/network dependent); quote fan-out coalesced to ~100–250 ms windows.
- Invariants: Settled cash must never go negative; no order may reserve buying power it doesn't have; every execution must post to the ledger exactly once.