# Free LLM API access for students and side projects

> You don't need a company card to build with real models. Between a no-spend free tier, a $2/mo plan if you outgrow it, and routing on free-tier keys you may already have from providers like Google AI Studio, there's a durable way to stay at $0 while a class project or side hustle is still finding its shape.

- Date: July 12, 2026
- Category: guides
- HTML: https://anyrouter.dev/blog/free-llm-api-for-students

## What should a free LLM API actually give a student project?

A student budget usually means no company card and no appetite for a trial that quietly expires. What matters is three things: models good enough to actually ship something with, a standard API so the code isn't thrown away later, and a way to stay at $0 that doesn't have a hard deadline.

AnyRouter covers all three the same way it does for any account. The free path isn't a stripped-down mode, it's the same OpenAI-compatible endpoint and the same catalog, just with free models instead of a card.

## Start with anyrouter/free: Go and up, no credit spend

anyrouter/free routes to healthy free-tier capacity on Go and higher, with no daily limit and no credit required. A Go plan is free when you donate one working key, and the Free plan gets a 5-request lifetime trial. It's the fastest way to wire a class project or prototype to a real model before deciding whether it's worth paying for tokens.

### curl

```bash
curl https://anyrouter.dev/api/v1/chat/completions \
  -H "Authorization: Bearer $ANYROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "anyrouter/free",
    "messages": [{ "role": "user", "content": "Explain what an API key is in one short sentence." }]
  }'
```

### Python

```python
import os
import requests

res = requests.post(
    "https://anyrouter.dev/api/v1/chat/completions",
    headers={"Authorization": "Bearer " + os.environ["ANYROUTER_API_KEY"]},
    json={
        "model": "anyrouter/free",
        "messages": [{"role": "user", "content": "Explain what an API key is in one short sentence."}],
    },
)
print(res.json()["choices"][0]["message"]["content"])
```

### JavaScript

```javascript
const res = await fetch("https://anyrouter.dev/api/v1/chat/completions", {
  method: "POST",
  headers: {
    Authorization: "Bearer " + process.env.ANYROUTER_API_KEY,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    model: "anyrouter/free",
    messages: [{ role: "user", content: "Explain what an API key is in one short sentence." }],
  }),
})
const data = await res.json()
console.log(data.choices[0].message.content)
```

### OpenAI SDK

```python
import os
from openai import OpenAI

client = OpenAI(
    base_url="https://anyrouter.dev/api/v1",
    api_key=os.environ["ANYROUTER_API_KEY"],
)

res = client.chat.completions.create(
    model="anyrouter/free",
    messages=[{"role": "user", "content": "Explain what an API key is in one short sentence."}],
)
print(res.choices[0].message.content)
```

```json
{
  "object": "chat.completion",
  "model": "google/gemini-2.5-flash",
  "choices": [
    {
      "message": {
        "role": "assistant",
        "content": "An API key is a unique secret code used to identify and authenticate a user or application making a request to a software service."
      },
      "finish_reason": "stop"
    }
  ],
  "usage": { "prompt_tokens": 12, "completion_tokens": 25, "total_tokens": 37, "cost": 0 }
}
```

_A real response, abridged. The model field names the free model that answered._

Because it's the same endpoint as every paid model, nothing about this code changes later if the project outgrows the free models.

## Pick a free model

anyrouter/free chooses for you. If you want a specific model, these are the free ones live in the catalog right now. Search them, filter by provider or long context, and copy the model id into the same request.

_(Interactive embed `free-models-card` — see the [HTML version](https://anyrouter.dev/blog).)_

## Use it from your terminal

The anyr CLI installs in one line, signs you in on first run, and points a coding agent at a free model. Pick the agent you already use.

### Claude Code

```bash
curl -fsSL https://anyrouter.dev/cli.sh | bash
anyr claude --model "anyrouter/free"
```

### Codex

```bash
curl -fsSL https://anyrouter.dev/cli.sh | bash
anyr codex --model "anyrouter/free"
```

### OpenCode

```bash
curl -fsSL https://anyrouter.dev/cli.sh | bash
anyr opencode --model "anyrouter/free"
```

Free models are available on Go. A Go plan costs $2/month, or it is free when you donate one working provider key to the Pool. The Free plan gets a 5-request lifetime trial on free models.

## When the free tier is not enough

A side project that starts getting real use will outgrow free models alone. Go is $2/mo. A $4 credit added to your balance automatically (roughly 16M tokens on fast models) on top of the free-tier models. If usage keeps growing from there, Pro ($10/mo), Pro+ ($45/mo), and Max ($100/mo) raise the rolling rate-limit window.

| Plan | Price | What changes |
| --- | --- | --- |
| Free plan | $0 | BYOK and pay-as-you-go credits; a 5-request lifetime trial on free models, which then need Go |
| Go | $2/mo | $4 monthly credit for paid models |
| Pro | $10/mo | + $20 credit, higher rolling rate limits |
| Pro+ | $45/mo | + $100 credit, highest rolling rate limits |
| Max | $100/mo | + $300 credit, highest rolling rate limits |

## Already have a free provider account? Route it instead of paying twice

Students often already hold free-tier keys from a class assignment or a personal project. Google AI Studio's Gemini free tier is a common one. BYOK lets you attach that key and route through it at $0 markup, so a key you're not fully using pays for itself instead of sitting idle.

Go further and donate the spare capacity on that key to the shared pool: every request the pool serves through it adds up to 8% of the request's cost to a pending balance you can claim as credits, and donating one working key also makes the $2/mo Go plan free for as long as it stays active.

![AnyRouter free models tier shown in the dashboard](https://cdn.anyrouter.dev/screenshots/free-models-with-bg-2026-11.webp)

_The free tier and BYOK sit side by side in the same dashboard as paid usage._

## Build on the endpoint you'll still be using later

The point of using a standard, OpenAI-compatible endpoint from day one is that a class project, hackathon entry, or early side hustle doesn't need a rewrite if it turns into something real. The same base URL and key that served free-tier requests scale to a catalog of hundreds of models without touching the client code.

- Start with anyrouter/free on Go (free with one donated key), no daily limit.
- Attach a free-tier provider key you already have: /byok.
- Read the endpoint reference before you build: /docs.

- [Quickstart](https://anyrouter.dev/docs/getting-started/quickstart): your first request in two minutes.
- [All free models](https://anyrouter.dev/free): the full live list.
- [Pricing](https://anyrouter.dev/pricing): Go, Pro and what each plan adds.
- [The Pool](https://anyrouter.dev/pool): donate one key and make Go free.
- [The anyr CLI](https://anyrouter.dev/docs/cli): launchers for Claude Code, Codex and OpenCode.

A free LLM API that doesn't need a rewrite when your project grows.

[Set it up free](https://anyrouter.dev/dashboard)
