Skip to content
Mechna Academy
  • How does it decide?
DecisionSignalsLearningMistakesTry itCheck itOlder readersQuestionsSourcesRelated
How does it decide? / Search autocomplete

How does search autocomplete decide what to suggest?

Answer first

Search autocomplete decides which few searches to suggest while you are still typing. It finds searches that start with your letters, then gives each one a score using clues such as how often people search for it and how new it is. The highest scores appear first. Popular does not mean true or right for you.

In one line: A program in a search box that guesses the rest of your search from the first letters you type and shows a few suggestions.

Last reviewed: 25 October 2026 | 3 min read

What decision does it make?

Every time you type a letter, autocomplete picks a short list of whole searches you might mean. It does not finish the search for you. You choose a suggestion or keep typing.

DecisionPossible answers
Which searches should I suggest?A short, ranked list of searches that start with the letters typed so far.

What does it look at?

  • Your letters. Only searches that start with what you typed, or come close, are in the running.
  • Popularity. Searches that many people have typed before get a higher score.
  • Freshness. Some systems give recent searches a boost, so a search about a recent event can rank high.
  • Your past searches. Some systems use earlier searches as a clue, so a search you made before can be suggested again.

How does it learn the rule?

  1. Collect examples. The program keeps counts of the searches people type and which words tend to come after which.
  2. Find matches. When you type, it finds the searches that start with your letters.
  3. Score each one. Each clue adds to a score, and some clues count more than others.
  4. Show the top few. The highest scores are shown first. Some systems also learn from which suggestions people pick or skip.

Where can it go wrong?

  • Popular is not the same as true. If many people search for a wrong idea, it can still be suggested.
  • It guesses the wrong thing. You start a search about bees and it suggests something you never meant.
  • Recent can beat what you meant. A system that favors the newest searches can rank a recent event above the older one you were asking about.

Try it

Toy example with made-up scores: someone typed "how do b". Change how much the machine cares about each clue and watch which suggestion comes out on top.

Toy example: four suggestions with made-up scores from 0 to 10 for each clue.

ItemValuesScore at starting weights
how do bees make honeypopularity: 9; freshness: 2; your past searches: 029
how do birds flypopularity: 7; freshness: 1; your past searches: 527
how do boats floatpopularity: 4; freshness: 9; your past searches: 021
how do batteries workpopularity: 6; freshness: 4; your past searches: 022

Check it

What does search autocomplete decide?

Answer: Which searches to suggest as you type. It picks a short list of searches that start with your letters.

A suggestion is at the top. What does that tell you?

Answer: It got the highest score from the clues. Top means highest score, often because many people searched it. It does not mean true.

You turn "freshness" all the way up. What happens?

Answer: Newer searches move up the list. The more a clue counts, the more items that score high on it move up.

For older readers

Autocomplete is a ranking problem. A simple version ranks past searches that share your prefix by how often they were typed. Many systems also use a language model, which estimates how likely a sequence of words is from counts in training text, so they can complete searches nobody has typed before. The final score is a weighted mix of signals, like the sliders above.

Questions

It is trying to save you typing. It scores the searches that start with your letters and shows the highest ones.

Not always. A suggestion is a popular or likely search, not a checked fact. Look at the results and think about who wrote them.

You do not have to click it. Tell a grown-up, and keep typing your own words.

Sources

  1. MIT OpenCourseWare: Smoothed estimation and language modeling (lecture notes) (opens another website)
  2. University paper: query auto-completion and relevance scores (opens another website)
  3. Stanford CS229 notes: supervised learning and the LMS update rule (opens another website)

Related machines

  • How does autocorrect decide which word you meant?↗
  • How does a video app decide what to show you next?↗

On this page

What decision does it make?What does it look at?How does it learn the rule?Where can it go wrong?Try itCheck itFor older readersQuestionsSourcesRelated machines

Nothing you do on these pages is sent anywhere. There are no cookies and no ads.

Mechna Academy teaches how machines like this decide.

For grown-ups: privacy For grown-ups: how Mechna Academy works