Cloudflare AI Gateway adds analytics, caching and rate limits in front of provider accounts, and charges 5% on credits when Cloudflare bills your inference. RouterPlus bills each provider's price with no fee line, and adds reserved capacity and sourced providers.
Cloudflare AI Gateway
// 5% on Unified Billing credits
const client = new OpenAI({
baseURL: "https://gateway.ai.cloudflare.com/v1/{account}/{gateway}/compat",
apiKey: process.env.CF_API_TOKEN,
});
RouterPlus
// provider price, no fee line
const client = new OpenAI({
baseURL: "https://api.routerplus.com/v1",
apiKey: process.env.ROUTERPLUS_API_KEY,
});
RouterPlus is the better fit when you want inference at provider prices with no credit fee, routing on your own evals, and capacity reserved across providers. Cloudflare AI Gateway observes and caches traffic to provider accounts and adds 5% to Unified Billing credits.13
What is the difference between RouterPlus and Cloudflare AI Gateway?
Cloudflare AI Gateway is an observability and control layer at Cloudflare's edge, over provider keys or Cloudflare credits. RouterPlus is an inference gateway: one key at each provider's price, routing on your evals, and reserved capacity for teams at scale.41
Which is cheaper, RouterPlus or Cloudflare AI Gateway?
With your own provider keys, neither charges on tokens. When the gateway bills your inference, Cloudflare adds 5% to the credits you buy, while RouterPlus charges each provider's listed price with no fee line.317
Can RouterPlus replace Cloudflare AI Gateway?
Yes, for chat traffic on models in the RouterPlus catalog: change the base URL, key and model IDs. Cloudflare features such as edge caching or DLP scanning stay with Cloudflare if you use them.58
Does RouterPlus store my prompts?
Billing and analytics keep metadata only. Requests to shared endpoints go to an encrypted request log for up to 30 days, for debugging. Dedicated endpoints and organizations that opt out are never logged.9
How do I switch from Cloudflare AI Gateway to RouterPlus?
Point your client at https://api.routerplus.com/v1, use a RouterPlus key and map model names to RouterPlus catalog IDs. The OpenAI and Anthropic SDKs work unchanged.8