Serverless
A cloud model where you run code without managing servers—you just deploy functions.
Serverless computing lets you run code without provisioning or managing servers. You deploy functions, and the cloud provider handles everything else.
How it works: 1. You write a function 2. You deploy it to a serverless platform 3. The platform runs it when triggered 4. You pay only for execution time
Key characteristics: - Auto-scaling: Handles any traffic level automatically - Pay-per-use: No cost when not running - No maintenance: No servers to patch or update - Event-driven: Functions run in response to triggers
Common triggers: - HTTP requests (API endpoints) - Database changes - File uploads - Scheduled timers (cron) - Message queues
Platforms: - AWS Lambda: The original serverless platform - Vercel Functions: Great for Next.js - Cloudflare Workers: Edge-first approach - Supabase Edge Functions: Integrated with Supabase
Limitations: - Cold starts (first request can be slow) - Execution time limits (usually 10-60 seconds) - Stateless (no persistent local storage) - Vendor lock-in
Examples
- •A Vercel API route handling form submissions
- •AWS Lambda processing image uploads
- •Cloudflare Worker handling auth at the edge