v150 · HTML · Element Types Comparison
Element Types Comparison
The autocorrect attribute is a global attribute that works on any element where text input is collected — <input>, <textarea>, and contenteditable elements. It also inherits from ancestor elements.
supported elements
| Element | autocorrect="on" | autocorrect="off" | Inherits? | Default |
|---|---|---|---|---|
<input type="text"> |
✓ | ✓ | ✓ | on |
<input type="email"> |
— | ✓ (always off) | — | off (forced) |
<input type="url"> |
— | ✓ (always off) | — | off (forced) |
<input type="password"> |
— | ✓ (always off) | — | off (forced) |
<textarea> |
✓ | ✓ | ✓ | on |
[contenteditable] |
✓ | ✓ | ✓ | on |
live elements
<input type="text" autocorrect="off">
Code editor / username field — no autocorrect
<textarea autocorrect="on">
Comment field — autocorrect active
<div contenteditable autocorrect="off">
Rich text editor — autocorrect disabled
Edit this text — no autocorrect applied
Form-level inheritance
Child inputs inherit from form's autocorrect="off"
when to use each value
autocorrect="on" (or default)
- Comment boxes and feedback forms
- Chat and messaging interfaces
- Long-form text areas (blog posts, emails)
- Description or bio fields
- Any natural language input
autocorrect="off"
- Code editors and terminal input
- Username and handle fields
- Domain names and URLs
- Template variables (e.g.
{{name}}) - Technical identifiers (IDs, tokens, slugs)
- Search boxes where exact terms matter
- Database query fields