:selected (since jQuery 1.0) matches <option> elements that are currently selected in a <select>. Official docs: it does not work for checkboxes or radios — use :checked for those.
Syntax
Start with these common calls. Keep them short and readable.
jQuery
$("option:selected") // selected options
$("select option:selected") // official-style scope
$("#city option:selected").text() // visible label
$("#city").val() // value attribute (simpler)
// Not for checkboxes / radios → use :checked
// Faster pattern:
$("#city option").filter(":selected")
Call
What it does
Selector string
:selected (best with an option / select prefix)
<select> context
Limits matches to one dropdown
change handler
Refresh labels/values after user input
Return value
jQuery collection of selected <option>s (0+)
Load jQuery before your script (CDN or local file), then wrap DOM work in $(function () { ... }) when needed.
Parameters
Parameter
Description
Step 1
Prefer $("select option:selected") or an id-scoped query.
Step 2
Bind change on the <select> so results stay current.
Step 3
Use .text() for the label, .val() on the select for the value.
Return Value
Return Value
Description
See examples
Check the examples below for what this API returns in common cases.
jQuery Examples
Example 1 — Official Demo: option:selected on Change
Collect selected option text whenever the dropdown changes (jQuery API example).
text: Paris
value: par
(Updates when you change the city)
How It Works
Text.option:selected + .text() is what the user sees.
Value.$("#city").val() reads the option’s value attribute.
Refresh. Re-run on change so both stay in sync.
Frequently Asked Questions
:selected matches every option element that is currently selected inside a select dropdown. Official jQuery docs: it works for option elements. Available since jQuery 1.0.
No. Official docs state that :selected does not work for checkboxes or radio inputs — use :checked for those control types instead.
:selected targets selected option elements in a select. :checked matches ticked checkboxes, selected radios, and can also match options. Prefer option:selected when you only care about dropdown selections.
Bind change on select, loop $("select option:selected").each() to collect option text, write it to a div, then .trigger("change") for the initial draw — as in the jQuery API docs.
Use $("#mySelect").val() for the value attribute, or $("#mySelect option:selected").text() for the visible label. Both read the current selection after the user changes the dropdown.
Because :selected is a jQuery extension, first select options with a CSS selector then narrow with .filter(":selected") — for example $("#mySelect option").filter(":selected").