🚀 LEVEL UP TO SENIOR:Unlock 500+ Advanced Practical Challenges & Expert Masterclasses.
🎓 COURSERA PARTNER:Earn professional Google, Meta, and IBM certificates to supercharge your resume.
REFERENCEhtml

html Documentation

LOADING ENGINE...

HTML <select> Tag

Create dropdown lists. Learn select, option, optgroup, and forms.

select.html
<!-- Dropdown -->
<select name="color">
<option value="red">Red</option>
<option value="blue">Blue</option>
</select>
📋
select.html
1 / 7
📋

Tutor:The <select> tag creates a dropdown list. It contains <option> elements; each option has a value (submitted with the form) and visible text. Use the name attribute on select for form submission.


Select Mastery

Unlock nodes by learning the select tag, option, optgroup, and forms.

Concept 1: The Select Tag

The <select> tag creates a dropdown list. It contains <option> elements. Each option has a value (submitted) and text (visible). Use name on select for form submission.

System Check

Which element creates a dropdown list of choices?


Community Holo-Net

Share Select Patterns

Using <select> with option, optgroup, or forms? Share your patterns.

Enjoying this guide?

Codesyllabus is 100% free and open-source. Support our mission, pay for server infrastructure, and fuel new tutorials by buying us a coffee!

HTML <select> Tag

Author

Pascual Vila

Frontend Instructor.

The <select> tag creates a dropdown list. It contains <option> elements; each option has a value (submitted with the form) and visible text. Use the name attribute on select for form submission. Pair with <label> using for and id for accessibility.

option and optgroup

Each <option> has value (what gets submitted) and text content (what the user sees). Use <optgroup> to group options under a label. Use selected on an option for the default choice.

Attributes and forms

multiple allows multiple selections; size sets visible rows. required makes the field mandatory. Place select inside a <form> and give it a name so the selected value is submitted.

Select Tag Glossary

<select>
HTML element that creates a dropdown list. Contains <option> (and optionally <optgroup>). Use name for form submission.
<option>
Defines one choice in a select. value is submitted with the form; text content is what the user sees. Use selected for default.
<optgroup>
Groups <option> elements under a label. Use the label attribute for the group heading.