# Light and Darkmode in CSS?

**URL:** https://community.glideapps.com/t/light-and-darkmode-in-css/55786
**Category:** Ask for Help
**Created:** [December 16, 2022, 11:31am UTC](https://community.glideapps.com/t/light-and-darkmode-in-css/55786 "2022-12-16T11:31:29Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Carter](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/carter/32/45004_2.png) [@Carter](https://community.glideapps.com/u/Carter)
#### Post date: [December 16, 2022, 11:31am UTC](https://community.glideapps.com/t/light-and-darkmode-in-css/55786/1 "2022-12-16T11:31:29Z")

</div>

I would like to know if anyone knows if there are css class for light and darkmode CSS?

---

<div class="post-metadata">

### Author: ![Robert\_Petitto](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/robert_petitto/32/25193_2.png) [@Robert\_Petitto](https://community.glideapps.com/u/Robert_Petitto)
#### Post date: [December 16, 2022, 1:33pm UTC](https://community.glideapps.com/t/light-and-darkmode-in-css/55786/2 "2022-12-16T13:33:11Z")

</div>

@ThinhDinh has a EC column that does a decent job.

---

<div class="post-metadata">

### Author: ![Carter](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/carter/32/45004_2.png) [@Carter](https://community.glideapps.com/u/Carter)
#### Post date: [December 16, 2022, 1:59pm UTC](https://community.glideapps.com/t/light-and-darkmode-in-css/55786/3 "2022-12-16T13:59:52Z")

</div>

Oh, i will give him some love for christmas if he can share it !

---

<div class="post-metadata">

### Author: ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)
#### Post date: [December 17, 2022, 12:13am UTC](https://community.glideapps.com/t/light-and-darkmode-in-css/55786/4 "2022-12-17T00:13:45Z")

</div>

> [@Dark/Light mode detection](https://community.glideapps.com/t/dark-light-mode-detection/32136):
>
> In some cases where I enable match device’s theme, I find some of my images/illustrations does not work that well on both dark & light mode. Therefore I created this column so I can cover both bases. Demo: Hope it helps some of your use cases, especially for designing.

It only helps you with detecting the mode though, you would still have to write the right code for each scenario.

---

<div class="post-metadata">

### Author: ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)
#### Post date: [December 17, 2022, 12:18am UTC](https://community.glideapps.com/t/light-and-darkmode-in-css/55786/5 "2022-12-17T00:18:24Z")

</div>

You can also use prefers-color-scheme for a pure CSS solution.

> **[Dark Mode in CSS | CSS-Tricks](https://css-tricks.com/dark-modes-with-css/)**
>
> With the introduction of dark mode in macOS, Safari Technology Preview 68 has released a new feature called prefers-color-scheme which lets us detect whether
