New! My 44-page ebook "CSS in 44 minutes" is out! 😃

Get it now →

# option

Defines an option within a <select> dropdown.

Example: Copy

<select name="country">
  <option value="Argentina">Argentina</option>
  <option value="Bolivia">Bolivia</option>
  <option value="Brazil">Brazil</option>
  <option value="Chile">Chile</option>
  <option value="Colombia">Colombia</option>
  <option value="Ecuador">Ecuador</option>
  <option value="Guyana">Guyana</option>
  <option value="Paraguay">Paraguay</option>
  <option value="Peru">Peru</option>
  <option value="Suriname">Suriname</option>
  <option value="Uruguay">Uruguay</option>
  <option value="Venezuela">Venezuela</option>
</select>

value

Defines the <select> value if this option is selected.

Required.

"south-africa"

This value will be sent to the server when the form is submitted.

<select>
  <option value="south-africa">South Africa</option>
</select>

label

Defines a label for the option.

"Republic of South Africa"

The label will replace the option inner text.

<select>
  <option value="south-africa" label="Republic of South Africa">South Africa</option>
</select>

disabled

Disables the option.

No value required.

The option remains visible but is not selectable anymore.

<select>
  <option>Monday</option>
  <option>Tuesday</option>
  <option disabled>Wednesday</option>
  <option disabled>Thursday</option>
  <option>Friday</option>
  <option>Saturday</option>
  <option>Sunday</option>
</select>

selected

Selects the option when the web page loads.

No value required.
<select>
  <option>Monday</option>
  <option>Tuesday</option>
  <option>Wednesday</option>
  <option>Thursday</option>
  <option selected>Friday</option>
  <option>Saturday</option>
  <option>Sunday</option>
</select>