{"schemaVersion":"1.0","record":{"label":"FlexSearch","description":"Configurable full-text search library with field indexes, workers and persistent storage adapters.","aliases":[],"kind":"software","website":"https://github.com/nextapps-de/flexsearch","overview":"FlexSearch is an open-source search library for browser and Node.js applications. It offers simple text indexes, structured document search and optional worker or persistent-storage configurations. Applications choose how to encode content, which fields to index and how to present results rather than receiving a complete hosted search service.","license":"Apache-2.0","lifecycle":"active","example":false,"features":[{"name":"Structured document search","status":"supported","detail":"Indexes selected fields with optional stored-document enrichment and result merging.","useCase":"Embedding indexed text search in browser and Node.js applications","platforms":["Web","JavaScript","TypeScript","Node.js"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/document-search.md","locator":"Descriptor, result shape, storage, count and sequential-data limitations","retrievedAt":"2026-10-07T23:41:28Z","kind":"vendor"}]},{"name":"Persistent index storage","status":"supported","detail":"Adapters include IndexedDB and server databases; initialization and commit timing require asynchronous handling.","useCase":"Embedding indexed text search in browser and Node.js applications","platforms":["Web","JavaScript","TypeScript","Node.js"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/persistent.md","locator":"Adapters, async commit and destructive clear/destroy operations","retrievedAt":"2026-10-07T23:41:21Z","kind":"vendor"}]},{"name":"Worker integration","status":"limited","detail":"Worker methods return promises; custom functions need external configuration and strict CSP may require non-bundled workers.","useCase":"Embedding indexed text search in browser and Node.js applications","platforms":["Web","JavaScript","TypeScript","Node.js"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/worker.md","locator":"Promise methods, custom configuration files and CSP","retrievedAt":"2026-10-07T23:41:39Z","kind":"vendor"}]},{"name":"Automatic migration tooling","status":"unsupported","detail":"The inspected persistent-index guide states that no migration tool is provided.","useCase":"Embedding indexed text search in browser and Node.js applications","platforms":["Web","JavaScript","TypeScript","Node.js"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/persistent.md","locator":"Adapters, async commit and destructive clear/destroy operations","retrievedAt":"2026-10-07T23:41:21Z","kind":"vendor"}]}],"alternatives":[],"slug":"flexsearch","draftAlternatives":[{"targetSlug":"fuse-js","status":"limited","detail":"Can replace local record search when field indexes and configurable storage fit better; matching, result shape and index formats differ.","useCase":"Embedding indexed text search in browser and Node.js applications","platforms":["Web","JavaScript","TypeScript","Node.js"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/document-search.md","locator":"Descriptor, result shape, storage, count and sequential-data limitations","retrievedAt":"2026-10-07T23:41:28Z","kind":"vendor"},{"url":"https://www.fusejs.io/getting-started.html","locator":"Collection-based fuzzy lookup","retrievedAt":"2026-10-07T23:41:02Z","kind":"vendor"}]}],"evidence":[{"url":"https://github.com/nextapps-de/flexsearch","locator":"Browser/Node library, worker and persistent index options","retrievedAt":"2026-10-07T23:40:39Z","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/document-search.md","locator":"Descriptor, result shape, storage, count and sequential-data limitations","retrievedAt":"2026-10-07T23:41:28Z","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/encoder.md","locator":"Default normalization, deduplication and alphanumeric filtering","retrievedAt":"2026-10-07T23:41:39Z","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/worker.md","locator":"Promise methods, custom configuration files and CSP","retrievedAt":"2026-10-07T23:41:39Z","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/persistent.md","locator":"Adapters, async commit and destructive clear/destroy operations","retrievedAt":"2026-10-07T23:41:21Z","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/LICENSE","locator":"Apache 2.0 terms","retrievedAt":"2026-10-07T23:41:11Z","kind":"vendor"},{"url":"https://www.fusejs.io/getting-started.html","locator":"Collection-based fuzzy lookup","retrievedAt":"2026-10-07T23:41:02Z","kind":"vendor"}],"document":{"version":1,"references":[{"url":"https://github.com/nextapps-de/flexsearch","locator":"Browser/Node library, worker and persistent index options","retrievedAt":"2026-10-07T23:40:39Z","id":"repo","title":"FlexSearch overview","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/document-search.md","locator":"Descriptor, result shape, storage, count and sequential-data limitations","retrievedAt":"2026-10-07T23:41:28Z","id":"document","title":"Document search","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/encoder.md","locator":"Default normalization, deduplication and alphanumeric filtering","retrievedAt":"2026-10-07T23:41:39Z","id":"encoder","title":"Encoder guide","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/worker.md","locator":"Promise methods, custom configuration files and CSP","retrievedAt":"2026-10-07T23:41:39Z","id":"worker","title":"Worker parallelism","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/doc/persistent.md","locator":"Adapters, async commit and destructive clear/destroy operations","retrievedAt":"2026-10-07T23:41:21Z","id":"persistent","title":"Persistent indexes","kind":"vendor"},{"url":"https://github.com/nextapps-de/flexsearch/blob/master/LICENSE","locator":"Apache 2.0 terms","retrievedAt":"2026-10-07T23:41:11Z","id":"license","title":"FlexSearch Apache license","kind":"vendor"},{"url":"https://www.fusejs.io/getting-started.html","locator":"Collection-based fuzzy lookup","retrievedAt":"2026-10-07T23:41:02Z","id":"fuse","title":"Fuse.js getting started","kind":"vendor"}],"overviewCitations":["repo","document"],"licenseCitations":["license"],"sections":[{"id":"documents","heading":"Fields, storage and result shape","paragraphs":[{"id":"documents-detail","content":[{"text":"A simple Index accepts ID/content pairs; a Document index adds selected fields and optional document storage. Default search results are grouped by field and contain IDs, while enrichment adds stored documents and merge combines fields by ID. The descriptor distinguishes searchable fields from fields retained only for display. The documentation limits a document's root shape and does not support its ID nested inside an array; such sequential structures need flattening before indexing."}],"citations":["document"]}]},{"id":"encoding","heading":"Encoding changes what can be found","paragraphs":[{"id":"encoding-detail","content":[{"text":"The default encoder normalizes characters, deduplicates repeated letters and retains alphanumeric content while filtering other characters. This can help matching, but it can also remove symbols that distinguish codes, usernames or technical terms. The encoder permits custom inclusion rules and provides different language-oriented configurations. Search behavior therefore depends on the chosen encoding pipeline, not only on the raw source strings."}],"citations":["encoder"]}]},{"id":"workers","heading":"Worker integration","paragraphs":[{"id":"workers-detail","content":[{"text":"Worker indexes use promise-returning methods. Document workers distribute work by fields. When a field configuration contains custom functions, the guide requires an external configuration module instead of assuming the functions can pass through a worker message. Bundled worker generation can conflict with strict Content Security Policy; documented alternatives include non-bundled modules or an explicit worker file. These deployment details should be verified before adopting a generated worker setup."}],"citations":["worker"]}]},{"id":"persistence","heading":"Persistent versus in-memory indexes","paragraphs":[{"id":"persistence-detail","content":[{"text":"Persistent adapters include IndexedDB for browsers and several server databases. The guide requires awaiting mounting before access and describes automatic asynchronous batch commits. An explicit awaited commit can establish completion of pending updates. Export/import remains available for in-memory indexes, so exporting an index and mounting a persistent adapter are different workflows. A UI update alone should not be treated as confirmation that an asynchronous storage operation has completed."}],"citations":["persistent"]}]},{"id":"maintenance","heading":"Migration and reset risks","paragraphs":[{"id":"maintenance-detail","content":[{"text":"The persistent-index guide states that no migration tool is currently provided. It warns that clear and destroy operate on database contents associated with the configured store name, including truncation or dropping tables. An application's migration plan must treat those operations as destructive rather than harmless cache refreshes, and isolate store names accordingly. No reset or migration was executed during this research."}],"citations":["persistent"]}]},{"id":"results","heading":"Pagination considerations","paragraphs":[{"id":"results-detail","content":[{"text":"Queries are limited by default, and the document guide says the complete result count cannot be pre-counted. A search interface that displays a definitive total or arbitrary numbered pages needs its own strategy rather than assuming the index provides a database-style count query. Query options and result grouping should be reflected explicitly in the interface."}],"citations":["document"]}]},{"id":"license","heading":"License and comparative scope","paragraphs":[{"id":"license-detail","content":[{"text":"FlexSearch is released under Apache License 2.0. It can be considered alongside "},{"text":"Fuse.js","targetSlug":"fuse-js"},{"text":" for application-level search, but replacing one requires revisiting field configuration, matching behavior and result handling. FlexSearch's documentation advertises substantial performance advantages; this article does not adopt those figures as an independently verified comparison. Licensing the library does not supply hosting, storage administration or a managed search endpoint."}],"citations":["license","repo","fuse"]}]}]},"id":"Q1089","revision":1137,"updatedAt":"2026-10-13T21:01:16Z","sourceUrl":"https://substitutefor.net/entities/Q1089?revision=1137"}}