---
title: Menubar
description: A visually persistent menu common in desktop applications that provides quick access to a consistent set of commands.
base: base
component: true
links:
doc: https://base-ui.com/react/components/menubar
api: https://base-ui.com/react/components/menubar#api-reference
---
## Installation
Command
Manual
```bash
npx shadcn@latest add menubar
```
Install the following dependencies:
```bash
npm install @base-ui/react
```
Copy and paste the following code into your project.
Update the import paths to match your project setup.
## Usage
```tsx showLineNumbers
import {
Menubar,
MenubarContent,
MenubarGroup,
MenubarItem,
MenubarMenu,
MenubarSeparator,
MenubarShortcut,
MenubarTrigger,
} from "@/components/ui/menubar"
```
```tsx showLineNumbers
File
New Tab ⌘T
New Window
Share
Print
```
## Examples
### Checkbox
Use `MenubarCheckboxItem` for toggleable options.
### Radio
Use `MenubarRadioGroup` and `MenubarRadioItem` for single-select options.
### Submenu
Use `MenubarSub`, `MenubarSubTrigger`, and `MenubarSubContent` for nested menus.
### With Icons
## RTL
To enable RTL support in shadcn/ui, see the [RTL configuration guide](/docs/rtl).
## API Reference
See the [Base UI Menubar](https://base-ui.com/react/components/menubar#api-reference) documentation.