High Contrast Mode Media Query in CSS


Ensure your website is accessible in high contrast modes with specific media queries.

Source Code

@media screen and (forced-colors: active) {
    body {
        forced-color-adjust: none;
        background-color: Window;
        color: WindowText;
    }
}
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments