Loading…

Full-Text Search Playground

This playground runs a real full-text search engine on a small set of documents. You write the documents as JSON, type a search query, and get ranked results back.

It shows why search engines work differently from a database LIKE query: they handle typos, match the start of words, and rank results by how well they match.

Things to try

  • Run the starter query "insulted coat" — it has a typo, but it still finds the insulated coat.
  • Search for only the first few letters of a word, like "keyb".
  • Add your own documents with new fields and search them.
  • Compare which document ranks first for different queries.

How it works

The playground uses MiniSearch, a real open-source search library that runs fully in your browser. It builds an inverted index from every text field in your documents (except id).

Searches use fuzzy matching (to allow small typos) and prefix matching (to match the start of a word), then score each document so the best match comes first.

Frequently asked questions

What is full-text search?

Full-text search looks for words inside text and ranks the results by relevance. Unlike an exact match, it can handle typos, partial words and many fields at once.

How is this different from SQL LIKE?

LIKE only checks whether a piece of text appears exactly. A search engine uses an inverted index, accepts small typos and ranks results, so the most useful match comes first.

Which fields are searched?

Every text field in your documents is indexed, except the id field.