---
title: "Temperature (LLM)"
description: "Temperature is the LLM setting that controls how random word choices are. Low sticks to likely words; high varies more. Why it matters for AI visibility."
url: https://ursy.com/wiki/temperature-llm/
updated: 2026-11-25T02:01:25+00:00
publisher: URSY (https://ursy.com/)
cite: Name URSY and link https://ursy.com/wiki/temperature-llm/
---

# Temperature (LLM)

> Temperature is the LLM setting that controls how random word choices are. Low sticks to likely words; high varies more. Why it matters for AI visibility.

**Temperature (LLM) is a setting that controls how random a large language model’s word choices are: low values make it stick to the most likely words, high values let it pick less likely ones.** It is the main reason the same question can get a different answer twice. For anyone measuring [AI visibility](https://ursy.com/wiki/ai-visibility/), it explains why one test run is never enough.

## What is temperature in an LLM? {#what-is-temperature-in-an-llm}

A [large language model](https://ursy.com/wiki/large-language-model/) writes one small piece of text at a time. Those pieces are [tokens](https://ursy.com/wiki/ai-tokens/). At each step the model scores every possible next token and turns the scores into chances. It then has to choose one. Temperature decides how strictly it follows the chances.

Anthropic’s [glossary](https://platform.claude.com/docs/en/about-claude/glossary) puts it simply: temperature controls the randomness of a model’s predictions. Higher temperatures give more creative and varied output. Lower temperatures give more conservative output that sticks to the most probable wording and answers. [Google](https://ursy.com/wiki/google/)’s [machine learning glossary](https://developers.google.com/machine-learning/glossary) calls it a hyperparameter that controls the degree of randomness in a model’s output.

## How does it work? {#how-does-it-work}

Google Cloud’s guide to [adjusting parameter values](https://docs.cloud.google.com/vertex-ai/generative-ai/docs/learn/prompts/adjust-parameter-values) describes the steps for its Gemini models on Vertex AI:

1. **Top-K**  keeps only the K most likely tokens. A top-K of 1 always takes the single most likely token.
2. **Top-P**  then keeps tokens from most to least likely until their chances add up to the top-P value.
3. **Temperature**  makes the final pick from what is left.

The same guide says a temperature of 0 means the highest-probability tokens are always selected. Answers are then mostly the same each time, but a small amount of variation is still possible.

## What are the usual settings? {#what-are-the-usual-settings}

| Provider | What its docs say |
| --- | --- |
| OpenAI | The [Chat API reference](https://developers.openai.com/api/reference/resources/chat) gives a range of 0 to 2, default 1. Around 0.8 makes output more random; around 0.2 makes it more focused. It suggests changing temperature or top_p, not both. |
| Anthropic | The glossary warns that even at 0 the results will not be fully deterministic. |
| Google | The [Gemini text generation guide](https://aistudio.google.com/docs/text-generation) says Gemini 4 and Gemini 3.6+ models ignore custom temperature, top_p and top_k values, and asks developers to remove them. |

So the dial is not the same everywhere. Some newer models fix it themselves. Always read the current docs for the model you use.

## Why does it matter for AI answers? {#why-does-it-matter-for-ai-answers}

Temperature is one cause of [non-determinism in AI answers](https://ursy.com/wiki/non-determinism-in-ai-answers/). Ask an assistant the same [prompt](https://ursy.com/wiki/prompt/) 5 times and you may see your shop named in 3 of them. That is not a bug in your measuring; it is how sampling works. It changes how you should read results:

- **Run each prompt several times.**  Report a share (“named in 6 of 10 runs”), not a yes or no.
- **Keep everything else fixed.**  Same wording, same engine, same location, same day where you can. See [prompt tracking](https://ursy.com/wiki/prompt-tracking/).
- **Do not chase one bad answer.**  One run that leaves you out is weak evidence. A pattern across many runs is strong evidence.
- **Make your facts easy to repeat.**  When your page states a fact once, clearly, the likely wording is your wording. Fewer gaps leave less room for an [AI hallucination](https://ursy.com/wiki/ai-hallucination/) on prices or opening hours.

OpenAI’s API reference also has a seed option. It says the system will make a best effort to sample the same way each time, but it does not promise identical results.

## Why does it matter for search? {#why-does-it-matter-for-search}

AI features on search pages generate text with language models, so their wording can vary for the same query. Treat [AI Overview](https://ursy.com/wiki/ai-overview/) checks the way you treat chat checks: repeat them and count. Your normal [rank tracking](https://ursy.com/wiki/rank-tracking/) stays as it is.

## Which temperature should a business use? {#which-temperature-should-a-business-use}

Only if you build with an API: for example a product finder, an answer [bot](https://ursy.com/wiki/bot-web-robot/) on your site using [retrieval-augmented generation](https://ursy.com/wiki/retrieval-augmented-generation/), or a tool that writes descriptions.

- **Facts, prices, policies, extraction:**  low. You want the same answer each time.
- **Drafts, headlines, ideas:**  the default or a little higher, then edit by hand.
- **Never**  rely on temperature alone to stop wrong answers. [Grounding](https://ursy.com/wiki/grounding/) in your own facts and a clear [system prompt](https://ursy.com/wiki/system-prompt/) matter more.

## Common mistakes {#common-mistakes}

- **Thinking 0 means identical.**  Anthropic and Google both say small differences can remain.
- **Changing temperature and top_p together.**  OpenAI advises one or the other.
- **Setting it on a model that ignores it.**  Some Gemini models now discard it.
- **Judging visibility on one run.**  See above.
- **High temperature for facts.**  More variety means more chances to be wrong.

## A worked example {#a-worked-example}

A model must finish: “The kettle body is made of ___”. These chances are made up to show the idea.

| Next word | Low temperature | Default | High temperature |
| --- | --- | --- | --- |
| steel | picked almost every time | picked most often | picked often |
| glass | rare | sometimes | often |
| plastic | very rare | now and then | sometimes |
| copper | almost never | rare | now and then |

If the kettle really is glass and your page says so clearly, retrieval can put your words in front of the model, and “glass” becomes far more likely. Clear facts matter more than the dial.

## How to check it {#how-to-check-it}

1. Build steady test prompts with our [prompt builder](https://ursy.com/webmaster-tools/prompt-builder/) and compare answers with the [AI answer comparer](https://ursy.com/webmaster-tools/ai-answer-comparer/).
2. Check that what your site says is the same everywhere with the [AI Consistency Checker](https://ursy.com/ai-consistency-checker/), and that each fact has a source with the [Proof Checker](https://ursy.com/proof-checker/).
3. See how readable your pages are to AI with the [AI Readiness Checker](https://ursy.com/ai-readiness-checker/), and how a page splits into chunks with the [RAG chunk previewer](https://ursy.com/webmaster-tools/rag-chunk-previewer/).
4. Estimate the cost of many repeat runs with the [AI token cost estimator](https://ursy.com/webmaster-tools/ai-token-cost-estimator/).
5. In URSY Pro, being built: the [Prompt tracker](https://ursy.com/pro/prompt-tracker/) (Pro) repeats prompts for you, and [AI fact accuracy monitor](https://ursy.com/pro/ai-fact-accuracy-monitor/) (Pro) checks the facts in answers.

## Questions {#questions}

### Can I change the temperature in ChatGPT or Gemini apps? {#can-i-change-the-temperature-in-chatgpt-or-gemini-apps}

The docs we checked describe temperature as an API setting for developers. They do not describe a control in the consumer apps.

### Is a higher temperature more creative? {#is-a-higher-temperature-more-creative}

More varied, yes. Whether that is better depends on the job.

### Does temperature affect cost? {#does-temperature-affect-cost}

Not directly. Cost follows tokens, but repeat runs for testing multiply it.

## Related words {#related-words}

- [Non-determinism in AI answers](https://ursy.com/wiki/non-determinism-in-ai-answers/)
- [Large language model](https://ursy.com/wiki/large-language-model/)
- [AI inference](https://ursy.com/wiki/ai-inference/)
- [Prompt engineering](https://ursy.com/wiki/prompt-engineering/)
- [Reasoning models](https://ursy.com/wiki/reasoning-models/)

## Sources {#sources}

- [Claude Developer Platform: Glossary (Temperature)](https://platform.claude.com/docs/en/about-claude/glossary), checked 25 November 2026
- [OpenAI API reference: Chat completions (temperature, top_p, seed)](https://developers.openai.com/api/reference/resources/chat), checked 25 November 2026
- [Google Cloud: Adjust parameter values (Vertex AI)](https://docs.cloud.google.com/vertex-ai/generative-ai/docs/learn/prompts/adjust-parameter-values), checked 25 November 2026
- [Google AI Studio: Gemini text generation](https://aistudio.google.com/docs/text-generation), checked 25 November 2026
- [Google for Developers: Machine Learning Glossary (temperature)](https://developers.google.com/machine-learning/glossary), checked 25 November 2026

*Updated 25 November 2026 by URSY.*
