---
title: "Select"
description: "A select menu for choosing from a list, with groups, separators, and custom items, styled to match the rest of the form. Built on Base UI."
plan: Free
docs: https://ui.edbn.me/docs/components/select
---

# Select

A select menu for choosing from a list, with groups, separators, and custom items, styled to match the rest of the form. Built on Base UI.

## Installation

```bash
npx shadcn@4.19.0 add https://ui.edbn.me/r/select.json
```

## Dependencies
- npm: @base-ui/react@^1.8.0, lucide-react@^1.33.0
- edbn: edbn-base

## Usage

```tsx examples/select-basic.tsx
"use client";
import {
  Select,
  SelectContent,
  SelectItem,
  SelectTrigger,
  SelectValue,
} from "@/components/ui/select";

export default function SelectBasicPreview() {
  return (
    <Select defaultValue="light" items={[{ value: "light", label: "Light" }, { value: "dark", label: "Dark" }, { value: "system", label: "System" }]}>
      <SelectTrigger aria-label="Theme">
        <SelectValue placeholder="Theme" />
      </SelectTrigger>
      <SelectContent aria-label="Themes">
        <SelectItem value="light">Light</SelectItem>
        <SelectItem value="dark">Dark</SelectItem>
        <SelectItem value="system">System</SelectItem>
      </SelectContent>
    </Select>
  );
}
```

## Files
- components/ui/select.tsx (217 lines)

## For agents
- Base theme, once per project: npx shadcn@4.19.0 add https://ui.edbn.me/r/edbn-base.json
- MCP server with search, items, examples and source: https://ui.edbn.me/mcp
- Every page and item: https://ui.edbn.me/llms.txt
