HTML <main> tag

Updated: 10/11/2017 by Computer Hope

HTML main tagWhen writing in HTML, the <main> tag is a block element used to denote the main content of the <body> of a document that is unique to that page. If should not contain any content that is repeated throughout the site, such as site logos, Copyright information, navigation links, sidebars, etc. There cannot be more than one <main> element in a single document.

Note: The <main> element cannot descend from an <article>, <aside>, <footer>, <header>, or <nav> element.


Within an HTML tag, an attribute dictates certain aspects of an HTML element. Attributes are made up of a name and value pair. While the <main> tag does not have any unique attributes, it does utilize all of the standard attributes.


Internet Explorer Firefox Safari Opera Chrome
Not Supported 21.0+ 7.0+ 16.0+ 26.0+

Author, Browser, Compatibility, Copyright, Logo, Web design terms