Tag Description
<optgroup> The HTML <optgroup> tag is used to group together related options in a select list.This element is used in conjunction with the <option> tag and <select> tag.

Example:

HTML Code Display

Select a city: 
<select> 
    <optgroup label="Australia">
        <option value="sydney">Sydney</option>
        <option value="melbourne">Melbourne</option>
    </optgroup>
    <optgroup label="New Zealand"> 
        <option value="cromwell">Cromwell</option>
        <option value="queenstone">Queenstone</option>
    </optgroup> 
</select>
                
Select a city: