On June 15, 2026, Anthropic retired flat-rate agent access and replaced it with a metered credit pool that charged for every tool call. The change arrived with a short changelog entry and a long wave of confused posts from developers. Millions of people who use free AI tools every day suddenly had a reason to care about tokens, context windows, and inference costs. This explainer covers how the technology actually works, and why the billing shifted in June 2026.

How does AI work? At the simplest level, a model is a very large statistical machine that predicts the next piece of text. It learned that skill by reading an enormous pile of documents. It then repeats the prediction billions of times, one small chunk at a time, until a paragraph appears on your screen. Every free tier you use, from ChatGPT to Gemini to Claude, is a business built on top of that loop. The caps on free API tiers exist because each repetition costs real money on real hardware.

OpenAI, Google, Anthropic, and Meta spent years giving this technology away to build habits. The OpenAI pricing history shows the strategy clearly: rates fell, free tiers widened, and usage soared past every internal forecast. Then the bill arrived. Google tightened Gemini free API access in June 2026, GitHub moved Copilot to usage-based billing, and Anthropic started charging for agent loops. The price war that benefited consumers also made the meter visible to everyone.

This guide walks through the full pipeline in eight steps, from raw training data to the invoice you get at the end of the month. It is written for people who want to understand what they are paying for, not for engineers who plan to train a model from scratch. Each step ties one technical detail to something you can actually see on a live pricing page in 2026.

What You’ll Need

  • A free account on at least one AI chat product such as ChatGPT, Gemini, or Claude
  • Access to a vendor pricing page so you can compare token rates
  • Optional: a tokenizer tool on Hugging Face to see how text splits into tokens
  • Optional: a laptop with 16GB of memory if you want to try a local open-weight model

How Do You How AI Works?

  1. Start with the training run, because it sets the price floor.

Every large language model begins as a pile of text. Companies collect books, websites, code repositories, and licensed archives, then clean the mess. A frontier training set in 2026 runs into the tens of trillions of tokens. The model reads that pile thousands of times over weeks or months on clusters of specialized chips.

That process is called pretraining, and nobody supervises it directly. The model sees a sequence of tokens and guesses the next one. When it guesses wrong, it nudges its internal numbers in the right direction. Do that a few trillion times and the model starts producing grammar, facts, and reasoning patterns that look deliberate. The run itself is expensive. Published estimates for a frontier model in 2026 land between 50 million and 2 billion dollars, depending on the lab and the size of the model.

This is the first thing to understand about free AI. Training is a sunk cost once the run finishes. Serving the model is the recurring cost that never stops. That split explains why vendors can hand out free chats while charging heavily for API use. It also explains the price cuts of 2026. Google slashed Gemini API rates in May, and OpenAI signaled it would match as competition squeezed margins across the industry.

If you remember one ratio from this step, remember this one. Training a model might consume a hundred times more compute than answering a single question, but you only train once. Inference runs forever, on every request, for every user. Every free-tier decision made in 2026 traces back to that arithmetic.

  1. Learn how tokenization turns your words into billable units.

Models do not read words. They read tokens, which are chunks of characters. A tokenizer splits text into pieces that average about four characters in English. The word cat is one token. The word tokenization is two or three, depending on the vocabulary. A thousand tokens is roughly 750 English words.

Pricing pages quote rates per million tokens, split into input and output. In 2026, small models ran near 10 to 30 cents per million input tokens, while flagship reasoning models sat between 3 and 15 dollars. That spread is why the same task costs wildly different amounts depending on which model you pick. It is also why vendors push you toward cheaper models for routine work.

The tokenizer explains a strange fact about AI costs. Two prompts that look identical to a human can differ by 30 percent in price because of punctuation, code blocks, or non-English text. Developers noticed, and some started gaming output length to hit internal usage targets. That behavior, nicknamed tokenmaxxing, backfired badly at several large companies in 2026 when finance teams audited the bills.

You can see this for yourself in five minutes. Paste a paragraph into a tokenizer tool and compare the token count to the word count. Then estimate what that paragraph would cost at 5 dollars per million tokens. The number will be tiny. Now imagine a product with 200,000 daily users doing the same thing.

Close-up of a circuit board with microchips and glowing connections
Photo via Pexels
  1. Watch a transformer predict one token at a time.

Once text becomes tokens, the model converts each one into a long list of numbers called a vector. Those vectors pass through dozens of stacked layers in a transformer network. Each layer mixes information between tokens using a mechanism called attention. Attention is how the model links the word it back to the noun it refers to forty tokens earlier.

After the final layer, the model produces a probability score for every token in its vocabulary. A 2026 vocabulary runs between 100,000 and 256,000 entries. The model picks one, appends it to the sequence, and runs the whole thing again. A 500-word answer takes roughly 700 passes through the network, and each pass touches billions of parameters.

That loop is why output costs more than input. Input tokens can be processed in parallel because the model already has them. Output tokens come out one at a time, and each one depends on the last. Vendors typically charge three to five times more for output, and the split is visible on almost every pricing page. Cheaper open-weight models like Gemma 4 follow the same architecture and the same cost curve.

The context window is the maximum number of tokens the model can hold in view. By 2026, Gemini and Claude pushed theirs to a million tokens or more, which allows entire codebases in one request. A bigger window means more attention math per call. That is one reason long-document analysis costs more than a short chat, even when the output is the same length.

  1. Follow inference from your prompt to the response.

When you press send, your app fires an HTTPS request to an inference server. The provider routes it to a machine with the right model already loaded in memory. Large models need multiple GPUs, often eight or more, just to hold the weights. The model does not load from disk per request. It sits in memory, waiting.

Providers batch requests to cut costs. Many users share the same GPU pass, which lowers the cost per request and improves throughput. Latency rises when the queue grows. Free tiers sit at the back of that queue by design, which is why a paid plan sometimes feels twice as fast on identical hardware. The speed difference is scheduling, not magic.

Rate limits come in two flavors: requests per minute and tokens per minute. Google’s Gemini free API tier tightened in June 2026, with requests capped well below paid tiers and Pro-class models moved entirely behind the paywall. Those caps exist because a single runaway script can consume a shared GPU for hours without paying for it.

Streaming changed how all of this feels to users. The server sends tokens as they generate, so text appears word by word instead of arriving in one block. The billing engine still counts every token, streamed or not. A streamed answer and a buffered answer cost exactly the same amount.

  1. Understand post-training and why flagship models cost more.

A pretrained model is a raw next-token predictor. Ask it to complete a sentence and it will happily write a phishing email. Post-training fixes that behavior. Labs first run supervised fine-tuning on curated examples of good answers, then move to reinforcement learning from human feedback, usually shortened to RLHF.

RLHF uses human raters or AI judges to score pairs of answers. The model learns which style wins and adjusts accordingly. This stage is far smaller than pretraining, but it is not free. It requires labeled data, repeated evaluation runs, and human review at scale. Labs also run red-team testing to find failure modes before release, which adds more cost on top.

Alignment does not stop at training. Most providers add guardrails at inference time too. Safety classifiers screen the prompt and the output. Some run a second model to check the first one. That is extra compute on every single request, and it is baked into the posted price per million tokens whether you notice it or not.

Free tiers usually default to smaller, cheaper, more filtered models. Google moved Pro-class Gemini access to paid plans in June 2026. Claude’s free tier now resets on a five-hour window and runs on a lighter model than the paid plans. None of that is arbitrary. It is the post-training bill being passed along.

  1. See why agents drained free tiers so fast.

An agent is a model placed inside a loop. It reads a goal, decides on a tool call, runs the tool, reads the result, and decides again. Every turn resends the conversation so far, because the model has no memory beyond its context window. That means the prompt grows with each step, and the cost grows with it.

A single agent task can consume 50,000 to 500,000 tokens. Multiply that by a few hundred runs per day and a 20 dollar monthly plan disappears before lunch. That is the agentic billing crisis in one sentence. The technology worked fine. The pricing model attached to it did not.

Anthropic’s June 15 credit pool was a direct answer to that problem. Instead of unlimited agent access on a flat plan, users now draw from a metered balance that tracks every tool call. Google and GitHub moved in the same direction. GitHub Copilot shifted to usage-based billing in June 2026, and developers who ran long autonomous sessions saw their costs jump overnight.

The practical lesson is simple. Agent work is token work, and token work is metered. If a free plan advertises agents, read the credit cap before you build anything on it. A generous-looking allowance can vanish in a single afternoon of looping tasks, and the overage charge lands on your card.

  1. Read the free-tier fine print before you rely on it.

Free AI plans in 2026 differ on five things: model access, message caps, reset windows, data usage, and feature gates. The headline number is the least useful part of the page, mostly because it is the easiest one to advertise and the easiest one to misread.

Reset windows matter more than totals. Claude’s free tier resets every five hours, so a heavy morning does not lock you out for the rest of the day. Some Gemini tiers reset daily at midnight Pacific. A limit that looks generous at breakfast can be gone by lunch, and the reset clock is often buried three clicks deep in a help article.

Data terms are the hidden price. Many free tiers reserve the right to train on your conversations. Paid plans usually opt you out by default. If you paste client work, source code, or medical details into a free chat, you may be handing over training data along with the question. Read the policy before the first prompt, not after the tenth.

Model access is the other quiet downgrade. Vendors keep flagship models on paid plans and route free users to smaller versions with shorter context windows. That is not a bug. It is the pricing model working as designed. Free tier limits got tougher across most major providers in June 2026, and the pattern is unlikely to reverse while inference demand keeps climbing.

Rows of server racks in a data center lit by blue indicator lights
Photo via Pexels
  1. Run an open-weight model yourself and watch the whole pipeline.

Open-weight models let you run the entire pipeline on hardware you own. Meta, Mistral, Qwen, DeepSeek, and Google all released weights under permissive licenses by 2026. Llama 4 Scout, Mistral Small 4, and Gemma 4 all run on a single consumer GPU once the weights are compressed. Hugging Face hosts most of them along with benchmark cards and license terms, so start at Hugging Face before you download anything.

The tool most people begin with is llama.cpp, which quantizes weights down to 4-bit precision and runs on plain CPUs or Apple silicon. The project’s release notes on GitHub track performance gains every few weeks. A 7 billion parameter model at 4-bit needs about 5 gigabytes of memory. A 70 billion parameter model needs roughly 40 gigabytes, which puts it out of reach for most laptops.

The tradeoff is honest and worth stating plainly. Local inference is slower, and the models are weaker than hosted flagships on hard reasoning tasks. But the marginal cost per token is zero after you buy the hardware. If you generate millions of tokens a month, local wins on price within weeks. If you send twenty prompts a day, it never will. The best free AI models of 2026 covers which open weights are worth the disk space.

Running a model yourself is the fastest way to internalize everything above. You will watch tokens stream out slowly, see memory usage spike with context length, and understand exactly why the hosted version charges what it does. Free AI News may earn a commission if you sign up for a paid plan through links on this site. This does not affect our reporting.

Red Flags & Warnings

  • 🚨 Never trust a free tier’s headline number without checking the reset window. A 40-message limit that resets every five hours is a completely different product from a 40-message daily cap.
  • 🚨 Agent loops can spend a month of credits in an afternoon. Cap your tool calls and set a hard spending limit before you connect any agent to a paid key.
  • 🚨 Free plans often train on your prompts. Do not paste client work, source code, contracts, or personal records into a free chat until you have read the data policy.
  • 🚨 Local models are only cheaper if you already own the hardware. A new GPU can cost more than two years of API credits at moderate usage.
  • 🚨 Price cuts announced in a blog post do not always apply to your plan or your region. Check the live pricing page and your actual invoice before assuming the change reached you.

Frequently Asked Questions

How does AI work in simple terms?

A language model is a statistical machine that predicts the next small chunk of text, called a token. It learned that skill by reading trillions of words and adjusting billions of internal numbers until its guesses got good. When you send a prompt, the model repeats the prediction loop until it decides to stop, and the result reads like an answer.

Why do AI companies charge by the token?

Every token you send or receive triggers real GPU work on a server the vendor has to pay for. Input tokens can be processed in parallel, but output tokens generate one at a time, so most vendors charge three to five times more for output. Token pricing is simply the unit that maps cleanest onto the underlying compute cost.

Do free AI tools train on my conversations?

Many do, unless you opt out or pay for a plan that excludes training. Free tiers often reserve the right to use chat data for model improvement, and the terms vary by provider and by region. Read the data policy before you paste client work, code, or personal documents into a free chat window.

What is a context window and why does it matter?

A context window is the maximum number of tokens a model can consider at once, including your prompt, any attached files, and its own reply. Flagship models in 2026 pushed past one million tokens, which allows whole codebases or long reports in a single request. Bigger windows cost more because attention math scales with the number of tokens in view.

Why did Anthropic change agent billing in June 2026?

Agent loops resend the whole conversation on every step, so a single task can burn hundreds of thousands of tokens. Flat-rate plans could not absorb that usage, and Anthropic replaced unlimited agent access with a metered credit pool on June 15, 2026. Google and GitHub made comparable moves around the same time.

Can I run an AI model on my own computer for free?

Yes, if your hardware can hold the weights. Open-weight models like Gemma 4, Mistral Small 4, and Llama 4 Scout run on consumer GPUs or Macs with 16GB of memory when compressed to 4-bit. Local inference has no per-token cost, but it is slower and generally weaker than hosted flagship models.

What Should You Remember?

  • Tokens are the unit of AI: every chat message, code completion, and agent step is billed in tokens, not in seconds or clicks.
  • Training is a sunk cost: frontier training runs cost tens of millions to billions of dollars, but serving the model is what generates the recurring bill.
  • Output costs more than input: generated tokens are produced one at a time, so vendors charge roughly three to five times more for them.
  • Agents broke flat-rate plans: looping tool calls multiplied token use, and Anthropic replaced flat agent access with a credit pool on June 15, 2026.
  • Reset windows beat headline limits: a free tier that resets every five hours behaves very differently from one that resets daily at midnight.
  • Open weights remove the meter: local 4-bit models cost nothing per token after hardware, and they run entirely on your machine.
  • Data terms are part of the price: many free tiers train on your conversations, which is a cost that never appears on a pricing page.

Free AI News is an independent editorial publication. Information about AI pricing, free-tier limits, and features changes frequently and may become outdated. Always verify current details through the vendor’s official pages. Affiliate links may earn a commission at no cost to you, and never affect our reporting.