In short
In AI, a token is a small chunk of text, roughly four characters or three quarters of an English word, that a language model reads and writes in. Models do not see whole words the way you do; they break text into tokens, and both the price you pay and the amount a model can handle at once are measured in tokens, not words. Understanding tokens is the key to controlling both the cost and the quality of anything you build with AI.
Why tokens, not words
Models process text as tokens because it lets them handle any language, code and odd spellings consistently. A short common word might be one token; a long or unusual word can be several. Code and non-English text usually cost more tokens than the same idea in plain English, which directly affects your bill.
Tokens and your bill
AI pricing is quoted per million tokens and split into input (what you send) and output (what the model writes back), with output usually several times more expensive. On a workflow that runs thousands of times, trimming a bloated prompt can cut your cost dramatically. Sending less but more relevant text is almost always the right move.
A different "token" in security
Watch out for a naming clash. In AI, a token is a chunk of text. In login and security, a "token" means something completely different: a secret string that proves who you are, like an access token. They share a word but are unrelated concepts, so read the context to know which one is meant.
Tokens and the context window
Tokens also explain a limit you will hit called the context window: the maximum number of tokens a model can consider at once, including your instructions, any files you paste, the conversation so far, and the answer it writes. When that fills up, the model effectively forgets the oldest parts. This is why long, sprawling chats start losing track of things you said earlier, and why starting a fresh conversation often gives better answers than piling onto an old one. The practical takeaway is the same as for cost: send less but more relevant text. Tokens are the single unit that ties together what a model can hold, how well it answers, and what you pay, so a rough feel for them makes you better at everything you build with AI.
