Ask Cat › AI Tool Summary › aider
Aider + OpenRouter Free Models: Full 2026 Setup Guide (Install, API Key, and Living on 50 Requests a Day)
Article last updated:2026-09-06
Aider is an AI pair-programmer that lives in your terminal: you describe a change, it edits the files on your machine, and it commits the result for you. The tool itself is Apache 2.0 open source and free — the bill comes from the model you feed it (that is also what our own 2026-09-05 verification record says).
Which raises the obvious question: can the model be free too? Yes — point it at OpenRouter’s :free model variants. On 2026-09-06 we queried OpenRouter’s model list API directly: out of 430 models, 18 have a :free variant, several of them coding-oriented.
This is not a pricing article. It is the whole wiring job, step by step, from the official aider and OpenRouter documentation.
Step 1: Install aider
The shortest path in the official docs is two lines (you need Python 3.8–3.13):
python -m pip install aider-install
aider-install
That installs aider into its own isolated Python environment, and will pull down a separate Python 3.12 if it needs one, so nothing pollutes your existing setup.
If you would rather not touch Python at all, there are one-liners:
- Mac / Linux:
curl -LsSf https://aider.chat/install.sh | sh - Windows:
powershell -ExecutionPolicy ByPass -c "irm https://aider.chat/install.ps1 | iex"
There are also uv tool install --force --python python3.12 --with pip aider-chat@latest and pipx install aider-chat. One thing the docs say explicitly: do not install aider from a system package manager — those builds often carry the wrong dependencies.
Step 2: Where the API key goes (pick one of three)
Aider has dedicated switches for OpenAI and Anthropic; every other provider, OpenRouter included, uses the generic mechanisms. All three below are straight from the docs:
1. Environment variable
export OPENROUTER_API_KEY=<key> # Mac / Linux
setx OPENROUTER_API_KEY <key> # Windows
On Windows you must close and reopen the shell after setx. That is the number one cause of “I set the key and it still says there is no key”.
2. A .env file in the project
OPENROUTER_API_KEY=<key>
3. The .aider.conf.yml config file
api-key:
- openrouter=<key>
The third form simply sets OPENROUTER_API_KEY for you. For a one-off test, --api-key openrouter=<key> on the command line does the same thing.
Step 3: Pick a model — list them first
Start aider from inside your project directory. This matters: aider works against the git repo in the current folder.
cd /to/your/project
aider --list-models openrouter/
aider --model openrouter/<provider>/<model>
--list-models openrouter/ prints every model your key can reach. Spotting the free ones is easy: the ID ends in :free.
Among the 18 free variants we captured on 2026-09-06, the coding-leaning ones included cohere/north-mini-code:free, poolside/laguna-s-2.1:free, minimax/minimax-m3:free and nvidia/nemotron-3-super-120b-a12b:free, with context windows ranging from 65K to 1M tokens. That roster changes fast — trust your own --list-models output, not our snapshot.
Step 4: The trap the docs warn about — privacy settings
This one comes from aider’s own OpenRouter page: if you hit errors, check your OpenRouter privacy settings and enable providers that may train on inputs, so that all models are available to you.
In other words, part of the price of “free” is looser data terms. That is a trade-off, not a bug:
- Practising, or working on a personal project? Turn it on; usually fine.
- Company or client source code? That single setting is enough to rule the free route out. Use paid models.
If you would rather not flip it globally, aider reads a .aider.model.settings.yml from your home directory or repo root, where you can steer providers per model:
- name: openrouter/anthropic/claude-3.7-sonnet
extra_params:
extra_body:
provider:
order: ["Anthropic", "Together"]
allow_fallbacks: false
data_collection: "deny"
require_parameters: true
Note that data_collection: "deny" and “enable providers that may train on inputs” are two knobs pointing in opposite directions: one protects your data, the other buys you free capacity. Decide which you actually want. The full provider-routing syntax is in our guide on choosing cheaper OpenRouter providers.
Step 5: What 50 requests a day actually feels like
Here are the free-tier numbers from OpenRouter’s own limits documentation — we read the constants in the document source rather than repeating a second-hand figure:
| Credits purchased (all time) | Requests per minute | Requests per day |
|---|---|---|
| Less than US$10 | 20 | 50 |
| At least US$10 | 20 | 1,000 |
So a brand-new account that has never bought credits gets 50 requests a day. And aider does not spend those as “50 conversations”: every message you send costs at least one, and in architect mode — one model to plan, another to edit — a single message costs at least two. Fifty disappears quickly.
Ways to stretch it (all of these are in aider’s own tips, and they happen to save requests too):
- Only
/addthe files that actually need editing. The docs say plainly: don’t add lots of files. Irrelevant code distracts the model, and aider already has a map of the whole repo. /dropa file once it is done. Add the next one when you get to it; don’t drag dead weight through the conversation./clearwhen it gets stuck. Wiping the chat history and starting fresh is cheaper than fighting a bad context.- Plan with
/ask, then execute with/code. Ask mode discusses without touching files; once the plan is agreed, “go ahead” in code mode is enough. Getting it right once beats three retries. - Take bite-sized steps, one at a time.
When you hit the wall you get a 429, and the error response carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset telling you which limit you hit; a 402 means credits, not rate. To watch your remaining quota before it bites, call GET https://openrouter.ai/api/v1/key. The full breakdown of those limits is in our OpenRouter free-model daily limit guide.
Step 6: Git is your safety net — leave it on
Aider is tightly bound to git, and that matters more on free models, which get things wrong more often:
- Every time it edits a file, it commits the change with a descriptive message.
- If you had uncommitted work, it commits that first, so your edits and the AI’s edits stay cleanly separated.
- Broke something?
/undodiscards the last change./diffshows what changed this round,/committidies up dirty files,/gitruns raw git commands.
There is --no-auto-commits and even --no-git if you insist, but the docs themselves call that not recommended — and on free models it is a particularly bad idea.
The short version
Aider is free, OpenRouter has 18 free models, and the combination really does give you zero-cost code editing. The two things you have to accept: looser data terms, and the discipline of 50 requests a day. Great for practice and personal projects; not the route for client code.
Steps and figures verified on 2026-09-06 against the aider installation docs, the aider OpenRouter page, the aider API keys docs, the OpenRouter limits documentation, and a same-day pull of the OpenRouter models API. Free-model rosters and limits change without notice; check the official pages. Our cost breakdown for the tool is on the aider tool page.
What Amo and Pimi think
For engineers doing AI pair programming in the terminal, it's a free and stable choice — pair it with a local model and you save even the API cost. But you'll need to bring your own LLM key and manage costs yourself. For non-engineers or people who want a graphical interface, this tool's barrier is too high — don't force it.
Let's take a look at these
- aider Comprehensive Introduction: Pricing, Features, and Actual Limitations
- aider Is the free quota enough?
- aider Alternatives
- Comprehensive Free Quota List for All Tools

