Skip to main content

OpenRouter API key setup

Unified LLM router: one API key, many providers. The free tier gives you 50 req/day of free models with no card required; the free model pool rotates.

Get your key

  1. Open the OpenRouter API keys page: openrouter.ai/keys
  2. Create an account and generate an API key.
  3. Paste it into the Dracon BYOK provider keys, stored encrypted (AES-256-GCM), used browser-direct, works in every Dracon tool.

Use your key in every tab

Two free extensions take the key you just set up. Both read the page you are on and use your own provider key: free, no account, nothing stored on a server we run.

SamAI

Summarize or ask about any page with your own provider key.

Add to Chrome Add to Firefox

AI Auto Form Filler

Complete a web form from a short description, using a model you bring yourself.

Add to Chrome Add to Firefox

All extensions · last checked 2026-10-22.

Get the key and test it

  1. Open the OpenRouter API keys page: openrouter.ai/keys Create a key and copy the secret straight away.
  2. Point your client at this provider's base URL: https://openrouter.ai/api/v1 It speaks the OpenAI-compatible shape, so an OpenAI SDK client works against it with no adapter: only the base URL and the key change.
  3. Prove the endpoint answers before you trust it. Send one call with no Authorization header: a live endpoint answers 401 Unauthorized, because it is waiting for a bearer key. The wording of that error differs by provider (some say invalid_api_key, others incorrect_api_key or Token is invalid), so read the 401 as the signal, not the error text.
  4. Paste the key into the Dracon BYOK provider keys ; stored encrypted, used browser-direct, no relay.
  5. Compare other provider plans when this subscription does not match your usage or budget.

Test the key

Both examples read the key from the OPENROUTER_API_KEY environment variable, so the key stays out of the command line.

export OPENROUTER_API_KEY="<YOUR_API_KEY>"

curl https://openrouter.ai/api/v1/chat/completions \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"google/gemini-2.5-flash","messages":[{"role":"user","content":"hi"}]}'
import os
from openai import OpenAI

# export OPENROUTER_API_KEY="<YOUR_API_KEY>" first
client = OpenAI(
    api_key=os.environ["OPENROUTER_API_KEY"],
    base_url="https://openrouter.ai/api/v1",
)
resp = client.chat.completions.create(
    model="google/gemini-2.5-flash",
    messages=[{"role": "user", "content": "hi"}],
)
print(resp.choices[0].message.content)

Free tier

Yes. OpenRouter's free tier gives you 50 req/day of free models with no card. Add $10 in PAYG credits to unlock 1,000 req/day of free models. The free model pool rotates, so check the provider's pricing page for current specifics. no credit card required

Rate limits: 50 req/day on the base free tier; $10 in PAYG credits unlocks 1,000 req/day of free models (model pool rotates)

Connection details

Base URL
https://openrouter.ai/api/v1
API shape
OpenAI-compatible
Env var
OPENROUTER_API_KEY
Models
google/gemini-2.5-flash, deepseek/deepseek-chat-v3-0324, meta-llama/llama-3.3-70b-instruct
Model lineup
Llama 3.3 70B, Mistral Large, Qwen 3 235B, DeepSeek V3, Claude 3.5 Sonnet (paid)

Our verdicts on this kind of provider

Independent comparisons we keep current as pricing and free tiers shift. A guide is setup; a verdict is whether it's worth setting up.

Add your OpenRouter key Add this provider to a fallback list Compare provider plans