Skip to content
OpenAI-compatible · 7-day free key · Function calling

The AI API that picks the best model for you

Drop-in replacement for the OpenAI API. Use model: "auto" and ZeroOptimize™ routes every request to the best free AI model available. The chain below is live.

cURL
Python
JavaScript
from openai import OpenAI

client = OpenAI(
    base_url="https://www.zerolimitai.com/api/v1",
    api_key="YOUR_API_KEY",
)

response = client.chat.completions.create(
    model="auto",           # ZeroOptimize™ picks the best free model
    messages=[{"role": "user", "content": "Hello!"}],
)

print(response.choices[0].message.content)
model: "auto"→ZeroOptimize™ picks the best free model automatically

$0

per call, on every plan

< 2 lines

migration from OpenAI

24h

model refresh cycle

2,000

calls/day for $99 a year

See it in 76 seconds

Free key, two settings in Cline, a request, and what happens when the top model is busy.

Get started in minutes

If you already use the OpenAI SDK, it's literally 2 lines.

cURL
curl https://www.zerolimitai.com/api/v1/chat/completions \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "auto",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'
Chat with an agent (with memory)
# Chat with a persistent AI agent (with memory)
curl -X POST https://www.zerolimitai.com/api/v1/chat \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "agentId": "YOUR_AGENT_ID",
    "messages": [{"role": "user", "content": "What do you remember about my project?"}]
  }'
JavaScript / TypeScript
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://www.zerolimitai.com/api/v1",
  apiKey: "YOUR_API_KEY",
});

const response = await client.chat.completions.create({
  model: "auto",   // ZeroOptimize™ picks the best free model
  messages: [{ role: "user", content: "Hello!" }],
});

console.log(response.choices[0].message.content);
Drop-in backend

Use it with the editor you already have

Anything that speaks the OpenAI format and lets you set a base URL works with ZeroLimitAI unchanged — no plugin, no adapter. Point it here and every request routes to the best free model.

ClineVS Code
Settings → API Provider → OpenAI Compatible
Base URL:  https://www.zerolimitai.com/api/v1
API Key:   zlai_your_key_here
Model ID:  auto
Full Cline guide →
Roo CodeVS Code
Settings → Provider → OpenAI Compatible
Base URL:  https://www.zerolimitai.com/api/v1
API Key:   zlai_your_key_here
Model ID:  auto
Full Roo Code guide →
ContinueVS Code · JetBrains
~/.continue/config.yaml
name: My Assistant
version: 1.0.0
schema: v1
models:
  - name: ZeroLimitAI
    provider: openai
    model: auto
    apiBase: https://www.zerolimitai.com/api/v1
    apiKey: zlai_your_key_here
    roles: [chat, edit, apply]
Full Continue guide →
AiderTerminal
Environment variables
export OPENAI_API_BASE=https://www.zerolimitai.com/api/v1
export OPENAI_API_KEY=zlai_your_key_here

aider --model openai/auto
Full Aider guide →
OpenCodeTerminal
opencode.json
{
  "$schema": "https://opencode.ai/config.json",
  "provider": {
    "zerolimitai": {
      "npm": "@ai-sdk/openai-compatible",
      "name": "ZeroLimitAI",
      "options": {
        "baseURL": "https://www.zerolimitai.com/api/v1",
        "apiKey": "{env:ZEROLIMITAI_API_KEY}"
      },
      "models": {
        "auto": { "name": "ZeroOptimize auto" }
      }
    }
  }
}
Full OpenCode guide →
Open WebUISelf-hosted chat UI
Docker environment, or Admin Settings → Connections
docker run -d -p 3000:8080 \
  -e OPENAI_API_BASE_URL=https://www.zerolimitai.com/api/v1 \
  -e OPENAI_API_KEY=zlai_your_key_here \
  ghcr.io/open-webui/open-webui:main
Full Open WebUI guide →
LibreChatSelf-hosted chat UI
librechat.yaml + .env
endpoints:
  custom:
    - name: "ZeroLimitAI"
      apiKey: "${ZEROLIMITAI_API_KEY}"
      baseURL: "https://www.zerolimitai.com/api/v1"
      models:
        default: ["auto"]
        fetch: false
      titleConvo: true
      titleModel: "auto"
      modelDisplayLabel: "ZeroLimitAI"
Full LibreChat guide →
LangChainPython · JavaScript
ChatOpenAI client
from langchain_openai import ChatOpenAI

llm = ChatOpenAI(
    model="auto",
    base_url="https://www.zerolimitai.com/api/v1",
    api_key="zlai_your_key_here",
)
print(llm.invoke("Say hello in one sentence").content)
Full LangChain guide →

Using something else? If it accepts a custom base_url, it already works. Tell us what you use and we'll add the snippet.

Everything you need in production

Not just a proxy — a full developer platform.

ZeroOptimize™ auto-routing

Use model: "auto" and our algorithm picks the best available free model for every request — no guessing, no stale model IDs, and failover when a model is busy.

OpenAI-compatible

Change base_url and api_key. Nothing else. Every app built on the OpenAI SDK works with ZeroLimitAI out of the box.

Models updated daily

ZeroOptimize™ re-evaluates the model landscape every 24h. Your API always routes to the current best — without you touching a line of code.

Streaming SSE

Full server-sent events streaming, identical to OpenAI's format. Stream responses in real-time with any SSE-compatible client.

Webhooks

Receive real-time events (message.created, agent.created) with HMAC-SHA256 signed payloads — ready for Zapier, Make, or your own backend.

Secure & private

Your data is never used to train models. API keys are bcrypt-hashed. Bearer token auth, per-key rate limiting, full audit log.

Usage dashboard

Track today's and this month's API calls against your daily limit, from the Developer page or GET /api/v1/usage.

Embed widget

Drop an AI chat widget on any website with a single <iframe>. Connect it to any of your agents. No backend needed.

ZeroOptimize™

Stop hardcoding model names.
Let the algorithm decide.

Every 24 hours, ZeroOptimize™ ranks the free models on measured quality (published benchmarks and LM Arena human-preference votes), fitness for the job and our own latency data. Your calls go to the top model that is answering, with automatic fallback if it is busy or down.

  • Always the best model without code changes
  • Automatic failover to the next model when one is busy or down
  • Free models re-ranked daily — live list at /leaderboard
  • Or specify any model explicitly — full control

# ZeroOptimize™ routing right now

1. Google: Gemma 4 31B (free)GoogleACTIVE
2. Google: Gemma 4 26B A4B (free)GoogleSTANDBY
3. Cohere: North Mini Code (free)CohereSTANDBY
4. Recursive: Flint (free)recursiveSTANDBY
5. XingChen: Xing4.0 29B A4B (free)xingchen-agiSTANDBY

Live · re-ranked every 24h · health checked daily · a request goes to the first ACTIVE model and falls through on failure

Simple API pricing

Start free. Scale when you need to.

Free week

$0for 7 days

Try the API before you pay: wire it into your editor or app and see it answer. No credit card.

25 calls/dayBest free models via ZeroOptimize™
  • 25 API calls/day for 7 days
  • All ZeroOptimize™ free models
  • OpenAI-compatible endpoint, streaming and tools
  • For evaluation — production needs Annual
  • No card, no automatic charge
Start the free week

Annual

$99/year

2,000 API calls a day, plus the full ZeroLimitAI platform. Free models first, paid models as backup. Cancel any time.

$59/year in Latin America.

2,000 calls/dayFree models first, paid backup at our cost
  • 2,000 API calls/day
  • Paid models answer when the free ones are busy, within a monthly fair-use allowance
  • Beyond it, your own free Groq/OpenRouter key, no limit of ours
  • Webhooks (5 endpoints)
  • Embed widget for any site
  • Unlimited chat + 100 images/day
  • 5 custom AI agents
  • Developer dashboard
  • Billed yearly, cancel any time
  • 30-day money-back guarantee
Get Annual — $99/yr

All plans include the OpenAI-compatible endpoint, usage dashboard, and ZeroOptimize™ auto-routing. Annual renews yearly and can be cancelled any time. When the free models are busy or used up, paid models answer at our cost, within a monthly fair-use allowance. Beyond it, your own free OpenRouter or Groq key takes over. Only want the app, without the API? The Chat plan is $19 a year. Need more? Add your own key, or write to hello@zerolimitai.com.

Lifetime is no longer sold (since 26 October 2026). Accounts that bought it keep everything they bought.

FAQ

Is model: "auto" really free?

Yes. When you use model: "auto", ZeroOptimize™ routes your request to the highest-ranked free AI model available at that moment (the free catalog changes week to week); the live chain on this page shows which. These models are offered free by their providers via open APIs. You pay $0 per call: the daily quota of your plan is the only limit. On Annual, when the free models are busy or the shared free allowance is used up, a paid model answers at our cost, not yours.

Can I try the API before paying?

Yes. Sign up with email or Google and generate an API key straight away — no credit card. The key works for 7 days with 25 calls/day, enough to wire it into Cline, Continue or your own code and see it answer. After that the key needs the Annual plan: $99/year ($59 in Latin America), 2,000 calls/day. There is no automatic charge.

Does it work with Cline, Continue, Aider or Cursor?

Yes — anything that speaks the OpenAI format and lets you set a custom base URL works unchanged, with no plugin or adapter. Point the tool at https://www.zerolimitai.com/api/v1, paste your key, and use "auto" as the model. See the setup snippets above for Cline, Roo Code, Continue, Aider, Open WebUI and LangChain. Editors that hardcode their own endpoint (some Cursor features do) are the exception.

Is the API really OpenAI-compatible?

For chat completions, yes: /api/v1/chat/completions takes the same request body and returns the same response and streaming format as OpenAI. Any library that supports a custom base_url works — openai-python, openai-node, LangChain, LlamaIndex, and more. Function calling (tools) is supported; embeddings are not yet.

What models are available?

Every plan routes to the best free models available: whichever tops the live rankings at that moment. Plans differ by call volume and features, not model quality: the API always serves the top-ranked free model. Use GET /api/v1/models to list everything available.

How does ZeroOptimize™ choose the model?

Every 24h we rank the free models on measured quality: Artificial Analysis intelligence, coding and agentic indexes, plus LM Arena human-preference votes, adjusted for context window, output length, tool and JSON support, and our own latency and failure data. Requests go to the top-ranked model that is answering right now. If it fails or rate-limits, the next best is tried automatically — no downtime for your app.

You route through OpenRouter — how do I know I'm getting a good version of the model?

A fair question, and the honest answer has two halves. Where the criticism lands: a gateway can serve the same model at different quantisations, context limits and speeds depending on which provider picks up the request, and we do not pin that — nobody offering free inference can. Where it does not: we do not ask you to trust a benchmark we ran once. The model that answered is named in every response, its quality score and the method behind it are published on /leaderboard, its health is measured on real production traffic rather than a status page, and if it rate-limits or goes quiet the next model answers instead of an error reaching you. If a paid gateway's verified model/provider pairing is what you need, buy it — that is a different product from free-model routing, and a reasonable thing to want.

What happens when the free models are busy?

On Annual, free models answer first. When they are busy or the shared daily free allowance is used up, paid models answer at our cost, within a monthly fair-use allowance per account. Beyond that allowance, your own free OpenRouter or Groq key (added in Integrations) takes over, with no limit of ours. You are never charged per call, and the model field in each response says which model answered.

What happened to Lifetime?

Lifetime stopped being sold on 26 October 2026. It promised a fixed amount of free-model capacity for good, and that is not something we can guarantee: the free allowance is shared and outside our control. Accounts that bought Lifetime keep everything they bought, plus their own keys and a small paid backup. For new customers, the API plan is Annual.

Can I build a commercial product on top of the API?

Yes, on Annual. The API is licensed for commercial use, including products that serve your own end users, within your plan's daily call limit (2,000/day). The free week is for evaluation, not for serving users. The chat UI, agents and the Telegram integration are for personal and team use — a service for third parties goes through the API. Need more? Add your own key, or write to hello@zerolimitai.com.

Can I pick a specific model?

Yes. Send model: "auto" (or omit it) and ZeroOptimize™ picks the best free model for you — that is the recommended default. Send a concrete id from GET /api/v1/models and that model is used first, with the rest of the chain still behind it as failover, so a momentary outage returns an answer instead of an error. An id we do not serve — an OpenAI or Anthropic name, a model we retired — is routed by ZeroOptimize instead of failing, so an app pointed at us keeps working when its hardcoded model name means nothing here. It is never silent: the model field in the response always reports which model actually replied, and X-ZeroOptimize-Substituted-From carries the id you asked for.

What happens when I hit the daily limit?

Requests return HTTP 429 with a Retry-After header — never an automatic charge or overage. Daily limits reset at midnight UTC. On Annual, add your own free Groq or OpenRouter key in Integrations and requests carry on past the quota with no limit of ours. When a free week ends, the key returns HTTP 402 upgrade_required until the account has a plan.

Technical questions

Not covered here? The support assistant (bottom right) answers from the same facts, no sign-up needed.

What does a request look like?

A standard OpenAI chat completion with your key as a Bearer token. Omit model or send "auto" and ZeroOptimize™ picks the model; the model field in the response says which one answered.

curl https://www.zerolimitai.com/api/v1/chat/completions \
  -H "Authorization: Bearer $ZLAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"auto","messages":[{"role":"user","content":"Hello"}]}'

Which endpoints are there?

POST /api/v1/chat/completions (alias /api/v1/chat) for chat. GET /api/v1/models lists "auto" plus the models currently in the chain. GET /api/v1/usage shows today's calls against your quota. The OpenAPI spec is at /api/v1/openapi.json and a plain-text summary for AI tools at /llms.txt.

Which request fields are supported?

messages (system, user and assistant roles, text content), model ("auto" or an id from /api/v1/models), stream (true or false) and agentId (prepends the instructions of one of your agents). temperature, top_p, stop, seed, presence_penalty and frequency_penalty are passed to the model's provider; max_tokens (or max_completion_tokens) caps the answer and returns finish_reason "length" when it cuts. Out-of-range values get a 400 invalid_param. Function calling works: send tools (and tool_choice, parallel_tool_calls) and the request goes to the best free model that supports tools, with the same failover; tool results come back as role "tool" messages. Embeddings and image inputs are not available on the API today.

How does streaming work?

Send stream: true and you get text/event-stream with OpenAI-format chat.completion.chunk events, ending with data: [DONE]. The OpenAI SDKs and tools like Cline handle it as they do with OpenAI.

What are the rate limits?

A daily quota per account: 25 calls/day during the free week and 2,000 on Annual (accounts that bought Lifetime keep their quota), reset at 00:00 UTC. One thing worth knowing about the free week: the upstream free-model allowance is shared by everyone, so when it runs low we hold the second half of each day for paying accounts and free requests are served by the providers with their own quota — still an answer, from a lesser model. When it is contended, no single account may use more than 40% of it, paid or not, so one heavy user cannot leave the others with nothing. Free accounts can send up to about 16,000 input tokens per request (bigger ones get 413 request_too_large). On top of that, 60 requests per minute per key and 120 per minute per IP. Every response carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset; a 429 also carries Retry-After.

What do errors look like?

OpenAI's shape: { error: { message, type, code } }. Codes: invalid_key (401), upgrade_required (402, the free week is over), account_suspended (403), invalid_json, missing_messages and invalid_param (400), agent_not_found (404), request_too_large (413, free accounts over ~16,000 input tokens), rate_limited and daily_limit (429), upstream_error (502, every model in the chain failed: retry in a minute). A model name we do not serve is not an error: it is routed and the response carries X-ZeroOptimize-Substituted-From. Each response has an X-Request-Id; include it if you write to us.

How fast is it, and what if a model is down?

The first token usually arrives in a few seconds; it can take up to about 20 seconds when the top model reasons before answering. If a model rate-limits, errors or stays silent for 45 seconds, the same request moves to the next model in the chain, so you get a slower answer rather than an error. Live state of the chain: /status.

How long can prompts and answers be?

It depends on the model that answers. The ranking marks down models with under 32k tokens of context or under 4k of output, so the top of the chain handles long prompts; if a request is too long for one model, the next one is tried.

What happens to my prompts?

We never train on them or sell them, and the API stores only call counts and token estimates for your quota, not the text. Requests are also never routed to a provider that may train on them: OpenRouter publishes each provider's policy and we send data_collection=deny on every call, so the four providers it lists as training on prompts (DeepSeek, Liquid, NVIDIA, Thinking Machines) are excluded from our chain, even when that means fewer models. What remains: a provider may still retain a prompt for a period under its own terms, so don't send secrets you couldn't share with a third party. Identical requests may be answered from a one-hour cache, and a hit requires the entire request to match.

Start building in 2 minutes

Sign up, generate your API key, and make your first call — no credit card, no waiting.

Six use cases with code and cost math · Live service health: zerolimitai.com/status

Stop paying per token.

One endpoint. $0 inference.

Free 7-day API key in a minute · no card. Then $99 a year.