Airbnb logo

How Airbnb scaled its backend

Breaking apart a Ruby on Rails monolith without breaking the business

Airbnb's original Ruby on Rails monolith let a small team move fast in the early days, but as the company and engineering org grew, that same monolith became the thing slowing everyone down - every team's code lived in one repository, one deploy pipeline, and one runtime, so a change anywhere could break something everywhere.

Airbnb runs a global marketplace connecting millions of hosts and guests across a huge number of listings worldwide, with a large engineering organization that outgrew what a single shared codebase and deploy process could support - the technical challenge was less about raw request volume and more about how many engineers could safely ship changes to the same system at once.

Interactive

Airbnb’s stack, mapped

Grouped by where each piece sits in the request path. Click through to see what each one is actually for.

Infrastructure

Edge & delivery

Services & language

Data & messaging

Backend framework (core)

·

Ruby on Rails

Airbnb's original monolith, and still a significant part of its backend today, is built on Ruby on Rails - chosen in the company's early days for how quickly it let a small team ship a working product.

Click a piece of Airbnb’s stack to see what it’s for

The same stack, in plain language

Ruby on Rails

Backend framework (core)

Airbnb's original monolith, and still a significant part of its backend today, is built on Ruby on Rails - chosen in the company's early days for how quickly it let a small team ship a working product.

Thrift

Service communication (RPC)

As Airbnb split its monolith into services, it adopted Thrift to define and call APIs between those services - a way for one internal service to call another with a strongly typed contract instead of loosely-defined HTTP calls.

Apache Airflow

Workflow orchestration (built in-house)

A tool Airbnb built internally to schedule and monitor complex data pipelines - many small jobs with dependencies between them - and later open-sourced; it's since become one of the most widely used workflow schedulers in the industry.

Druid

Real-time analytics datastore

Used for dashboards and analytics that need to query very large volumes of event data with low latency, where a traditional data warehouse would be too slow to query interactively.

Kubernetes

Container orchestration

Airbnb migrated its service infrastructure onto Kubernetes, moving away from earlier in-house deployment tooling, to get a more standard, community-supported way of scheduling and scaling its large number of services.

MySQL

Primary relational database

Airbnb's core transactional data - listings, bookings, users - has long lived in MySQL, sharded and scaled as the company grew rather than replaced outright.

Java

Backend language (newer services)

Used for a number of newer backend services built after the move away from a single Rails codebase, particularly infrastructure-facing services where the JVM's performance and tooling ecosystem were a better fit than Ruby.

Kafka

Event streaming

Moves event data - bookings, search activity, pricing changes - between services and into the data pipelines that feed tools like Airflow and Druid, without every producer and consumer needing to be directly connected.

How it actually works

Extracting services from the monolith, deliberately and incrementally

Airbnb has written extensively about the multi-year effort to pull functionality out of its original Rails monolith into independently deployable services, using Thrift to define clear contracts between them. Rather than a rewrite, the publicly documented approach was incremental extraction - identifying a bounded piece of functionality, building it as a standalone service, and migrating callers over to it while the monolith kept running everything else. The stated goal wasn't microservices as an end in itself, but letting more engineers ship changes safely and independently without waiting on a single shared codebase's deploy queue.

Building Apache Airflow because the right tool didn't exist yet

As Airbnb's data pipelines grew more complex - many small jobs with dependencies on each other, needing to run on a schedule and be monitored for failure - the company built Apache Airflow internally, then open-sourced it. Airflow represents pipelines as a directed graph of tasks, so a failure in one step can be retried or alerted on without silently corrupting everything downstream. It's since become one of the most widely adopted data orchestration tools outside Airbnb entirely, which is a useful signal that the underlying problem - scheduling and monitoring interdependent data jobs reliably - is a genuinely common one, not unique to Airbnb.

Standardizing infrastructure on Kubernetes

Airbnb has documented moving its service infrastructure onto Kubernetes, replacing earlier custom deployment and scheduling tooling built in-house. The stated motivation in their public writing is consistency and reduced maintenance burden - running on a widely adopted, actively developed open-source scheduler instead of continuing to maintain bespoke internal tooling that only Airbnb's own infrastructure team understood.

Treating the migration itself as an engineering problem

A recurring theme in Airbnb's public engineering writing about the SOA migration is that the transition process itself needed careful engineering - tooling to run old and new code paths side by side, ways to verify a new service produced the same results as the code it was replacing, and a gradual rollout rather than a single cutover. The lesson emphasized repeatedly is that a large-scale architectural migration is itself a project that needs its own safety mechanisms, not just a destination to reach.

What “microservices” means here, concretely

Airbnb's backend today is a mix of its original Ruby on Rails monolith (still handling a meaningful share of functionality) and a growing number of independently deployable services - many in Java - extracted from it over several years, communicating over Thrift-defined APIs and scheduled on Kubernetes rather than the monolith's original deployment process.

Takeaway

Airbnb's public engineering writing is less about a single clever technology and more about how to migrate a large, business-critical monolith into services without stopping the business - incrementally, with tooling built specifically to make the migration itself safe.

Based on

  • Airbnb Engineering Blog - migrating to a service-oriented architecture
  • Airbnb Engineering Blog - building and open-sourcing Apache Airflow
  • Airbnb Engineering Blog - building Airbnb's Kubernetes infrastructure