Last verified

Retrieval & data AI glossary

What are embeddings?

Embeddings are lists of numbers — vectors — that an embedding model produces from text or other data, placed so that items with similar meaning end up close together and can be compared mathematically.

At a glance

  • How it works: An embedding model reads a passage and returns a fixed-length vector; the distance between two vectors measures how related the passages are.
  • Why it matters: They are what makes semantic search, clustering, recommendation and the retrieval step of RAG work.
  • What it costs: Priced per input token only: OpenAI's text-embedding-3-small lists $0.02 per million tokens, with no output charge.
  • Related to: RAG, token, batch API, LLM.

What an embedding is

OpenAI's definition is compact: an embedding is a vector — a list — of floating-point numbers, and the distance between two vectors measures their relatedness; small distances suggest high relatedness. An embedding model is trained so that passages with similar meaning land near each other even when they share no words, which is what lets a search for cancel my plan find a help article titled ending a subscription.

Vectors have a fixed length set by the model. OpenAI's text-embedding-3-small returns 1,536 numbers by default and text-embedding-3-large 3,072, and both accept a dimensions parameter to return shorter vectors without losing their concept-representing properties — useful because storage and search cost scale with vector length. For comparing vectors, OpenAI recommends cosine similarity.

What embeddings are used for

  • Retrieval for RAG — find the passages closest to a question and put them in the prompt; see RAG.
  • Semantic search — rank documents by meaning rather than keyword overlap.
  • Clustering and deduplication — group similar tickets, reviews or records.
  • Classification and recommendation — compare items to labelled examples or to a user's history.

In every case the expensive step — reading the text with a model — happens once per item, and later comparisons are cheap arithmetic on stored vectors.

What embeddings cost

Embedding models bill only input: you pay for the tokens you send, and the vector you get back is free. OpenAI's guide notes that usage is priced per input token, with a maximum input of 8,192 tokens per item on its current models. Rates are a small fraction of a chat model's — the panel below lists the embedding models in our index and their current rates.

The real cost lies around the model. A corpus has to be embedded once and re-embedded whenever documents change — or entirely when you switch embedding models, since vectors from different models are not comparable. Vectors must be stored and searched, which a vector database prices by storage and queries rather than tokens. For a large one-off corpus, the batch API discounts embedding requests too: OpenAI's Batch API accepts the embeddings endpoint.

In our indexEmbedding models in our index

Embedding models 4 Baichuan, OpenAI, Tencent (Hunyuan)
Cheapest $0.02 text-embedding-3-small
Priciest $0.13 text-embedding-3-large
ModelVendorPer 1M input tokens
text-embedding-3-smallOpenAI$0.02
Baichuan Text EmbeddingBaichuan$0.0744
Hunyuan EmbeddingTencent (Hunyuan)$0.104
text-embedding-3-largeOpenAI$0.13

Counted at build from our price index: current embedding models with a published rate, read between 2026-07-11 and 2026-08-31. How we collect prices.

Frequently asked.

Short answers to the questions that come up next.

Q · 01 What is an embedding in simple terms? +
A list of numbers that represents the meaning of a piece of text, arranged so similar meanings have similar numbers. Comparing two lists tells you how related two texts are.
Q · 02 How much do embeddings cost? +
Embedding models charge per input token only, at rates far below chat models — see the panel on this page. The larger costs are usually storage, search and re-embedding when documents or models change.
Q · 03 Can I mix embeddings from different models? +
No. Vectors from different embedding models live in different spaces and cannot be compared; switching models means re-embedding the whole corpus.
Q · 04 How long is an embedding vector? +
It depends on the model: OpenAI's text-embedding-3-small returns 1,536 dimensions and text-embedding-3-large 3,072 by default, and both can return fewer through the dimensions parameter.

Sources · read on the date shown