AI Inference Benchmark: Keln vs Fireworks, Baseten, Modal, DeepInfra & Z.ai
CompareCloudflare AI Gateway5 min read

Keln vs Cloudflare AI Gateway. Cloudflare AI Gateway alternative: an inference platform for open models.

Open models, as reliable as a frontier API. Keln next to Cloudflare AI Gateway.

To move from Cloudflare AI Gateway to Keln you change the base URL and the key, and drop the provider prefix from the model id. The rest of your code does not change. The same key also works in Claude Desktop, Claude Code and Codex. Below is what changes after the move: pricing, speed and reliability, model quality, data retention and the model catalog.

TL;DR

Cloudflare AI Gateway sits between your app and the model providers you already pay, and adds logs, a cache, rate limits and fallback rules. It serves no models of its own: for open models you either use Workers AI, Cloudflare's own service that runs a set of open models on its GPUs, or send the request through the gateway to another provider. Keln is an inference platform for open models: it serves a small list of models, manages the infrastructure and capacity, and checks every model against the released weights. Every model has one price. Keln has zero data retention by default. Keln's goal is open models with the same uptime and consistency a developer gets from OpenAI or Anthropic.

The differences:

1. Pricing

The gateway itself is free on every plan, and you pay for the model calls that go through it. With your own provider keys, each provider bills you at its own price. With Unified Billing you buy credits from Cloudflare and pay the provider's price plus a 5% fee on every purchase, so $100 of credits costs $105. Models on Workers AI, Cloudflare's own service that runs open models on its GPUs, are billed per token at Cloudflare's rates, with a free daily allowance.

On Keln every model has one rate. There is no platform fee. Top-ups start at $5 and credits never expire. The rate card is on the Models page and in the API, and the dashboard shows the cost of each request. Failed requests are free.

2. Speed and reliability

In Cloudflare AI Gateway you set the routing rules yourself. A dynamic route can split traffic by percentage, branch on a header or a metadata field, and switch to a fallback when a key goes over a request or budget limit. If a provider returns an error, the gateway retries up to five times and then tries the next provider in your list. A timeout counts until the first part of the response arrives. After that the gateway waits for the provider however long it takes. The routing does not read a provider's speed or health, so a provider that answers slowly gets the same traffic as a fast one.

On Keln speed and reliability are part of the service. Keln targets a first token in under 2 seconds and at least 50 tokens per second. If a stream stops, it resumes from the last token and the app sees one response. Keln does not time out a request that is still being served.

3. Model quality

Cloudflare AI Gateway forwards your request to the provider you named and records what came back: status, tokens, cost, duration. It does not check the answer itself. A provider can run a quantized copy of a model under the same model id, and the logs look normal while the answers get a little worse. The user catches that with evals, spot checks and reading answers by hand.

Keln checks the answers. Model quality is verified continuously against the released weights, with checks on quantization, tool calls and modality. Capacity that serves a quantized copy, degrades its output or truncates context is removed until it passes again. A small, curated catalog makes keeping a high quality bar possible.

4. Data retention

Cloudflare AI Gateway logs every request by default, and a log can include the prompt and the response. You can turn logging off for the whole gateway, skip it for one request with a header, or keep the metadata and drop the bodies. The gateway has no setting for what the provider keeps. That depends on your agreement with each provider.

Keln is built for businesses, so zero data retention is the default. No provider stores prompts or completions or trains on them. Keln holds a prompt and its completion in memory only while the request runs and deletes them when the response ends. Keln requires zero retention and zero training from every provider before it serves a request, and rechecks the terms continuously. There is no flag to set and no special plan to buy. Details in Privacy & zero data retention.

5. Model catalog

Cloudflare AI Gateway connects to 24 providers, from OpenAI and Anthropic to DeepSeek, Groq and OpenRouter, each in its own API format. Open models on Cloudflare's own GPUs come through Workers AI, a catalog of 70 models with Llama, Qwen, GPT-OSS and DeepSeek among them. If your product calls several providers and wants one place for logs, limits and a cache, Cloudflare is built for that. You pick the provider and the model, and the gateway forwards the request.

Keln serves a curated list of open text models: the best performing ones on benchmarks, like Kimi K3, Qwen3.8 Max, GLM 5.3 and DeepSeek V4, plus smaller and faster ones. Each is verified before it is listed and checked continuously after. You can request a model from the catalog in the portal: the team reviews the request, and the model is live and ready to use in a couple of days. The same list works in Claude Desktop, Claude Code and Codex, where the picker shows the models with tool calling and reasoning, and the rest stay available through the API.

Switching

Keln supports the OpenAI Chat Completions and Responses APIs. The base URL becomes https://api.keln.ai/v1 and the key becomes your Keln key. Model ids follow the maker/model shape, like openai/gpt-oss-120b, with no provider prefix. If you called a provider's native format through the gateway, switch that call to the OpenAI SDK pointed at Keln. The quickstart shows the change for each SDK. Keln also supports the Anthropic Messages format, which is how Claude Code and Claude Desktop run on it.

The same key also works outside your code. Claude Desktop, Claude Code and Codex can all run on Keln's models with a two-minute setup:

Who each is for

Keln's case is strongest for teams that ship a product on open models, cannot have a bad answer or a dead stream reach a user, and do not want anyone on the team owning inference. Cloudflare's case is strongest for teams that already have providers and want visibility and control over calls they make anyway.

When to pick Cloudflare AI Gateway

  • You call closed models like GPT or Claude together with open ones and want one place for logs, limits and a cache.
  • You want to keep paying each provider directly with your own keys.
  • You want a response cache for repeated prompts.
  • You route traffic by rules: percentage splits, per-key budgets, tests between two models.
  • Your app already runs on Cloudflare Workers.

When to pick Keln

  • You want a curated list of open models that are verified before they are listed.
  • You want to ship on open models reliably, without anyone on the team owning inference.
  • You want to know the model you pay for is the model you get, not a quantized copy.
  • You want the same price for the same model on every request.
  • You want speed and reliability managed for you, including on long streams.
  • You want zero data retention on every request, with no flag to set and no plan tier to be on.
  • You want the same open models in Claude Desktop, Claude Code and Codex.

Side by side

KelnCloudflare AI Gateway
PriceOne rate per modelWorkers AI rates, or other providers' prices plus 5% on Cloudflare credits
Speed and reliabilityManaged by KelnRules you write
Model qualityOutput checked continuouslyNot checked
Quantized providersCaught and removedNot detected
Data retentionZero, on every providerPrompts logged by default
ModelsSmall, curated, verified24 providers; 70 models on Workers AI
APIOpenAI, Anthropic, Vercel SDKOpenAI-compatible, provider-native

Cloudflare AI Gateway details are taken from its public documentation on the day of writing. Fees, plan limits and routing rules can change, so check its docs before you decide.

Keln vs Cloudflare AI Gateway: questions

No. It sits between your app and the providers you already pay, and adds logs, a cache, rate limits and fallback rules. It serves no models of its own apart from Workers AI. Keln serves the models and verifies their quality.

Keln has one rate per model. With Cloudflare AI Gateway you pay Workers AI rates or each provider's own price, plus 5% when you pay with Cloudflare credits.

Yes, by default for text models.

Keln suits teams that ship on open-source models and want verified models and one price. Cloudflare AI Gateway suits teams that already have provider accounts and want logs, a cache and rules over calls they make anyway.

Cloudflare AI GatewayComparePricingReliabilityZero data retention

Switch in two lines

Change the base URL and the key. Keep your OpenAI SDK code.