HTML Mark Tag <mark> is used to mark certain portion of text from the HTML resource or webpage.
In other words, we can say that whenever we want to mark or highlight certain portion of text in HTML resource we use the Mark Tag <mark>.
Mark Tag is a closed tag and needs a closing Mark Tag </mark>.
Note: Mark Tag is new in HTML 5.
Syntax of HTML Mark Tag
<mark> Some text .. </mark>
Example of HTML Mark Tag
HTML Mark Tag Code | Output |
<p> I have to attend a <mark> meeting @ 3 </mark>pm today</p> |
I have to attend a meeting @ 3 pm today |
In the output of the HTML Mark Tag example above we can see that the text “meeting @ 3” within the Mark HTML Tag is being displayed highlighted and that’s the usage of Mark Tag in HTML.
HTML Mark Tag Supports all HTML Global Attributes and HTML Event Attributes.
HTML Mark Tag Supporting Browsers
S. No. | Browser | Supported(Yes/No) |
1 | Internet Explorer | Yes (from IE-9 onwards) |
2 | Firefox | Yes |
3 | Google Chrome | Yes |
4 | Opera | Yes |
5 | Safari | Yes |