Lurker News
For HTML Day 2025 [1], I made a web service that displays the current sky at your approximate location as a CSS gradient. Colours are simulated on-demand using atmospheric absorption and scattering coefficients. Updates every minute, without the use of client-side JavaScript.

Source code and additional information is available on GitHub: https://github.com/dnlzro/horizon
[1] https://html.energy/html-day/2025/index.html

Comments (160) 61 threads

Earlier comments
cgijoe1 reply#
Ooh, how about this as a live desktop wallpaper!
rafinha#
Same!
joeyh#
This reminds of of a web page that did this for Ithaca NY circa 1995. The page was a static hardcoded shade of grey.
nisten#
i put my laptop next to the window and it was spot on wtf

what got me the most is opening chrome dev tools and seeing nothing there

ianbicking1 reply#
I'm around so much wildfire smoke lately that my sky expectations have changed...

I wonder what it would take to account for weather?

craftkiller#
That'd be a pretty large introduction of a dependency. The sky can be calculated with just lat/lon and the current date+time. Adding in weather would mean querying some external weather service.

Load more comments