CodeBase Coders
Free tool · No sign-up

AI API Cost Calculator

Estimate what an AI feature will cost to run. Enter how many requests you expect and how long they are, and compare Claude, GPT and Gemini models side by side.

Quick start

Rough guide: 1,000 tokens is about 750 English words. Input includes your instructions, chat history and any documents you send.

Requests per month: Based on 30 days.

Standard list prices in USD per 1 million tokens, checked on 21 Oct 2026. Prices change often, so confirm on the official pages: Anthropic, OpenAI, Google. Taxes, free tiers and volume discounts are not included. Every price above is editable.

How AI API pricing works

AI providers charge per token, a small chunk of text. You pay for the tokens you send (input: your instructions, the conversation so far and any documents) and the tokens the model writes back (output). Output tokens usually cost several times more than input tokens.

The formula is simple: (input tokens × input price + output tokens × output price) ÷ 1,000,000, multiplied by the number of requests.

Ways to lower your AI bill

  • Pick the smallest model that does the job well. Classification and simple replies rarely need the largest model. Test a few on your real data.
  • Keep prompts short. In chatbots, the whole conversation is sent again with every message, so long chats get expensive. Summarise or trim old messages.
  • Use prompt caching and batch processing where your provider offers them. Both can cut costs a lot for repeated instructions or work that doesn't need an instant answer.
  • Cap the output length so the model doesn't write more than you need.

More free tools

Planning an AI feature?

We help businesses pick the right model, keep running costs in check and build AI chatbots, agents and integrations.

Call Us WhatsApp

Leaving Already?

Before you go, get a free, no-obligation estimate for your project.

Free consultation & estimate
An itemised estimate and timeline before any development starts.
You own the source code
Code, designs and accounts are yours once the project is paid for.
NDA before you share details
Your idea stays confidential from the first conversation.

Share Your Requirements to help our experts understand your business objectives and create your customized plan.

In just 2 mins you will get a response
Your idea is 100% protected by our Non Disclosure Agreement

Protected by reCAPTCHA. Google's Privacy Policy and Terms of Service apply.

TRUSTED BY GLOBAL BRANDS
ConverseIQ Logo Modarch India Logo Ramyug Logo Media Dekho Logo