---
title: "Label"
description: "An accessible label for form controls that follows their disabled state. Pairs with Field, Input, Checkbox, and the other form components."
plan: Free
docs: https://ui.edbn.me/docs/components/label
---

# Label

An accessible label for form controls that follows their disabled state. Pairs with Field, Input, Checkbox, and the other form components.

## Installation

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

## Dependencies
- edbn: edbn-base

## Usage

```tsx examples/label-basic.tsx
"use client";
import { Input } from "@/components/ui/input";
import { Label } from "@/components/ui/label";

export default function LabelBasicPreview() {
  return (
    <div className="grid gap-2">
      <Label htmlFor="label-input">Project name</Label>
      <Input id="label-input" defaultValue="Acme" />
    </div>
  );
}
```

## Files
- components/ui/label.tsx (21 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
