We have seen startups fail because they scaled too early — and because they did not scale at all. Here is the balanced approach.
By David Friedman, Founder of AppBrewers
Startups face a paradox: build for scale or ship fast? The answer is both. Build for the next order of magnitude, not the next decade. Here is our architecture playbook.
The Stages of Scale
| Stage | Users | Architecture | Cost |
|---|---|---|---|
| MVP | 0-100 | Monolith, serverless | 0-50 Euro/month |
| Product-market fit | 100-10,000 | Same stack, optimize queries | 50-300 Euro/month |
| Growth | 10,000-100,000 | Caching, CDN, read replicas | 300-2,000 Euro/month |
| Scale | 100,000+ | Microservices, dedicated infra | 2,000+ Euro/month |
Principles for Every Stage
1. Database First
Your database is your bottleneck. Design it carefully.
- Normalize until you have a reason to denormalize
- Index foreign keys and query patterns
- Use connection pooling
- Plan for read replicas before you need them
2. Stateless Services
Application servers should be stateless. Store session data in Redis, not memory.
Why: You can add servers instantly without sticky sessions.
3. Async by Default
| Operation | Sync | Async |
|---|---|---|
| User login | Yes | No |
| Send welcome email | No | Yes (queue) |
| Generate PDF report | No | Yes (background job) |
| Process image upload | No | Yes (worker) |
4. Caching Strategy
| Layer | Tool | TTL |
|---|---|---|
| CDN | Cloudflare | Static assets, 1 year |
| Edge | Vercel Edge | API responses, 60s |
| Application | Redis | Session data, 24h |
| Database | PostgreSQL | Query cache, auto |
5. Monitoring from Day One
- Error tracking (Sentry)
- Performance monitoring (Datadog, New Relic)
- Uptime monitoring (Pingdom, UptimeRobot)
- Log aggregation (LogRocket, Datadog)
Anti-Patterns to Avoid
- Premature microservices: Monoliths scale further than you think
- No database indexes: 100 users feels fast, 10,000 does not
- Synchronous third-party calls: Always queue external API calls
- No rate limiting: One abusive user can take down your app
- Ignoring cold starts: Serverless needs warm-up strategies
Our Scalable Stack
| Layer | Technology | Scales To |
|---|---|---|
| Frontend | Next.js 15 | 1M+ users |
| API | Next.js API / tRPC | 1M+ users |
| Database | PostgreSQL + Prisma | 10M+ users |
| Cache | Redis (Upstash) | Unlimited |
| Queue | Bull + Redis | Unlimited |
| Storage | S3 / Cloudflare R2 | Unlimited |
| CDN | Cloudflare | Unlimited |
Need Scalable Architecture?
We design architectures that grow with your startup. From MVP to millions of users. No over-engineering. Malta-based cloud architects.
Originally published on the AppBrewers Blog.
Top comments (0)