The :default pseudo-class matches form elements that are the default in a related group — for example a radio/checkbox with the checked attribute, a default option, or a form’s default submit button.
It is not the same as :checked. :checked follows the current selection; :default points at the control that was defined as the default.
Baseline · Widely available.
Not deprecated. Cross-browser since about January 2020. Not supported in Internet Explorer.
Teaching tip.
Change a radio group in the live preview: the coral ring (:default) can stay on Summer while the selected radio moves.
Syntax
CSS Syntax
syntax.css
:default {/* styles for the default control */ }
Often paired with a type or sibling: input:default, option:default, input:default + label.
A is the HTML default. It has checked in the markup.
:default adds “(default)”. Tied to that original default.
:checked bolds the current pick. Switch to B to see bold move.
Takeaway. Default ≠ currently selected after the user changes the group.
Edge Cases & Pitfalls
Most confusion is mixing up “default in the form” with “checked right now.”
vs-checked
Not a synonym for :checked
Use :checked for the live selection. Use :default for the original default control.
options
option:default styling varies
Native select UIs limit how much you can style options. Test in your target browsers.
submit
Default submit is about the form
The first submit-capable control belonging to the form is typically the default. Extra buttons with type="button" do not submit.
multiple
Multiple selected options
In a multiple select, more than one option can match :default.
ie
No Internet Explorer support
Do not rely on :default alone if you must support IE; treat it as progressive enhancement.
Compatibility
Browser Support
:default is a browser CSS pseudo-class for form defaults. Node.js, Deno, and Bun do not apply it.
✓ Baseline · Widely available
:default
Chrome 10+, Firefox 4+, Safari 5+, Edge 79+. Widely available since January 2020. Not supported in Internet Explorer.
95%Browser support
Google Chrome10+
Full support
Mozilla Firefox4+
Full support
Apple Safari5+
Full support
Microsoft Edge79+
Full support
Opera10+
Full support
Samsung Internet1+
Full support
Internet ExplorerNot supported
Not supported
:defaultWidely supported
Bottom line: Safe for modern form UX as progressive enhancement. Pair with clear HTML defaults. It is not a runtime API.
Remember
Key Takeaways
Role: highlight the default control in a form group.
vs :checked: default is original; checked is current.
Also covers: default options and the form submit button.
Enhance: fine for modern browsers; skip IE-only needs.
One line: use :default to style the form’s original default control, not just the current selection.
Frequently Asked Questions
It matches form controls that are the default in their group — such as a radio or checkbox with the checked attribute, a default option, or a form’s default submit button.
option, input (checkbox/radio with checked, and submit-like controls), and button when it is the form’s default submit control.
:default tracks the original default from the markup/form rules. :checked tracks whatever is selected right now. After the user picks another radio, :checked moves; :default usually stays on the original default.
No. A checkbox matches :default when it is marked as the default (typically via the checked attribute in HTML), not merely because the user checked it later.
Yes. :default matches the form’s default submission button — generally the first submit button belonging to that form in DOM order.
It is Baseline and widely available since about January 2020. It is a browser CSS pseudo-class, not a Node.js API. Internet Explorer does not support it.