このロケールの翻訳が存在しないため、英語バージョンのコンテンツを表示しています。 Help us translate this article!

This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.

The ::-moz-color-swatch CSS pseudo-element is a Mozilla extension that represents the color selected in an <input> of type="color".

Note: Using ::-moz-color-swatch with anything but an <input type="color"> doesn't match anything and has no effect.


Syntax not found in DB!



<input type="color" value="#de2020" />


input[type=color]::-moz-color-swatch {
  border-radius: 10px;
  border-style: none;



Not part of any specification. This is a proprietary pseudo-element specific to Gecko.

Browser compatibility

Update compatibility data on GitHub
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
Chrome No support NoEdge No support NoFirefox Full support 27IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoFirefox Android Full support 27Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No


Full support  
Full support
No support  
No support
Non-standard. Expect poor cross-browser support.
Non-standard. Expect poor cross-browser support.

See also

  • Similar pseudo-elements used by other browsers: