@charset

An at-rule used to define the character encoding of the CSS file. It must be at the very first line of the file and only one is allowed.

Quick example

/* Must be the very first line */
@charset "UTF-8";

@charset Browser Support

Widely available Since 2015 96% global usage

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

Safe to use without fallbacks.

2+
1.5+
4+
12+
ESC