English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
The HTML <nav> tag is an HTML5An element used to define a part of the HTML document that contains navigation links. This tag is also commonly referred to as the <nav> element.
An example of a navigation link:
!doctype html> <html> <head> <meta charset="UTF-8"> <title>HTML5 Use of nav tag (Basic Tutorial Website oldtoolbag.com)</title> </head> <body> <nav> <ul> <li><a href="/section1/index.html">Section1</a></li> <li><a href="/section2/index.html">Section2</a></li> <li><a href="/section3/index.html">Section3</a></li> </ul> </nav> </body> </html>Test to see ‹/›
IEFirefoxOperaChromeSafari
Most browsers currently support the <nav> tag.
<nav> tag defines the part of navigation links.
<nav> tag is used to create navigation in HTML documents.
Not all HTML documents need to use the <nav> element. The <nav> element is just used to mark the area of a navigation link.
navigation links can be set to display on different devices (mobile or PC) to meet the needs of different screens.
for IE versions earlier than 9IE browsers, please use HTML5shiv, which is a JavaScript solution, can provide support for new HTML5elements provide support, for example: <header>, <main>, <article>, <section>, <aside>, <nav>, <footer>.
<nav> is an HTML5 new tag.
<nav> tag supports global attributes, see the complete attribute table HTML Global Attributes.
<nav> tag supports all HTML Event Attributes.