Navigation: [/sitemap.md](/sitemap.md)

---
type: doc
title: Textarea
description: Displays a form textarea or a component that looks like a textarea.
---

```astro live props={{ name: 'textarea' }}
---
import { Label } from "@/components/ui/label"
import { Textarea } from "@/components/ui/textarea"
---

<div class="grid w-full max-w-sm gap-2">
  <Label for="message">Message</Label>
  <Textarea id="message" placeholder="Type your message here..." />
  <Textarea placeholder="Disabled textarea" disabled />
</div>
```

## Installation

```bash
npx shadcn@latest add @fulldev/textarea
```

## Usage

```ts
import { Textarea } from "@/components/ui/textarea"
```

```astro
<Textarea placeholder="Type your message here..." />
```

## Notes

- Use `Textarea` for longer free-form input where multiple lines are expected.
- Set `rows` when you want a clearer default height.
- Pair it with [Field](/components/field/) when you need descriptions or
  validation messaging.

## Example

```astro
<Textarea rows={6} placeholder="Write your message..." />
```

## API Reference

See the [GitHub source code](https://github.com/fulldotdev/ui/tree/main/src/components/ui/textarea) for more information on props.
