<option> HTML Tag

Disclosure: Your support helps keep the site running! We earn a referral fee for some of the services we recommend on this page. Learn more
Element of
Lists Bring Order To Web Pages: Here’s The HTML Code To Create Them
What does <option> HTML Tag do?
The <option> element is used in conjunction with the <select> element to create a drop-down menu in a web form. Each <option> element is displayed as an available option in the resulting drop-down menu.

Code Example

<p><strong>Select your favorite species of flamingo.</strong></p>

<select name="favorites">
          <option value="American">American flamingo</option>
          <option value="Greater">Greater flamingo</option>
          <option value="Lesser">Lesser flamingo</option>
          <option selected value="Andean">Andean flamingo</option>
          <option value="Chilean">Chilean flamingo</option>
          <option value="James's">James's flamingo</option>

Select your favorite species of flamingo.

Defining List Options

The <option> element is used to define options in a drop-down list. If your list contains a large number of options, consider splitting it into labelled groups using the <optgroup> element.

Claire is seasoned technical writer, editor, and HTML enthusiast. She writes for HTML.com and runs a content agency, Red Robot Media.

Browser Support for option