---
title: Text Input
desc: Text Input is a simple input field.
layout: components
classnames:
component:
- class: input
desc: For tag or a wrapper of tag
style:
- class: input-ghost
desc: ghost style
color:
- class: input-neutral
desc: neutral color
- class: input-primary
desc: primary color
- class: input-secondary
desc: secondary color
- class: input-accent
desc: accent color
- class: input-info
desc: info color
- class: input-success
desc: success color
- class: input-warning
desc: warning color
- class: input-error
desc: error color
size:
- class: input-xs
desc: Extra small size
- class: input-sm
desc: Small size
- class: input-md
desc: Medium size
default: true
- class: input-lg
desc: Large size
- class: input-xl
desc: Extra large size
---
### ~Text input
```html
```
### ~Text input with text label inside
#### We can use input class for the parent and put anything inside it
```html
```
### ~Disabled
```html
```
## Input types
`input` class can be used for any input field type. Including `text`, `password`, `email`, `number`, `date`, `datetime-local`, `week`, `month`, `tel`, `url`, `search`, `time`
For `checkbox`, `radio`, `file`, `range` use their own class names, as they are not visually input fields.
Inputs can be used with `validator` class to have validation styles. [See Validator component](/components/validator/) for more details.
### ~Text input with data list suggestion
```html
```
### ~Date input
```html
```
### ~Time input
```html
```
### ~datetime-local input
```html
```
### ~Username text input with icon and validator
```html
Must be 3 to 30 characters
containing only letters, numbers or dash
```
### ~Search input with icon
```html
```
### ~Email input with icon and validator
```html
Enter valid email address
```
### ~Email input with icon, validator, button, join
```html
Enter valid email address
```
### ~Password input with icon and validator
```html
Must be more than 8 characters, including
At least one number
At least one lowercase letter
At least one uppercase letter
```
### ~Number input with validator
```html
Must be between be 1 to 10
```
### ~Telephone number input with icon and validator
```html