Agentgateway
Open source proxy for LLM, MCP, and agent traffic in one binary
Replaces Kong Ai Gateway, Portkey

Who it's for
Teams running multiple LLM providers and MCP servers behind separate proxies can replace that stack with a single agentgateway binary. The unified policy layer applies the same auth, rate limiting, and audit rules to HTTP services, LLM calls, MCP tool invocations, and agent-to-agent traffic from one config.
If your team only needs LLM routing without MCP or A2A support and already operates a mature service mesh, a narrower LLM proxy requires less operational overhead.
Developers orchestrating agents across LangChain, CrewAI, or Google ADK can route all agent-to-agent and agent-to-tool traffic through agentgateway's A2A and MCP gateways. Per-hop identity tracing and audit logs make it possible to debug complex agent chains without adding custom instrumentation.
If your agents communicate through direct API calls to a single LLM provider and do not use MCP servers, a simpler LLM proxy setup covers the use case at lower operational cost.
Finance and platform teams that need to attribute LLM spend by team or product can use virtual keys and the built-in cost dashboard to cap token consumption and dollar spend per consumer. The CEL-based policy engine enforces fine-grained access rules without running a separate authorization service.
If cost attribution is the only requirement and your team does not need MCP or A2A protocol governance, Portkey's managed cloud service requires no infrastructure to operate.
The problem
Platform teams integrating AI agents into production face a fragmented infrastructure problem. HTTP services need one proxy, LLM routing needs another, and MCP tool calls with agent-to-agent traffic have no standard gateway at all. Each new protocol added to the stack means another control plane to operate, another auth policy to keep synchronized, and another gap in the audit trail. The pain compounds when cost controls become a requirement. Token budgets and spend limits need enforcement at the proxy layer before the invoice arrives, not as after-the-fact alerts in application code. Without a unified gateway, teams accept blind spots in cost attribution or build custom middleware that breaks when a provider changes its API.
How it works
Routes requests to OpenAI, Anthropic, Bedrock, Gemini, Azure OpenAI, and Mistral through a single OpenAI-compatible endpoint. Token budgets, semantic caching, prompt enrichment, load balancing, and failover apply per-route without changes to the calling application.
Proxies Model Context Protocol servers and federates their tools behind a single discovery endpoint. Supports stdio, HTTP, SSE, and Streamable HTTP transports. Each tool call is signed, scoped to the caller's identity, and written to an audit trail.
Routes agent-to-agent calls between LangChain, CrewAI, Google ADK, and custom runtimes using the A2A protocol. Capability discovery, modality negotiation, and identity tracing on every hop make multi-agent orchestration auditable without custom middleware.
Expresses allow/deny rules over method, path, headers, and JWT claims using Google's Common Expression Language. Policies attach at the gateway, listener, route, or backend level and merge into a single per-request decision. Supports external authorization over gRPC or HTTP for teams with existing entitlement services.
Emits token-usage histograms to Prometheus, request traces to Jaeger, and structured logs with status, latency, token counts, and realized USD cost on each request. The agctl CLI adds live proxy tracing and runtime config inspection without a gateway restart.
Issues scoped virtual keys per team, app, or user so every request carries an owner for budgeting and reporting. Hard caps on token consumption and dollar spend cut off usage when a limit is hit rather than alerting after the invoice arrives. A cost dashboard in the admin UI groups spend by model, provider, and user.
Features
- LLM Gateway with unified OpenAI-compatible API
- MCP Gateway with tool federation and auth
- A2A Gateway for agent-to-agent communication
- RBAC with CEL policy engine
- OpenTelemetry observability by default
- Per-team cost controls and virtual keys
How to install
Install the standalone binary with a one-line curl command.
curl -sL https://agentgateway.dev/install | bashRecommended for this setup
Strengths
- Single binary covering four protocol types: One process handles HTTP/gRPC services, LLM providers, MCP servers, and A2A calls. Teams that currently run a dedicated HTTP gateway, a separate LLM proxy, and custom MCP tooling can replace all three with one binary and one config file, cutting the number of control planes to operate.
- Apache-2.0 license with no vendor fees: Runs entirely on your own infrastructure under an Apache-2.0 license. Unlike Kong AI Gateway or Portkey, there are no per-seat charges, no token-usage fees to a gateway vendor, and no proprietary lock-in on policy or config formats.
- Rust runtime with low per-connection overhead: Written in Rust, the proxy keeps per-connection memory overhead low compared to JVM or Node.js-based gateways. The binary also offers native Envoy compatibility for teams that already run Envoy in their service mesh.
- Linux Foundation project with enterprise contributors: Agentgateway is a Linux Foundation project with corporate contributors including Microsoft, AWS, Cisco, Alibaba, Adobe, and Salesforce. The governance model keeps the project neutral and the infrastructure open to community-driven evolution.
Trade-offs
- 300 open GitHub issues on a project under two years old: The repository carried 300 open issues as of October 2026, on a project created in March 2025. That volume is expected for an actively maintained AI infrastructure project, but it means some integrations and edge cases may have known bugs or incomplete documentation. Test against a staging environment before committing to production.
- Kubernetes deployment adds operational complexity: Full Kubernetes support requires deploying the built-in controller and configuring Gateway API resources, adding overhead beyond the standalone binary. Teams without Kubernetes expertise may find the standalone path adequate, but Kubernetes-specific features are unavailable in that mode and the two deployment paths have separate documentation.
- MCP and A2A are emerging, fast-changing protocols: Model Context Protocol and A2A are relatively new specifications. Agentgateway tracks them actively, but upstream protocol changes can require gateway updates. Teams building production systems on MCP or A2A should expect periodic API changes as the specs stabilize.
Tech stack
FAQ
Yes. Agentgateway is Apache-2.0 licensed and free to run on your own infrastructure. There are no per-seat charges or token-usage fees to a gateway vendor. An Enterprise offering is listed on the website but the core open source binary has no feature limits in the self-hosted deployment.
Agentgateway routes to OpenAI, Anthropic, Google Gemini, AWS Bedrock, Azure OpenAI, Mistral, DeepSeek, Ollama, Vertex AI, Meta/Llama, xAI, Perplexity, Replicate, Snowflake, and NVIDIA NIM through a unified OpenAI-compatible API. Self-hosted inference runtimes including vLLM, TGI, and Triton are also supported with latency-aware and cost-aware routing.
Yes. Agentgateway ships a built-in Kubernetes controller with Gateway API support for declarative config. There is also a standalone binary mode driven by flat YAML config for deployments outside Kubernetes. Documentation for both modes is at agentgateway.dev/docs, where the two deployment paths have separate doc sections.
Kong AI Gateway is a proprietary commercial extension of Kong's API gateway for LLM routing, with no self-hosted open source path for AI features. Agentgateway is Apache-2.0 licensed and self-hosted. The key functional difference is protocol coverage: agentgateway adds native MCP and A2A protocol support, which Kong AI Gateway does not offer. Teams needing governance across MCP servers and agent-to-agent calls alongside LLM routing have no path to that with Kong AI Gateway today.
Agentgateway is written in Rust. The Rust runtime keeps memory overhead low per connection compared to JVM or Node.js-based gateways, which matters for teams running high-concurrency LLM traffic. The binary also provides native Envoy compatibility for teams that already run Envoy as part of their service mesh.