Serverless lets you run code without managing servers—you write functions, cloud provider runs them. AWS Lambda, Vercel Functions, Cloudflare Workers. Pay per execution, auto-scales to zero (no cost when idle), scales infinitely. Perfect for event-driven workloads (process uploaded file, send email, webhook handler). Not actually "serverless"—servers exist, you just don't manage them. Great for startups, avoid DevOps complexity.
Use serverless for event-driven tasks (image processing, scheduled jobs, webhooks), APIs with unpredictable traffic (auto-scales), background jobs (queue processing), or when you want zero DevOps. Great for startups with limited eng resources. Don't use for long-running tasks (15-min timeout), high-frequency low-latency (cold starts), or stateful workloads (functions are ephemeral).
System Design Patterns
Code runs only when triggered