What would it look like if the websites we build actually cared about the people using them?
Not in the polite, marketing sense — in a real, structural way. A way that takes responsibility for the impact a product has on the lives of the people who interact with it. Even when that means asking them to put the product down.
That is the question behind night night (nightnight.みんな — みんな is Japanese for "everyone"), a small open-source project we made to put websites to sleep at bedtime.
What it is
night night is a single line of code you drop into a website. During the day the site behaves as normal. At bedtime, it gently goes to sleep — showing a quiet sleep page that encourages the visitor to step away and get some rest. If they really need to stay, a single click lets them carry on. The sleep and wake times are configurable. It works in any time zone, because it reads the user's local clock. It supports fourteen languages out of the box, with full RTL for Arabic, and falls back to English if the visitor's language isn't yet covered.
Why we built it
As designers and technology creators, we tend to optimise for engagement, retention, and conversion. The metrics that win us promotions are the ones that pull people deeper into our products. But the same systems that delight us during the day quietly hurt us at night. Sleep debt is one of the largest, least-discussed health problems in the modern world. One missed night of sleep impairs cognition as much as being intoxicated. The cumulative effects show up as stress, depression, hypertension, heart and kidney disease, motor vehicle accidents, even suicide. About one third of people in the United States don't get enough sleep.
If our websites are part of why people stay up too late, we are part of the problem. night night is a tiny, deliberate way to be part of the solution.
Universal responsibility
night night is an expression of one of our core ideas at Masamichi Souzou: universal responsibility. The idea that as designers and technology creators we are responsible for all of the outcomes of our creations — not only the ones our metrics measure. We have a duty to deliver a great product experience. We also have a duty to the wellbeing of the people on the other side of the screen. Sometimes those duties pull in different directions, and the responsible answer is to help people step away.
How to use it
Add a single script tag just above the closing </body> on any HTML page, with your preferred sleep and wake hours. That is it. The full code, documentation, and self-hosting instructions are open source under the MIT licence.
Get night night for your website →
If you build websites, we would love for you to install it. And we would love to hear what you think. A small line of code is a small thing, but enough small things, in enough places, start to add up to a different kind of internet — one that helps people live well, and sleep well, on their own terms.