Prompt
I'm building a low-traffic SaaS backend, what serverless option makes sense?
Latest observation
For a low-traffic SaaS backend, a serverless option usually makes a lot of sense—especially if you want to keep ops, cost, and scaling simple.
Best fit in most cases
AWS Lambda + API Gateway
Good if you want:
- very low idle cost
- automatic scaling
- broad ecosystem/support
- easy integration with AWS services
Typical stack:
- API Gateway for HTTP endpoints
- Lambda for backend logic
- DynamoDB or Aurora Serverless for data
- S3 for files/static assets
- Cognito or external auth for login
Other strong options
Cloudflare Workers
Great if your backend is:
- mostly request/response APIs
- edge-friendly
- lightweight and fast
- okay with a more limited runtime than AWS Lambda
Best for:
- simple APIs
- auth/session handling
- proxying/edge logic
Less ideal if you need:
- long-running jobs
- heavy CPU work
- lots of traditional backend dependencies
Google Cloud Functions / Cloud Run
Good if you want:
- simpler container-based deployment
- more flexibility than pure functions
- good fit for modern web apps
Cloud Run is often a better choice than Cloud Functions if you want serverless but with a normal container and fewer runtime constraints.
Azure Functions
Makes sense mainly if you’re already in the Microsoft/Azure ecosystem.
What I’d recommend by scenario
Choose AWS Lambda if:
- you want the safest “default” for a SaaS backend
- you expect moderate growth
- you want mature serverless tooling
Choose Cloud Run if:
- you want serverless without function constraints
- you prefer containerized deployment
- you may later outgrow pure function architecture
Choose Cloudflare Workers if:
- your app is small, global, and API-light
- you care about low latency and low cost
- you can live within Workers limitations
Important caveats for SaaS
Serverless is great, but watch out for:
- cold starts on some platforms
- database connection management
- timeouts for long tasks
- vendor lock-in
- local dev/testing complexity
For many SaaS apps, the biggest decision is actually the database, not the compute layer.
Simple recommendation
If you want a practical default:
- Backend compute: AWS Lambda
- API: API Gateway
- DB: Postgres on Aurora Serverless v2 or a managed Postgres provider
- Auth: Auth0 / Cognito / Clerk
- Jobs: SQS + Lambda or a scheduler
If you want, I can also suggest the best serverless stack for your specific SaaS type (e.g. B2B app, CRUD app, AI app, webhook-heavy app, etc.).