Apache APISIX
Apache APISIX is an API gateway configured through routes, upstreams, plugins, and an administrative API.
Why consider Apache APISIX?
Apache APISIX is a dynamic, high-performance API gateway and AI gateway that handles traffic management for microservices and LLM workloads.
Learn Apache APISIX by building
Practical setup notes, real use cases, and copy-ready examples in one focused guide.
In this guide3 sections
Apache APISIX: Dynamic API and AI Gateway
Apache APISIX is a high-performance, open-source API gateway built on top of NGINX and etcd. It is engineered to process and route traffic for modern APIs, microservices, and increasingly, AI-driven workloads. One of its defining characteristics is its fully dynamic architecture—administrators can update configurations, add new routes, and hot-load plugins without ever needing to restart the underlying service.
Microservices and API Traffic Control
As microservice deployments grow in complexity, managing the flow of data between disparate services becomes critical. APISIX addresses these challenges by offering rich traffic management features designed for both traditional north-south traffic from external clients and internal east-west traffic between internal services.
The gateway supports a wide array of core operations natively:
- Load Balancing: Distribute incoming requests across multiple upstream nodes to ensure high availability and responsiveness.
- Dynamic Upstreams: Adjust backend service endpoints on the fly as infrastructure scales up or down.
- Deployment Strategies: Safely roll out new features using canary releases, blue-green deployments, and A/B testing.
- Resilience: Protect backend systems with circuit breaking, rate limiting, and observability integrations to detect and mitigate malicious attacks.
Furthermore, APISIX is platform-agnostic. It can be deployed on bare-metal servers or run efficiently in cloud-native environments, including serving as a dedicated Kubernetes ingress controller. It also extends beyond basic HTTP by proxying gRPC, Dubbo, MQTT, and WebSocket traffic, making it a versatile tool for diverse protocol requirements.
Unified AI Gateway and LLM Management
In addition to traditional API routing, APISIX has evolved to serve as a specialized AI gateway. Using its extensible plugin system, APISIX enables teams to route requests to various Large Language Model (LLM) providers through a single, unified interface. This abstraction simplifies client applications, which no longer need to manage provider-specific SDKs or authentication mechanics.
Key AI proxying capabilities include:
- LLM Load Balancing and Fallbacks: If a primary provider experiences downtime or latency, APISIX can automatically retry or fall back to an alternative model, ensuring consistent reliability for AI agents.
- Cost and Traffic Control: Administrators can implement token-based rate limiting to prevent cost overruns and protect upstream LLM endpoints from abuse.
- Robust Security: Centralize authentication and authorization for all AI workloads, ensuring that sensitive prompts and responses are properly governed.
- MCP Bridge: The gateway includes a plugin to seamlessly convert stdio-based Model Context Protocol (MCP) servers into scalable HTTP Server-Sent Events (SSE) services.
Setup and Basic Routing Example
For teams looking to evaluate APISIX, the project provides a streamlined installation process via Docker. The official quickstart script downloads and starts both the APISIX gateway (listening on port 9080) and its required etcd configuration store.
To bootstrap the environment, run the following command:
curl -sL https://run.api7.ai/apisix/quickstart | shAfter the container initializes, you can verify that the gateway is responding by querying the proxy port. Configuration is handled entirely through a REST Admin API exposed on port 9180.
To create your first dynamic route that proxies traffic to an upstream destination, send a PUT request with your routing logic. The following example configures a round-robin upstream pointing to httpbin.org:
curl -i "http://127.0.0.1:9180/apisix/admin/routes/1" -X PUT -d '{ "uri": "/get", "upstream": { "type": "roundrobin", "nodes": { "httpbin.org:80": 1 } }}'Because APISIX is fully dynamic, the route becomes active immediately without a service restart. Sending a request to http://127.0.0.1:9080/get will now seamlessly forward the payload to the configured upstream. By combining this dynamic routing core with an expansive library of plugins, APISIX allows operations teams to precisely govern API and AI traffic at scale.
Related tools
More options with a similar category or technology profile.
diskus
Minimal, fast alternative to du -sh written in Rust using multi-threaded directory traversal.
peco
Simplistic interactive filtering tool for Unix pipelines, process lists, and file trees.
Dapr CLI
Command-line tool for managing Dapr distributed application runtime environments and sidecars.
Freeze
Generate beautiful image screenshots and SVGs of code snippets and terminal outputs.