# How Stripe Used MongoDB Sharding and Replication to Scale Payments with Minimal Downtime

DevFeed: [How Stripe Used MongoDB Sharding and Replication to Scale Payments with Minimal Downtime](<https://devfeed.tech/articles/how-stripe-processed-1-trillion-in-payments-with-zero-downtime-17979.md>)

Original publisher: [Read original article](<https://newsletter.betterstack.com/p/how-stripe-processed-1-trillion-in>)

Author: Richard Oliver Bray

Published: 2024-12-04T14:02:44Z

Content type: article

Language: en

Sources: [Hacking Scale by Better Stack](<https://devfeed.tech/sources/hacking-scale-by-better-stack.md>)

Topics: [MongoDB](<https://devfeed.tech/topics/mongodb.md>), [Databases](<https://devfeed.tech/topics/databases.md>), [Replication](<https://devfeed.tech/topics/replication.md>), [Database](<https://devfeed.tech/topics/database.md>)

Tags: [database](<https://devfeed.tech/tags/database.md>), [developer](<https://devfeed.tech/tags/developer.md>), [mongodb](<https://devfeed.tech/tags/mongodb.md>), [replication](<https://devfeed.tech/tags/replication.md>), [sharding](<https://devfeed.tech/tags/sharding.md>)

## AI overview

The article explains how Stripe used MongoDB, sharding, replication sets, and query routing to scale payment data while maintaining reliability during migrations. It describes the database architecture and the roles of shards, replicas, Mongos instances, and config servers.

## Source excerpt

Stripe's hand-crafted system that guarantees their data never gets lost