How to Get a Free GitHub Models API Key (2026)

13 free models available — no credit card required. Get your GitHub Models API key →

Overview

GPT-4o, o3, Llama 4, DeepSeek-R1 — free for all GitHub users.

GitHub Models provides free API access to 45+ models from OpenAI (GPT-4.1, o3, o4-mini), Meta (Llama 4), Mistral, DeepSeek, and Cohere for GitHub account holders. Rate limits depend on the GitHub Copilot subscription tier (Free/Pro/Pro+/Business). Tokens per request are limited (8K in/4K out), making it best suited for prototyping rather than production workloads.

  • 45+ models including GPT-4.1 and o3
  • Free for all GitHub accounts
  • Includes Llama 4, DeepSeek-R1, Mistral
  • Base URL: models.inference.ai.azure.com

API Compatibility: OpenAI SDK-compatible (Chat Completions)

Quick Start Guide

  1. 1
    Sign in with GitHub account Every GitHub user gets free access.
  2. 2
    Go to github.com/marketplace/models
  3. 3
    Generate a personal access token with Models:read permission
  4. 4
    Pick a model GPT-4.1, o3, Llama 4, DeepSeek — 45+ models available.
  5. 5
    Configure OpenAI client Base URL: https://models.inference.ai.azure.com

All Free GitHub Models Models — Context Windows & Rate Limits

Model Context Max Output Modality Rate Limit Released Status
gpt-4.1 1.0M 32K text 10 RPM, 50 RPD Online Details
gpt-4.1-mini 1.0M 32K text 15 RPM, 150 RPD Online Details
gpt-4o 128K 16K text 10 RPM, 50 RPD Online Details
o3-mini 200K 100K text 10 RPM, 50 RPD Online Details
o4-mini 200K 100K text 10 RPM, 50 RPD Online Details
Llama-4-Scout-17B-16E 512K 4K text 15 RPM, 150 RPD Online Details
Llama-4-Maverick-17B-128E 256K 4K text 10 RPM, 50 RPD Online Details
Meta-Llama-3.3-70B 131K 4K text 15 RPM, 150 RPD Online Details
DeepSeek-R1 64K 8K text 15 RPM, 150 RPD Online Details
Mistral-Small-3.1 128K 4K text 15 RPM, 150 RPD Online Details
Phi-4 131K 0 text See provider page Online Details
Mistral Large (24.11) 131K 0 text See provider page Online Details
AI21 Jamba 1.5 Large 256K 0 text See provider page Online Details

Pricing & Limits

Credit Card Not required
Free Tier Permanently free
Context Range 64K – 1.0M
Total Models 13 free
Rate Limits 10 RPM, 50 RPD · 15 RPM, 150 RPD
API Compatibility OpenAI SDK-compatible (Chat Completions)

Use Cases

What GitHub Models's free models are best for, based on aggregated model capabilities:

Chat 12 models Reasoning 2 models Coding 1 model

Limitations & Caveats

  • Low per-request token limits (8K input / 4K output)
  • Rate limits tied to GitHub Copilot subscription tier
  • Not suitable for large-context or long-generation tasks
See our FAQ for common questions about free LLM APIs