The <li> tag in HTML is used to define a List item in an HTML document. It is used within an Ordered List <ol> or Unordered List <ul>. The <li> tag requires a starting and end tag.
Note: The end tag can be omitted if the list item is immediately followed by another <li> element, or if there is no more content in its parent element.
<li> Item </li>
Attribute Value: The <li> tag contains two attributes type and value
Below examples illustrate the <li> element in HTML
Example-1: Using <li> with Ordered Lists
Example-2: Using <li> with Unordered Lists
Supported Browsers: The browser supported by <li> tag are listed below:
- Google Chrome
- Internet Explorer
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.
Improved By : MritunjayPathak