← Stripe Interview Insights

Stripe·Software Engineer·Onsite - System Design / Architecture·Senior

Senior
May 2026

Summary

Stripe systems design interview for a software engineering role. The whole thing was one long coding/design problem about a reconciliation pipeline, and they kept layering on edge cases until I was pretty sure I'd missed something important.

Questions Asked (7)

Q1

You have a reconciliation pipeline that pairs transaction records across two systems and classifies each pair as matched, mismatched, unmatched on one side, or unmatched on the other. How would you produce aggregated reports showing counts and total amounts for each classification, including mismatches broken down by which field differs?

System DesignData ModelingProduct Analytics & Metrics
Author's notes

I started with a groupBy on the classification label and summed amounts, which felt obvious.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by defining a clear data model that captures each pair's classification and, for mismatches, the specific fields that differ. Then describe how to aggregate counts and amounts per classification, using a schema that supports efficient grouping and drill-down. Finally, discuss how to handle edge cases like missing records and ensure the reports are scalable and accurate.

Pro tip: Mention that you would store the classification and mismatch details as structured data (e.g., a JSON field or a separate mismatch table) to enable flexible reporting without reprocessing raw data. Also, highlight the importance of defining clear business rules for matching and mismatch tolerance upfront to avoid ambiguity.

1. Define the output schema

Design a table or view that includes columns for classification (matched, mismatched, unmatched_left, unmatched_right), count, total_amount, and for mismatches, a breakdown by field (e.g., field_name, mismatch_count, mismatch_amount).

2. Classify and enrich pairs

During the reconciliation process, assign each pair a classification and, for mismatches, record which fields differ (e.g., amount, date, status). Store this enriched data in a staging table.

3. Aggregate counts and amounts

Write SQL queries to group by classification and sum counts and amounts. For mismatches, further group by the differing field to produce the breakdown.

4. Handle unmatched records

Ensure unmatched records from either side are included in the aggregation, with their amounts summed appropriately. Consider using a full outer join or union to capture all records.

5. Optimize and present

Optimize queries with indexes on classification and field names, and consider materialized views for performance. Present results in a clear report format, possibly with drill-down capabilities.

Key Points to Mention

  • Data model design: separate tables for pairs, classifications, and mismatch details to avoid data duplication and enable flexible querying.
  • Use of SQL aggregation functions (COUNT, SUM) with GROUP BY on classification and mismatch field.
  • Handling of unmatched records: ensure they are included in counts and totals, possibly with a LEFT/RIGHT JOIN or UNION.
  • Performance considerations: indexing, partitioning, and incremental processing for large datasets.
  • Business rules: define what constitutes a match and how to handle tolerance (e.g., rounding differences).
  • Reporting flexibility: ability to drill down from summary to individual mismatched pairs.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q2

How would you handle duplicate records where the same transaction ID appears more than once on the same side of the reconciliation?

System DesignTechnical Trade-offsRoot Cause Analysis
Author's notes

Blanked for a second.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the reconciliation context and the potential impact of duplicates, then propose a systematic approach: detect, classify, and resolve duplicates while ensuring data integrity and auditability. Emphasize root cause analysis to prevent recurrence and discuss trade-offs between automated and manual handling.

Pro tip: Demonstrate awareness that duplicates might indicate upstream issues like retries or idempotency failures, and propose logging and monitoring to catch them early. Mention that at Stripe, financial accuracy is paramount, so any resolution must be auditable and reversible.

1. Clarify and Scope

Ask clarifying questions about the reconciliation process, data sources, and business impact to understand the severity and context of duplicates.

2. Detect and Classify

Identify duplicates by grouping on transaction ID and side, then classify them as exact duplicates, near-duplicates, or conflicting records based on other fields.

3. Resolve with Rules

Define resolution rules: for exact duplicates, deduplicate keeping the earliest or latest; for conflicting duplicates, flag for manual review or apply business logic.

4. Ensure Auditability

Log all duplicate handling actions with reasons, maintain a separate table for duplicates, and ensure the process is reversible for compliance.

5. Prevent Recurrence

Investigate root causes (e.g., retries, idempotency issues) and implement safeguards like idempotent APIs, unique constraints, or monitoring alerts.

Key Points to Mention

  • Idempotency keys to prevent duplicate processing
  • Database unique constraints and upsert logic
  • Audit trails and logging for financial compliance
  • Root cause analysis (e.g., retry logic, race conditions)
  • Trade-offs between automated deduplication and manual review
  • Monitoring and alerting for duplicate detection

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q3

How do you classify and handle partial matches, for example when the amount agrees but the status field differs, or vice versa?

Data ModelingTechnical Trade-offsProduct Analytics & Metrics
Author's notes

Pretty straightforward conceptually.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying that partial matches require a tiered classification system based on field-level agreement and business impact. Then, walk through a concrete example (e.g., amount matches but status differs) to show how you'd define match confidence levels and handle each case with appropriate actions like auto-merge, manual review, or rejection.

Pro tip: Emphasize that the right handling depends on the cost of false positives vs. false negatives—at Stripe, financial accuracy often means erring on the side of caution and flagging ambiguous cases for review rather than auto-resolving them.

1. Define match criteria and confidence levels

Establish which fields are critical (e.g., amount, currency) and which are secondary (e.g., status, timestamp). Assign confidence scores or tiers (exact, partial, no match) based on field agreement.

2. Classify partial matches by field combination

Enumerate common partial match scenarios (e.g., amount matches but status differs; status matches but amount differs) and map each to a severity level based on business risk.

3. Determine handling strategy per class

For each class, decide on an action: auto-accept, auto-reject, flag for manual review, or apply a fallback rule. Consider the cost of errors and regulatory requirements.

4. Implement and monitor with feedback loops

Build the logic with clear logging and metrics. Monitor false positive/negative rates and iterate on thresholds or rules as data accumulates.

5. Document and communicate trade-offs

Clearly document the rationale for each decision and communicate trade-offs to stakeholders, ensuring alignment on risk tolerance and business impact.

Key Points to Mention

  • Field-level agreement and weighted scoring for match confidence
  • Business impact and cost of false positives vs. false negatives
  • Tiered handling: auto-merge, manual review, rejection
  • Use of thresholds and configurable rules for flexibility
  • Monitoring and feedback loops to refine classification over time
  • Regulatory and compliance considerations in financial systems

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q4

Records from different systems may carry different currencies. How would you normalize currencies before comparing amounts, and what are the failure modes?

System DesignTechnical Trade-offsAPI & Integrations
Author's notes

This one caught me more than I expected from a pipeline question.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the business context and requirements for currency normalization, then propose a robust architecture that handles currency conversion and comparison. Discuss trade-offs between different approaches (e.g., real-time vs. batch conversion) and highlight common failure modes such as stale rates, rounding errors, and missing rates.

Pro tip: Emphasize the importance of using a reliable, versioned exchange rate source and storing both original and normalized amounts for auditability. Mention that Stripe's own APIs often require amounts in the smallest currency unit (e.g., cents) to avoid floating-point issues.

1. Clarify Requirements and Constraints

Ask about the use case: is this for reporting, real-time transactions, or analytics? Determine acceptable latency, accuracy, and whether historical rates are needed.

2. Choose a Normalization Strategy

Decide on a base currency and whether to convert at ingestion, query time, or via a separate service. Consider using a dedicated currency conversion service or library.

3. Implement Conversion with Reliable Rates

Integrate a trusted exchange rate provider (e.g., Open Exchange Rates, ECB) and cache rates with appropriate TTL. Ensure rates are versioned and timestamped.

4. Handle Edge Cases and Failure Modes

Address missing rates, stale rates, rounding discrepancies, and currency fluctuations. Implement fallbacks and alerting for anomalies.

5. Ensure Auditability and Consistency

Store original amounts, converted amounts, and the rate used. Use idempotent operations and consider eventual consistency in distributed systems.

Key Points to Mention

  • Use of a base currency (e.g., USD) for normalization and comparison.
  • Importance of timestamped, versioned exchange rates to handle historical data.
  • Rounding strategies: use decimal arithmetic (not floats) and define rounding rules (e.g., banker's rounding).
  • Failure modes: missing rates, stale rates, rate source outages, rounding errors accumulating, and timezone issues.
  • Trade-offs: real-time conversion (accurate but costly) vs. batch conversion (cheaper but stale).
  • Stripe-specific considerations: amounts in smallest currency unit, multi-currency support in APIs, and webhook handling for rate updates.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q5

Timestamps from the two systems may be in different timezones. How do you normalize them, and does this affect your matching logic?

System DesignTechnical Trade-offs
Author's notes

Normalize to UTC on ingest, full stop.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by acknowledging that timestamps from different systems often have different timezones and formats, so normalization to a common standard like UTC is essential. Explain that you would convert all timestamps to UTC using a reliable library, then adjust matching logic to account for any remaining discrepancies such as precision or daylight saving time. Finally, discuss how this normalization impacts matching by ensuring consistency and reducing false mismatches.

Pro tip: Mention that you would store timestamps in UTC at rest and convert to local time only for display, which is a best practice at companies like Stripe. Also, highlight the importance of logging timezone information to debug issues.

1. Identify timezone sources

Determine the timezones of the systems providing timestamps and whether they include timezone offsets or are naive.

2. Normalize to UTC

Convert all timestamps to UTC using a robust date-time library (e.g., Joda-Time, java.time, moment-timezone) to ensure consistency.

3. Handle precision and format

Standardize precision (e.g., milliseconds) and format (e.g., ISO 8601) to avoid mismatches due to representation differences.

4. Adjust matching logic

Update matching algorithms to compare normalized timestamps, possibly with tolerance for clock skew or network delays.

5. Validate and monitor

Test with edge cases (DST transitions, leap seconds) and monitor for anomalies in production.

Key Points to Mention

  • Use of UTC as a canonical timezone for storage and comparison.
  • Importance of timezone-aware libraries to avoid manual errors.
  • Handling of daylight saving time and leap seconds.
  • Potential need for tolerance windows in matching due to clock skew.
  • Impact on data consistency and idempotency in distributed systems.
  • Logging and auditing timezone conversions for debugging.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q6

Floating-point arithmetic can cause spurious mismatches when comparing monetary amounts. How would you handle this in the reconciliation pipeline?

Algorithms & Data StructuresTechnical Trade-offs
Author's notes

Stored amounts as integers in cents (or the smallest currency unit) and compared those directly.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by acknowledging the problem: floating-point types like float/double cannot exactly represent most decimal fractions, leading to precision errors. Then propose using integer minor units (e.g., cents) or a decimal library for exact arithmetic, and describe how to apply this in the reconciliation pipeline, including parsing, storage, and comparison.

Pro tip: Mention that even with integers, you must define rounding rules for currency conversions and interest calculations, and ensure consistency across systems. Also, consider using a dedicated decimal type like Python's Decimal or Java's BigDecimal for intermediate calculations.

1. Identify the root cause

Explain that floating-point numbers are binary fractions and cannot represent decimal values like 0.1 exactly, causing tiny discrepancies that accumulate.

2. Choose exact representation

Recommend using integer minor units (e.g., cents) or a decimal library (e.g., BigDecimal, Decimal) for all monetary values to avoid precision loss.

3. Apply consistently in pipeline

Ensure all stages—ingestion, storage, computation, and comparison—use the exact representation, and avoid mixing with floating-point types.

4. Handle rounding and conversions

Define explicit rounding rules (e.g., half-up) for currency conversions or interest calculations, and apply them uniformly to prevent mismatches.

5. Validate and test

Implement unit tests with known edge cases (e.g., 0.1 + 0.2) and reconciliation scenarios to ensure correctness and catch regressions.

Key Points to Mention

  • Floating-point precision issues (e.g., 0.1 + 0.2 != 0.3)
  • Integer minor units (cents) as a common solution
  • Decimal libraries (BigDecimal, Decimal) for exact arithmetic
  • Consistent rounding and conversion rules
  • Avoiding floating-point in comparisons and storage
  • Testing with edge cases and reconciliation scenarios

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q7

What test cases would you write to cover each of these edge cases: duplicates, partial matches, currency differences, timezone differences, and floating-point comparisons?

Technical Trade-offsRoot Cause AnalysisSystem Design
Author's notes

I went through them in order which in hindsight was too mechanical.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the context: what system or function is under test (e.g., payment processing, data matching). Then, for each edge case, describe a specific test case that exercises the boundary condition, including the input, expected output, and why it's important. Finally, discuss how you would prioritize and automate these tests.

Pro tip: Mention that you would use property-based testing (e.g., QuickCheck) to generate random inputs for floating-point and currency comparisons, ensuring comprehensive coverage beyond hand-picked cases.

1. Clarify the System Under Test

Ask clarifying questions to understand the function or component being tested, its inputs/outputs, and the business context (e.g., payment processing, data deduplication).

2. Define Test Cases for Each Edge Case

For each edge case, specify a concrete test scenario: input data, expected behavior, and the risk it addresses. Include both positive and negative tests.

3. Explain the Testing Strategy

Describe how you would implement these tests (unit, integration, property-based) and how you would handle non-determinism (e.g., timezones, floating-point).

4. Prioritize and Automate

Discuss which tests are most critical, how you would integrate them into CI/CD, and how you would maintain them over time.

Key Points to Mention

  • Duplicates: test exact duplicates, case-insensitive duplicates, and duplicates with slight variations (e.g., whitespace).
  • Partial matches: test substring matches, fuzzy matching thresholds, and false positives/negatives.
  • Currency differences: test different currencies, rounding rules, and conversion rates; ensure no floating-point errors in monetary calculations.
  • Timezone differences: test UTC vs local times, daylight saving transitions, and cross-timezone date boundaries.
  • Floating-point comparisons: use epsilon-based comparisons, avoid direct equality, and test with values like 0.1 + 0.2.
  • Property-based testing: generate random inputs to cover edge cases automatically.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.