# TextArea
**Category**: react
**URL**: https://www.heroui.com/docs/react/components/text-area
**Source**: https://raw.githubusercontent.com/heroui-inc/heroui/refs/heads/v3/apps/docs/content/docs/react/components/(forms)/text-area.mdx
> Primitive multiline text input component that accepts standard HTML attributes
***
## Import
```tsx
import { TextArea } from '@heroui/react';
```
For validation, labels, and error messages, see **[TextField](/docs/components/text-field)**.
### Usage
```tsx
import {TextArea} from "@heroui/react";
export function Basic() {
return (
);
}
```
### Controlled
```tsx
"use client";
import {Description, TextArea} from "@heroui/react";
import React from "react";
export function Controlled() {
const [value, setValue] = React.useState("");
return (
);
}
```
### Rows and Resizing
```tsx
import {Label, TextArea} from "@heroui/react";
export function Rows() {
return (
);
}
```
### Full Width
```tsx
import {TextArea} from "@heroui/react";
export function FullWidth() {
return (
);
}
```
### Variants
The TextArea component supports two visual variants:
- **`primary`** (default) - Standard styling with shadow, suitable for most use cases
- **`secondary`** - Lower emphasis variant without shadow, suitable for use in Surface components
```tsx
import {TextArea} from "@heroui/react";
export function Variants() {
return (
);
}
```
### In Surface
When used inside a [Surface](/docs/components/surface) component, use `variant="secondary"` to apply the lower emphasis variant suitable for surface backgrounds.
```tsx
import {Surface, TextArea} from "@heroui/react";
export function OnSurface() {
return (
);
}
```
## Related Components
- **TextField**: Composition-friendly fields with labels and validation
- **Input**: Single-line text input built on React Aria
- **Label**: Accessible label for form controls
## Styling
### Passing Tailwind CSS classes
```tsx
import {Label, TextArea} from '@heroui/react';
function CustomTextArea() {
return (