DX Heroes logo
#apis
#engineering

What is an API gateway?

Length: 

3 min

Published: 

June 9, 2026

What is an API gateway?

What is an API gateway?

An API gateway is a single entry point that sits in front of your backend services and receives every incoming request. Instead of letting clients call dozens of services directly, they all talk to the gateway, which then routes each request to the right service and returns the answer.

The gateway also takes care of jobs that every service would otherwise have to repeat: checking who is calling (authentication), limiting how many requests each client may send (rate limiting), and recording what happened (logging). It is a common pattern in systems built from many small services, where managing each one separately would be a mess.

In plain words

Think of an API gateway as the reception desk in a large office building. Visitors do not wander the corridors looking for the right room. They check in at one desk, get verified, and are pointed to where they need to go. The desk also keeps a log of who came in. The gateway is that desk for your software: one front door for everyone, with the security and direction handled in one place.

Why it matters

  • One front door. Clients learn one address and one set of rules, even when many services sit behind it.
  • Shared concerns in one place. Authentication, rate limiting, caching, and logging live in the gateway, not copied into every service.
  • Freedom to change the inside. You can split, merge, or move services behind the gateway without breaking the clients calling it.

Common pitfalls

  • It becomes a single point of failure. If the gateway goes down, everything behind it is unreachable. Run it with redundancy.
  • Too much logic in the gateway. Routing and security belong there. Business rules do not, or the gateway turns into a tangle no one wants to touch.
  • Added latency. Every request now makes an extra hop. Usually small, but worth measuring under load.
  • Confusing it with a load balancer. A load balancer spreads traffic across copies of one service. A gateway routes by what is being asked for and adds API-level features on top.

Related articles:

  • What is an API? - The basic idea a gateway sits in front of.
  • What is a REST API? - The most common kind of API a gateway routes.
  • What is an API key? - One of the things a gateway checks before letting a request through.

Want to stay one step ahead?

Don't miss our best insights. No spam, just practical analyses, invitations to exclusive events, and podcast summaries delivered straight to your inbox.