HTML contenteditable Attribute
Example
An editable paragraph:
<p contenteditable="true">This is an editable paragraph.</p>
Try it Yourself »
Definition and Usage
The contenteditable attribute specifies whether the content
of an element is editable or not.
Note: When the contenteditable attribute is not set on an
element, the element will inherit it from its parent.
Syntax
<element contenteditable="true|false">
| Value | Description |
|---|---|
| true | Specifies that the element is editable |
| false | Specifies that the element is not editable |
Browser Support
The numbers in the table specify the first browser version that fully supports the attribute.
| Attribute | |||||
|---|---|---|---|---|---|
| contenteditable | 4.0 | 6.0 | 3.5 | 3.1 | 10.1 |
Related Pages
HTML Tutorial: HTML Attributes
HTML DOM Reference: HTML DOM contentEditable Property