ZenMode

ZenMode

Share this post

ZenMode
ZenMode
Splitwise - System Design [HLD]

Splitwise - System Design [HLD]

Prepare for System Design Interview on design a Splitwise like system

venkat's avatar
venkat
Nov 03, 2024
∙ Paid

Share this post

ZenMode
ZenMode
Splitwise - System Design [HLD]
Share

In this post, we will learn about the splitwise system design.

Splitwise is a free tool for friends and roommates to track bills and other shared expenses so everyone gets paid back.


It’s an app available on Android and IOS that helps users track their expenses. Users can split their expenses for trips, movies, taxis, or any other day-to-day expenditures between family, roommates, and friends. Users just need to enter the expense in the system, Splitwise simplifies and tracks the overall settlement status. Users can enter the expense details, and the app gives a choice of split the user wants like exact, equal, or percentage. The app keeps the history of all expenses and allows to record a payment. The app also allows users to make a group and track expenses in that group.

Top Tips to Create an App Like Splitwise: Cost and Features

1. Requirements Gathering

Before designing the system, it's essential to identify the key functional and non-functional requirements for Splitwise.

Let’s understand a little deeper of the function requirements.

Functional Requirements:

  • Users can create accounts and log in.

  • Users can create or join groups.

  • Users can add expenses for themselves or a group.

  • Users can assign expenses to one or more members of the group.

  • The system should automatically calculate each user's share and the amount they owe or are owed.

  • Users can settle up balances by making payments outside the app (e.g., cash, bank transfer, etc.) and record the payment.

  • Users should be able to see a summary of what they owe and who owes them.

  • Support for multiple currencies.

  • Notifications for expense additions and updates.

Non-Functional Requirements:

  • Scalability: The system should be able to handle millions of users.

  • Performance: Responses should be quick, especially for frequently accessed data like balances and recent transactions.

  • Availability: The system should be highly available, especially for core functions like adding expenses.

  • Consistency: Balances and amounts owed must be accurate at all times (eventual consistency).

  • Security: Sensitive user data (e.g., personal information, transaction details) must be secured.


2. High-Level Architecture

2.1. System Components:

  • Frontend (Client App):

    • Web app and mobile apps (iOS/Android) for user interaction.

    • Supports various platforms and browsers.

    • Connects to backend services via APIs.

  • Backend (Microservices Architecture):

    • Authentication Service: Manages user login, signup, password resets, etc.

    • Expense Management Service: Manages the creation and modification of expenses.

    • Balance Calculation Service: Handles logic for calculating who owes whom and how much.

    • Notification Service: Push notifications, and email alerts for expense updates.

    • Settlement Service: This is for recording payments and settling balances.

    • Currency Conversion Service: Handles conversions for expenses in different currencies.

  • Database:

    • Stores user data, expenses, and balances.

    • Handles sharding and replication to ensure scalability.

  • External Services:

    • Payment Gateway (optional): In case the app later supports online payments for settling balances.

    • Currency Exchange APIs: For real-time exchange rates.

2.2. High-Level System Diagram:

This post is for paid subscribers

Already a paid subscriber? Sign in
© 2025 venkat
Privacy ∙ Terms ∙ Collection notice
Start writingGet the app
Substack is the home for great culture

Share