---
title: What Is a Token? How AI Reads Words | Large Programs
description: Tokens are the small pieces of text that language models read and write. Learn how a sentence is chopped up, with simple examples.
canonical: https://www.largeprograms.com/what-is-a-token/
---

[Home](/) / [How LLMs Work](/category/how-llms-work/)

How LLMs Work

# What Is a Token? How AI Reads Words

Tokens are the small pieces of text that language models read and write. Learn how a sentence is chopped up, with simple examples.

26 November 2026 · 3 min read

When you read, you see letters and words. An AI language model sees **tokens**.

![A sentence cut into tokens, each with a number. The split and the numbers are made-up examples, not output from a real tokenizer.](/img/tokens.svg)

*A sentence cut into tokens, each with a number. The split and the numbers are made-up examples, not output from a real tokenizer.*

A token is a small chunk of text. It might be a whole short word like "cat", part of a long word like "un" + "believ" + "able", or even a single punctuation mark.

## Try it by hand

Take the sentence: *Dogs love playing outside.*

One possible split is: `Dogs` `love` `playing` `outside` `.` Another model might split "playing" into `play` and `ing`. Different models cut text in different ways.

## Why not just use letters or words?

- Using only letters makes every sentence very long.
- Using only whole words fails when a new word appears.
- Tokens are a middle path: common words stay whole, rare words are built from parts. A 2015 paper on machine translation (Sennrich and colleagues) showed this idea works: encoding rare and unknown words as sequences of subword units, using a method called byte pair encoding, improved English to German and English to Russian translation by up to 1.1 and 1.3 BLEU points compared with a dictionary fallback.

## Tokens become numbers

Each token has a number, like a locker number. The model works with those numbers, not the letters.

## Why you hear about tokens

Companies often count usage and limits in tokens. A model can also only look at so many tokens at once. That limit is called its **context window**. Read more in [what a context window is](/what-is-a-context-window/).

## Quick activity

Write a sentence and cut it into pieces any way you like. Swap with a friend. Notice that you each made different pieces but could still rebuild the sentence. That is the idea behind tokens.

## A worked example

Take the word **"unbelievable"**. A model might cut it as `un` + `believ` + `able`. That helps in two ways. The model has seen `un` and `able` in thousands of other words, so it can guess the meaning even if it never met "unbelievable" in exactly that form. And it keeps its list of pieces small enough to work with.

Different models use different token lists, so the same sentence can be cut differently by two different AIs. The pictures in this guide are examples to show the idea, not the real cuts of any particular model.

## Why tokens explain odd AI behaviour

- It may be one reason a model can [struggle to count letters](/why-ai-is-bad-at-counting-letters/) in a word. Researchers are still studying the causes.
- It is why long documents can fill up a [context window](/what-is-a-context-window/): the limit is counted in tokens, not pages.
- It is why some languages use more tokens for the same text than others. A 2023 study from the University of Oxford (Petrov and colleagues) found that the same text translated into different languages can differ in token count by up to 15 times. For ChatGPT and GPT-4 at the time of that study, the cost to process German or Italian was about 50% higher than English, and for a few languages such as Dzongkha, Odia, Santali and Shan it was more than 12 times higher, because the services charged per token. Prices and tokenizers have changed since, so these numbers describe that study, not today.

## Practice

1. Choose a sentence of ten words.
2. Cut it into pieces any way you like, making rare words into two or three parts.
3. Give each piece a number in order of first appearance.
4. Swap lists with a friend and rebuild each other's sentences from the numbers.

Notice how the same sentence can have several valid cuts but only one correct rebuild. That is exactly why a model needs to keep the numbers in order.

## Sources

- [https://arxiv.org/abs/1508.07909](https://arxiv.org/abs/1508.07909)
- [https://arxiv.org/abs/2305.15425](https://arxiv.org/abs/2305.15425)
- [https://en.wikipedia.org/wiki/Large_language_model](https://en.wikipedia.org/wiki/Large_language_model)

[Read this page as Markdown (.md)](/what-is-a-token.md)

## Keep reading

[![](/img/hero/art-ai-art-and-music-basics.svg)](/ai-art-and-music-basics/)

How LLMs Work

### [How AI Makes Music: A Beginner's Look](/ai-art-and-music-basics/)

Models can generate melodies and songs by learning patterns in sound. What that means for musicians.

[![](/img/hero/art-backpropagation-how-neural-networks-learn-from-mistakes.svg)](/backpropagation-how-neural-networks-learn-from-mistakes/)

How LLMs Work

### [Backpropagation: How a Network Learns From Its Mistakes](/backpropagation-how-neural-networks-learn-from-mistakes/)

Backpropagation is the method that works out how to adjust each weight in a neural network after it makes an error. A simple explanation with a team analogy.

[![](/img/hero/art-chain-of-thought-prompting-showing-your-working.svg)](/chain-of-thought-prompting-showing-your-working/)

How LLMs Work

### [Chain-of-Thought Prompting: Showing the Steps](/chain-of-thought-prompting-showing-your-working/)

Asking a language model to show intermediate steps can improve its answers to hard problems. What the research found and how it is like showing your working in maths.
