Claude vs GPT vs Gemini: model and API comparison

There is no universal winner: choose by tool and workload. Compare actual token rates from the live catalog, then follow the setup guide for Claude Code, Codex, Gemini CLI, CodeBuddy or WorkBuddy.

Representative models and monthly cost

The table uses the default model for each channel and the same workload: 20M input and 2M output tokens per month. Model IDs and prices come from the live catalog.

ChannelModelList price / monthCode By AI / monthSaving
Claude Codeclaude-sonnet-5$60.00$8.0087%
Codexgpt-5.6-terra$80.00$10.6787%
Geminigemini-3.8-flash$22.50$2.2590%

Which family should you choose?

Choose Claude for Claude Code

Use this family when your workflow is Claude Code or the Anthropic Messages API. The CLI, model IDs and setup are built around that protocol.

Claude Code setup guide

Choose GPT for Codex

Use this family for Codex and OpenAI Responses-compatible tools. Configure the model provider and the exact GPT model ID from the table.

Codex setup guide

Choose Gemini for Gemini CLI

Use this family for Gemini CLI and Gemini-compatible applications. Set the Gemini endpoint and key, then select the Gemini model ID you need.

Gemini setup guide

Protocols and endpoints

The gateway exposes four protocols. Protocols are not interchangeable: choose the endpoint your tool supports, then use a model ID accepted by that endpoint.

ProtocolEndpointModel familiesTypical tools
Anthropic Messageshttps://www.codebyai.net/api/agent/v1/messagesClaude onlyClaude Code and Anthropic SDK clients
OpenAI Responseshttps://www.codebyai.net/api/agent/v1/responsesGPT and ClaudeCodex and OpenAI Responses clients
OpenAI Chat Completionshttps://www.codebyai.net/api/agent/v1/chat/completionsGPT and ClaudeCodeBuddy, WorkBuddy and OpenAI-compatible clients
Gemini generateContenthttps://www.codebyai.net/api/agent/v1beta/models/{model}:generateContentGemini onlyGemini CLI and Gemini-compatible applications

Gemini does not use the Chat Completions endpoint. CodeBuddy and WorkBuddy tutorials on this page cover Claude and GPT only.

Use Claude and GPT in CodeBuddy and WorkBuddy

CodeBuddy and WorkBuddy accept OpenAI-compatible Chat Completions for Claude and GPT. Use the full endpoint https://www.codebyai.net/api/agent/v1/chat/completions, then add separate entries for a Claude model and a GPT model. Gemini uses its own generateContent endpoint, not this Chat Completions path.

Claude Code models: full price comparison

ModelList priceYou pay
claude-haiku-4-5-20251001$1.00 / $5.00$0.13 / $0.67
claude-sonnet-5Default$2.00 / $10.00$0.27 / $1.33
claude-sonnet-5-5$2.00 / $10.00$0.27 / $1.33
claude-sonnet-4-6$3.00 / $15.00$0.40 / $2.00
claude-opus-5-5$4.00 / $20.00$0.53 / $2.67
claude-opus-4-6$5.00 / $25.00$0.67 / $3.33
claude-opus-4-7$5.00 / $25.00$0.67 / $3.33
claude-opus-4-8$5.00 / $25.00$0.67 / $3.33
claude-opus-5$5.00 / $25.00$0.67 / $3.33
claude-fable-5$10.00 / $50.00$2.00 / $10.00
claude-fable-5-1$10.00 / $50.00$2.00 / $10.00

per 1M tokens (input / output)

Codex models: full price comparison

ModelList priceYou pay
gpt-6.1-terra$1.00 / $5.00$0.13 / $0.67
gpt-6-sol$2.00 / $10.00$0.27 / $1.33
gpt-6.1-sol$2.00 / $10.00$0.27 / $1.33
gpt-5.6-terraDefault$2.50 / $15.00$0.33 / $2.00
gpt-5.6-sol$4.00 / $20.00$0.53 / $2.67
gpt-6-astra$10.00 / $50.00$1.33 / $6.67

per 1M tokens (input / output)

Gemini models: full price comparison

ModelList priceYou pay
gemini-3.8-flashDefault$0.75 / $3.75$0.08 / $0.38
gemini-3.7-flash$1.00 / $3.00$0.10 / $0.30
gemini-3.1-pro-preview$2.00 / $12.00$0.20 / $1.20
gemini-4-argon$2.00 / $10.00$0.20 / $1.00

per 1M tokens (input / output)

FAQ

Is there a single best model?
No. Choose by tool and workload. Claude Code fits Anthropic's CLI, Codex fits OpenAI's tools, and Gemini fits Google's CLI. For price, compare the exact model ID rather than the family name.
Can I use Claude, GPT and Gemini with one key?
Yes. One Code By AI key works across all three channels. You still configure each tool with its own protocol and model ID.
Which model should I use in CodeBuddy or WorkBuddy?
Use Claude or GPT, and add them as separate custom models. The Chat Completions endpoint accepts GPT and Claude IDs; Gemini IDs use a different generateContent endpoint and are not part of these two custom-model tutorials.