· Iren Saltali · education · 2 min read
When to Use an API Gateway vs. a Reverse Proxy
A practical decision guide for teams deciding whether they need an edge API gateway or a thinner traffic-forwarding layer.
The short answer: Choose a gateway when you need request-aware behavior like auth, route policy, and transformation; choose a thinner reverse proxy when simple forwarding is enough.
When to read this
- You are comparing architecture options before deployment.
- You need to justify gateway complexity to the team.
- You want to avoid over-engineering early traffic flow.
What matters in practice
- The main distinction is not branding; it is where cross-cutting API behavior lives.
- Serverless API Gateway is most useful when config-driven auth and request shaping matter.
- If you only need hostname or port forwarding, a reverse proxy may be enough.
Concrete example
| Need | Reverse proxy | Serverless API Gateway |
| --- | --- | --- |
| Basic forwarding | Strong fit | Strong fit |
| Route-level auth | Manual add-on | Built into the route model |
| JWT/Auth0/Supabase hooks | External logic | Current repo supports all three |
| Header/query mapping | Manual config or code | Current repo supports both |The example above is intentionally small because the best gateway configs stay readable. Add only the route, auth, and mapping behavior you actually need.
How this maps to the current gateway
The current codebase already supports the behavior discussed here through its config schema, route matcher, and integration handlers. That is why this project is a good fit for reader-first examples: the docs and blog can point to real, implemented behavior instead of hypothetical gateway features.
What this product does not do
- This gateway does not try to replace every enterprise API management feature.
- A reverse proxy may still be simpler for purely internal static forwarding cases.
FAQ
Can this project act as a reverse proxy?
Yes. It supports HTTP proxy routing, but it adds API-aware features on top.
Should I always start with a gateway?
No. Start with the simplest thing that matches your real requirements.
Related docs
- choosing proxy vs service
- routing multi upstream patterns
- config driven gateways vs code driven gateways
Last reviewed: March 6, 2026
