Text input
The text input component is a form control that lets people enter a single line of text.
It can be useful when you need to collect information, however when data is required in a specific format, it can introduce errors which need to be handled.
Example
What problems it solves
The text input component allows people to enter free form text, instead of choosing from a list of predefined options.
When to use it
Use a text input when:
- It is not possible to predict users' answer
- People are expected to enter a single line of text
When not to use it
Do not use a text input when:
- People's possible answers are limited and can be predicted (use radio buttons, checkboxes or a
<select>instead) - People may need to enter multiple lines of text (use the textarea component instead)
- People are expected to enter non-text values, such as a telephone number
Where to use it
Text inputs are commonly used in forms to collect people's answers and personal information, such as people's name or the company they work for.
Assistive technology compatibility
This component has been tested with the following browsers and assistive technologies.
| Assistive technology | Result | Notes |
|---|---|---|
| Keyboard | No issues | No notes |
| Voice Access/Chrome 154.0.8/Windows 11 | No issues | No notes |
| JAWS 2026.2603.86/Chrome 154.0.8/Windows 11 | No issues | No notes |
| NVDA 2026.1.1/Firefox 157.0/Windows 11 | No issues | No notes |
| VoiceOver/Safari macOS Tahoe 26.6 | No issues | No notes |
| VoiceOver/Safari/iOS 26.0 | No issues | No notes |
| TalkBack/Chrome 154.0.8/Android 17 | No issues | No notes |
| Windows Contrast themes | No issues | No notes |
| Windows Magnifier and/or Apple Zoom | No issues | No notes |
| Browser zoom | No issues | No notes |
| prefers-reduced-motion | Not applicable | There are no animations to reduce |
Last updated: 13 October 2026.