Free-models

OpenRouter free models

The Models API returns pricing information for every model, so you can identify free ones programmatically.

How free models appear

  • Pricing fields (prompt and completion) are strings in USD per token.

  • A value of "0" means that part is free.

  • Many free variants also have an ID ending in :free (e.g. deepseek/deepseek-r1:free).

Example: list only free models with curl + jq

curl -s "https://openrouter.ai/api/v1/models?limit=500" \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  | jq -r '.data[] | select(.pricing.prompt == "0" and .pricing.completion == "0") | .id'

This prints the IDs of models where both input and output are free.

Slightly more detail (ID + pricing)

curl -s "https://openrouter.ai/api/v1/models?limit=500" \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  | jq '.data[] | select(.pricing.prompt == "0" and .pricing.completion == "0") | {id, pricing}'

Bonus: Free Models Router

You can also just use the special router that automatically picks a free model:

# model: "openrouter/free"

Note: Free models usually have rate limits (e.g. requests per minute/day). Check the current limits in the OpenRouter docs or on the models page.

WWW::OpenRouter v0.0.3

WWW::OpenRouter provides access to the OpenRouter playground (https://openrouter.ai).

Authors

  • Anton Antonov

License

Artistic-2.0

Dependencies

HTTP::Tiny:ver<0.2.5+>JSON::Fast:ver<0.20+>

Test Dependencies

Provides

  • WWW::OpenRouter
  • WWW::OpenRouter::ChatCompletions
  • WWW::OpenRouter::Embeddings
  • WWW::OpenRouter::Models
  • WWW::OpenRouter::Request

The Camelia image is copyright 2009 by Larry Wall. "Raku" is trademark of the Yet Another Society. All rights reserved.

Built with Podlite — the markup and publishing tools behind this site.