HTML <mark> tag
Definition and Usage
<mark>
The tag defines the text that should be marked or highlighted.
See also:
HTML Tutorial:HTML Text Formatting
HTML DOM Reference Manual:Mark Object
Example
Highlight a part of the text:
<p>Don't forget to buy <mark>milk</mark> today.</p>
Global Attributes
<mark>
The tag also supports Global Attributes in HTML.
Event Attributes
<mark>
The tag also supports Event Attributes in HTML.
Default CSS Settings
Most browsers will display the following default values <mark>
Element:
mark { background-color: yellow; color: black; }
Browser Support
The numbers in the table indicate the first browser version to fully support this tag.
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
6.0 | 9.0 | 4.0 | 5.0 | 11.1 |