Search
Learn how search works in Docstra and how to configure it.
Docstra comes with a fast, client-side search functionality out of the box, ensuring your users can find what they need instantly.
How it Works
Docstra uses Fuse.js, a lightweight fuzzy-search library, to provide high-quality search results.
- Indexing: During the build process, Docstra creates a search index of all your documentation pages, including titles, descriptions, and content.
- Client-side Search: When a user types in the search box, the search is performed entirely on the client side, making it extremely fast and responsive.
Features
- Fuzzy Matching: Finds results even if there are small typos.
- Keyboard Shortcuts: Open the search dialog with
Cmd+KorCtrl+K. - Pre-computed Results: Matches are ranked by relevance based on title, description, and content density.
Configuration
Search is enabled by default. You can control which fields are prioritized by adjusting your configuration (Advanced).
The search box is integrated into the DocstraHeader component, so as long as you use the standard layout, search will be available to your users.
tsx
Customizing Search
While the default search is powerful enough for most sites, you can customize the search behavior by passing options to the DocstraProvider.
In future versions, we plan to add support for external search providers like Algolia for very large documentation sets.
How is this guide?
Last updated on March 30, 2026