LiteLLM vs Portkey

LiteLLM fits teams that want to self-host a gateway and own the operations, and Portkey fits teams that want a managed platform with request logs and a paid production plan. If your main worry is one agent run draining a budget, RelayPlane is a free local proxy for that one job.

We make RelayPlane, a free open source proxy, so we say where LiteLLM and Portkey fit better.

How we compared them

Both tools sit between your app and your model providers, so they get compared a lot. They answer different questions, and the right pick depends on which question is yours. We took four criteria that matter to a developer or team lead choosing tooling, and checked each option against its own public pages. Where a page did not say, we left it out.

  • Where it runs and who operates it
  • What it costs you besides model spend
  • What you see after each request
  • How spend limits are scoped

LiteLLM

LiteLLM is an open source AI gateway with one OpenAI style interface across 100+ LLM providers. Its docs describe a self-hosted proxy with virtual keys, cost tracking and an admin UI, plus retry and fallback logic across deployments through its Router. Budgets can be set per key or per team.

The drawback is the work. Merge, which sells a competing gateway, points out that you deploy, scale and monitor LiteLLM yourself, and an outage there can affect every AI feature behind it. That is a fair reading. If you have a platform team, owning the gateway is often the point. The repo also links a hosted proxy and an enterprise tier, and we did not find a price for them in the pages we fetched.

Portkey

Portkey ships an open source gateway you can run locally with npx, and a hosted platform around it. Its repo says it routes to 250+ LLMs. The hosted side is where it differs most from LiteLLM. Its pricing page lists a free Developer plan with 10k recorded logs per month, and says that plan is not suitable for production workloads. The Production plan is $49/month with 100k recorded logs per month. Logs and traces are the center of the product.

The cost shows up as a second bill. Merge notes that Portkey charges for the gateway platform itself, on top of what you pay LLM providers. On Portkey's own page, SSO and granular budget and rate limits sit in the Enterprise column, which is custom priced. If you want request level debugging and team controls without running servers, that trade can be worth it.

RelayPlane

RelayPlane is a free, MIT licensed proxy that runs on your machine. It does less than either of the above. It does not try to cover the widest provider list or give you a hosted dashboard with team seats. What it does is meter what each agent run costs and stop a runaway one. A daily cap is one command from the budget cap docs, and the proxy checks it before a request is forwarded. Per run caps use a request header, described in the runs docs. Our LiteLLM compare page covers the same ground in more detail.

npm install -g @relayplane/proxy
relayplane start
relayplane cap set --day 10

The install and start lines are from the installation docs. If you only want the idea, see what an LLM proxy does.

Which one fits whom

If you need to route across a very large provider list from your own infrastructure, in our view LiteLLM is the better fit. If you want logs, traces and a managed service and can pay for production use, in our view Portkey is the better fit. If you run Claude Code or your own agents and mostly want a hard dollar limit before a loop gets expensive, RelayPlane is the smaller tool for that. Many teams will run one of the gateways for routing and add a cap on top.

Sources

Competitor facts on this page come from these pages. Prices change, so each was checked on the date shown.