If you’re an American and you want to feel old, try going out to dinner in the south of Spain during the summer. Show up at 8:30 p.m. and you’ll be the only person in the restaurant. Come back at 9:30 and there will be a few other folks—all Americans, all retirees, all taking advantage of the Spanish equivalent of the early bird special. It’s only at 10:30 that the Spaniards themselves start to arrive—with bedtime following many hours later.
(Find out what country you sleep like.)
The world is home to 196 different countries—and that means 196 different bedtimes and wake times. Not everybody’s personal body clock is perfectly suited to the rhythms of home, of course. There are surely some innately late-rising Americans who struggle with our country’s crack-of-dawn culture. There are surely some morning larks who get awfully lonely at 7 a.m. in Spain. So what country is best for you? Figuring that out has just gotten easier, thanks to an imaginative study by mathematicians Olivia Walch, Amy Cochran and Daniel Forger of the University of Michigan—and an interactive test, available here:
The research, just published in the journal Science, is based on data collected with a simple smartphone app, called ENTRAIN. Designed by the investigators for both Android and Apple devices, the app asks users to input a number of bits of basic information, including their age, gender, country, time zone and daily sleep and wake times, as well as their most common lighting environment: bright indoor, low indoor, bright outdoor, low outdoor. All people encounter all these lighting states in a single day, but the researchers were interested only in the predominant one.
In 2014, the first year of the study, 8,070 people downloaded and regularly used the app, uploading their information to the researchers’ database. In the second year, nearly 2,000 more joined them, making for a robust sample group that topped 10,000.
Some truths were consistent across all cultures. Gender is a key determinant of how many hours of sleep any one person gets, with women and girls logging a bit more than men and boys. Bedtime and wake time are determined principally by age. While small children go to bed early and wake up early, the pattern shifts dramatically in the teen years, with kids going to bed later and sleeping till noon on weekends if they’re allowed. Throughout adulthood and into old age, the pattern reverses again, as bedtimes and wake times creep earlier and earlier.
Beyond those broad averages, however, geography and nationality drove the sample group in a variety of directions. For the sake of simplicity and statistical significance, the researchers limited the places they considered to the 20 that submitted the most results: the U.S., Australia, Canada, the U.K., France, Spain, The Netherlands, Denmark, Germany, Belgium, China, Japan, Brazil, Switzerland, Singapore, Hong Kong, Italy, Finland, New Zealand and the United Arab Emirates.
The results, in a lot of ways, ran true to cultural form. The Japanese tend to get up early and go to bed late—consistent with their reputation for early-rising industriousness and long evenings spent socializing with co-workers. Americans indeed keep retirement community hours, with the fourth earliest bedtime (after Belgium, Australia and New Zealand) and the very earliest wake time. Germany maintains sensible hours in the middle of both charts. The French rival the Spanish for late-night café life, but it’s Spain and Singapore that are the last in the world—or at least the last in the sample group—to hit the lights and call it a day.
While time of sunrise and sunset do play a role in all of this, it’s a far smaller one than when we lived in the state of nature. “There are differences in latitudes [which determine hours of sunlight],” says Walch, “but they’re always engulfed by artificial light and culture.”
As newer versions of ENTRAIN are introduced, the developers hope that people will find practical uses for them. Once they have stored enough information about their daily sleep patterns, for example, the app could tell them what their optimum bedtime is, warn them what time of day they’re likely to crash if they’ve pulled an all-nighter the day before, and recommend ways to adjust their circadian rhythms when they cross time zones.
No matter how the app gets used, its help will surely be welcome. In a world divided by way too many things, sleep is one of the great levelers. We’ve all got to do it and, almost without exception, we’re all happy for something that offers us ways to do it better.
More Must-Reads from TIME
- Donald Trump Is TIME's 2024 Person of the Year
- Why We Chose Trump as Person of the Year
- Is Intermittent Fasting Good or Bad for You?
- The 100 Must-Read Books of 2024
- The 20 Best Christmas TV Episodes
- Column: If Optimism Feels Ridiculous Now, Try Hope
- The Future of Climate Action Is Trade Policy
- Merle Bombardieri Is Helping People Make the Baby Decision
Write to Jeffrey Kluger at jeffrey.kluger@time.com