BlogArchitecture
Architecture10 min read

Database Scaling Economics: When to Shard, Cache, or Rewrite

Database scaling decisions are $100K-$1M investments. Make them with economic frameworks.

By Richard Ewing·

The Scaling Decision Tree

Read caching (cheapest): Redis/Memcached layer. Cost: $5-20K implementation + $500-2K/month infrastructure. Handles: 5-10x read scale. Try this first.

Read replicas: Cost: $10-30K setup + $500-3K/month per replica. Handles: 10-50x read scale.

Sharding: Cost: $100K-500K implementation. Handles: 100x+ scale. But adds permanent operational complexity. Only shard when other options are exhausted.

Rewrite/migration: Cost: $200K-1M+. Consider only when the current database is fundamentally wrong for the workload.

Like this analysis?

Get the weekly engineering economics briefing — one email, every Monday.

Subscribe Free →

More in Architecture

Published Work

This article expands on ideas from my published work in CIO.com, Built In, Mind the Product, and HackerNoon. View published articles →

📊

Richard Ewing

The Product Economist — Quantifying engineering economics for technology leaders, PE firms, and boards.