IN AUGUST 2015 Heiko Maas, Germany’s justice minister, wrote an open letter to Facebook demanding better enforcement of the country’s laws against slander, defamation and hate speech. “The internet is not a lawless space where racist abuse and illegal posts can be allowed to flourish,” he told the social-networking giant. But despite Mr Maas’s efforts, hate speech has continued to proliferate on German social media. Much of it has been directed at the country’s 1.2m migrants from the Middle East and North Africa, most of whom are Muslim.

New research suggests that this digital hatred is now spilling over into the real world. A paper by Karsten Müller and Carlo Schwarz of the University of Warwick finds a strong association between right-wing, anti-refugee sentiment on German social-media sites and violent crimes against refugees. Using data from the Facebook page of the right-wing Alternative for Germany (AfD) party and statistics on anti-refugee incidents collected by local advocacy groups, the authors find that for every four additional Facebook posts critical of refugees, there was one additional anti-refugee incident (see chart). This relationship appears to be driven by violent crimes such as arson and assault, and cannot be explained by local social-media usage or demography.

This correlation is of course no guarantee of causation. However, the researchers were able to rule out several alternative theories. AfD Facebook posts that contained the words “Muslim”, “Islam” or “Juden” (Jews) but did not refer to refugees did not tend to coincide with attacks on refugees, which suggests that general anti-minority sentiment is not to blame. Similarly, posts about refugees from political parties other than the AfD did not appear to correlate with hate crimes. The authors even came across one pattern that could be described as a smoking gun: at times when residents in a given area reported poor internet connections, the correlation between social-media and anti-refugee violence in that region weakened. Messrs Muller and Schwarz conclude with a back-of-the-envelope estimate that in 2015 and 2016, the AfD’s Facebook posts increased the number of anti-refugee attacks in Germany by 13%—an additional 437 incidents.

The memory of Nazi rule means Germany takes an unusually tough stance on hate speech. Inciting hatred against minorities, for example, carries a prison sentence of up to five years. Yet applying such laws in the digital world has proved difficult. Last year the Bundestag passed a law requiring social-media companies to delete “clearly illegal” content from their platforms within 24 hours, and less clear-cut posts within a week, or face fines of up to €50m ($60m). The law, which came into force on January 1st, has been criticised for granting private companies too much power over its implementation. Some fear it could lead to legitimate content being censored. This paper adds a new aspect to this debate over how to balance free speech and the desire to hold fast against incitement of hatred. It suggests that robust enforcement of the new law could prevent hundreds of arsons and assaults.

Read more in our lead note on German hate speech in this week's issue