LONDON — Every generation of adults loves to complain about today's unruly, good-for-nothing young people. But a group of Danish researchers says kids these days are actually on their best behavior.

“In Denmark, we are observing a trend toward a much more law-abiding youth,” said Rannva Moller Thomsen, an analyst with the Danish Crime Prevention Council. A recent long-term study funded by the council found that the share of 14-to-15-year olds who confessed to shoplifting at least one time dropped from 46 percent in 1989 to 17 percent in 2016. The number of other types of crimes committed similarly decreased.

There are numerous possible explanations: Committing crimes has become more difficult because of improved safety mechanisms in cars or homes, researchers argue. Moreover, education reforms may have resulted in a greater emphasis among younger students on their performance in school, making them less likely to commit crimes.

But the most surprising explanation may be the simplest one: the Internet. “When young people spend time together in public spaces or meet privately and unwatched, the likelihood of them committing crimes increases,” said Moller Thomsen. “Many young people spend significantly more time online today than they did a few years ago. Overall, they are less social — but also less criminal.”

Susan McVie, a professor of quantitative criminology at the University of Edinburgh, agreed that fewer outdoor activities may also mean less time “hanging around in public places and exposing themselves to potentially delinquent activities,” but cautioned that more research was needed to prove the link with certainty.

The researchers relied on self-reporting of crimes in anonymous questionnaires instead of using publicly accessible official numbers. They think that crimes committed by younger people are often not sufficiently reflected in the official statistics. The data collected by government agencies across Europe shows that the crime level drop is not unique to Denmark.

But Danish children and teenagers also spend more time alone than their peers elsewhere in the world, according to a 2016 report by the World Health Organization, so there may be other possible explanations for the crime level drops in different countries.

In Britain, where youth crime levels have also sharply fallen, government and privately owned initiatives have been praised for creating organized activities that keep kids away from both the streets and from their computers and smartphones.

Simon Agboola, a 39-year-old soccer coach in west London, pointed out the dangers of confining high school students to public spaces such as streets and apartment courtyards rather than offering them “safe spaces” where they are watched and trained by volunteers. His Unity of Faiths Foundation has allowed more than 3,000 people to play soccer free on professional-quality fields, and similar projects have gained support across Europe over the past few decades.

Efforts to keep young people away from the Internet are also based on the controversial argument that children and teenagers may be behind a recent rise in crimes committed online.

“There is an increasing amount of evidence to show that young people that are traditionally more likely to take part in street-based crime are also the most likely to engage in online forms of fraud or violence,” McVie said. Other types of online crimes, such as the illegal streaming of films or music, are also on the rise, she said — a trend which has led to discussions whether online downloads should be compared with offenses such as shoplifting.

But, at least in Denmark, there has been little evidence that crimes committed by youths online have compensated for the drop in more ordinary crimes. “What we have observed, however, is that 14- to 15-year olds are increasingly likely to turn into victims online rather than into offenders,” Moller Thomsen said.

Read more: