# cua vs gateway
_Agent Infrastructure · independent comparison_

> cua and gateway are both open-source agent infrastructure you can self-host for free. cua has wider GitHub adoption — 21k stars vs 13k. Neither is universally better — pick by fit.

## Side by side

**cua**
- Open source · Infrastructure · 21k★ · Python · MIT · active today
- Best for: Background computer-use across macOS, Windows, and Linux without stealing focus.
- Avoid if: You need a runtime older than Python 3.11.
- [listing](https://agentsearchengine.app/agents/cua) · [official](https://cua.ai)

**gateway**
- Open source · Infrastructure · 13k★ · TypeScript · MIT · active 2 months ago
- Best for: Routing a single fast API across 250+ LLMs from 40+ providers.
- [listing](https://agentsearchengine.app/agents/gateway) · [official](https://portkey.ai/features/ai-gateway)

## Key differences

- cua has wider GitHub adoption — 21k stars vs 13k.
- cua is written primarily in Python; gateway in TypeScript.

## Which to choose

**Choose cua if:** Background computer-use across macOS, Windows, and Linux without stealing focus.

**Choose gateway if:** Routing a single fast API across 250+ LLMs from 40+ providers.

## FAQ

**What's the main difference between cua and gateway?**
cua has wider GitHub adoption — 21k stars vs 13k.

**Is cua or gateway better?**
Neither is universally better. cua is the stronger fit for Background computer-use across macOS, Windows, and Linux without stealing focus; gateway for Routing a single fast API across 250+ LLMs from 40+ providers. Use the side-by-side specs to decide by your own constraints.

**Is cua or gateway free?**
cua is free to run and self-host; gateway is free to run and self-host. Both are free to self-host — you only pay for the infrastructure and any model or API usage.

**Which is more popular, cua or gateway?**
By GitHub stars — a proxy for open-source adoption — cua is ahead (21k vs 13k). Stars measure attention, not necessarily the better fit for you.

---
Source: [Agent Search Engine](https://agentsearchengine.app) — https://agentsearchengine.app/compare/cua-vs-gateway
