:default

A pseudo-class that targets form elements (like buttons or checkboxes) that are the default among a set of similar elements.

Quick example

button:default {
  /* Highlights the primary/default button in a form */
  outline: 2px solid #3b82f6;
  font-weight: bold;
}

:default Browser Support

Widely available Since 2020 96% global usage

This feature is well established and works across many devices and browser versions. It has been available across browsers since 2020.

Safe to use without fallbacks.

10+
4+
5+
79+
ESC