HOME HTML CSS JAVASCRIPT SQL PHP JQUERY XML ASP.NET MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

HTML contenteditable Attribute

HTML Global Attributes HTML Global Attributes

Example

An editable paragraph:

<p contenteditable="true">This is an editable paragraph.</p>

Try it Yourself »

Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The contenteditable attribute is supported in all major browsers.


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.


Differences Between HTML 4.01 and HTML5

The contenteditable attribute is new in HTML5.


Syntax

<element contenteditable="true|false">

Attribute Values

Value Description
true Specifies that the element is editable
false Specifies that the element is not editable


HTML Global Attributes HTML Global Attributes

Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates

SHARE THIS PAGE