Search
Implement document search in your docs
Fumadocs UI provides a good-looking search UI for your docs, the search functionality is instead provided and documented on Fumadocs Core.
See Document Search.
Search UI
Open with ⌘ K or Ctrl K.
Configurations
You can customize search UI from the Root Provider component in root layout.
When not specified, it uses the Default fetch
Search Client powered by Orama.
It is lazy loaded using next/dynamic
.
This allows a better initial loading performance.
Custom Links
Add custom link items to search dialog. They are shown as fallbacks when the query is empty.
Disable Search
To opt-out of document search, disable it from root provider.
Hot Keys
Customise the hot keys to trigger search dialog.
Tag Filter
Add UI to change filters. Make sure to configure Tag Filter on search server first.
Search Options
Pass options to the search client.
For example, using static
client:
Replace Search Dialog
You can replace the default Search Dialog with:
To pass it to the Root Provider, you need a wrapper with use client
directive.
Use it instead of your previous Root Provider
Other Solutions
To use other search solutions such as Algolia and ElasticSearch, you can replace the default dialog with your own.
Algolia
For the setup guide, see Integrate Algolia Search.
While generally we recommend building your own search with their client-side SDK, you can also plug the built-in dialog interface.
-
Replace
appId
,apiKey
andindexName
with your desired values. -
Replace the default search dialog with your new component.
Note
The built-in implementation doesn't use instant search (their official javascript client).
Tag Filter
Same as default search client, you can configure Tag Filter on the dialog.
Orama Cloud
For the setup guide, see Integrate Orama Cloud.
- Replace
endpoint
,apiKey
with your desired values. - Replace the default search dialog with your new component.
Community Integrations
A list of integrations maintained by community.
Built-in UI
If you want to use the built-in search dialog UI instead of building your own,
you may use the SearchDialog
component.
Unstable
It is an internal API, might break during iterations
Last updated on