Description
kbar is a React component library that adds a command palette, the cmd+k (or ctrl+k) search menu, to a website or web app. Developers wrap their app in a single provider, define actions, and render the provided UI components, or build their own on the same simple data structure. Each action says what happens when a user selects it. Actions can be bound to keyboard shortcuts, for example pressing t to open a page, and can be nested so that backspace returns to the previous level. The README says the library is built for speed, with tens of thousands of actions and a virtualized results list, and it supports undo and redo through history management. Built-in screen reader support is included, and the animations and components are customizable. The useMatches hook returns a flat list of matching results grouped by section for the current query. kbar is a library rather than an end-user app, so it is for front-end developers adding a command menu to their own product. The source is public on GitHub, where the README invites sites to add themselves to a list of users.…
Highlights
- Cmd+k command palette for React apps
- Keyboard shortcuts and nested actions
- Undo and redo through action history
- Virtualized results list for large action sets
- Screen reader support and custom components
Ratings & Reviews
No ratings yet
Be the first to rate kbar.
People also visit

react-command-palette
WAI-ARIA compliant React command palette like the one in Atom

react-hotkeys
A declarative library for handling hotkeys and focus within a React application
data-command
Component for building dynamic command palettes with API-powered data

@cloudflare/kumo
Kumo - Cloudflare's component library for building modern web applications
kbar FAQ
What is kbar?
A React library that adds a cmd+k style command palette to a website, so users can search and run actions from the keyboard.
How do I add it to my site?
Install the kbar package, wrap your app in its provider, define your actions, then render the provided search and results components.
Is it free?
Yes. The source code is public on GitHub.
Can I change how it looks?
Yes. The README says the animations and components are fully customizable, and you can build your own components on its data structure.
Does it work with many commands?
The README says performance is a first-class priority and tens of thousands of actions are fine, because results are rendered as a virtualized list.
Does it support keyboard shortcuts?
Yes. Actions can be registered to keystrokes, and results can be navigated with control+n and control+p.
What are the best kbar alternatives?
Popular alternatives to kbar include react-command-palette, cmdk and react-hotkeys. See all kbar alternatives










