Facebook, Google and Twitter have agreed to remove hateful posts from their platforms within 24 hours in Germany, officials announced yesterday. The web companies committed to the move in a new agreement with German authorities, after coming under increased pressure to help curb racism online in the country.

The decision comes as Germany looks to control the far-right social media backlash sparked by the arrival of over one million refugees and migrants from countries including Syria and Afghanistan.

“When the limits of free speech are trespassed, when it is about criminal expressions, sedition, incitement to carry out criminal offences that threaten people, such content has to be deleted from the net,” said German Justice Minister Heiko Maas. “And we agree that as a rule, this should be possible within 24 hours.”

The minister told reporters that the agreement will require web companies operating in Germany to conform with the law when monitoring hate speech expressed on their platforms, instead of referring to internal policies. The German law stipulates that any comment inciting violence against ethnic or religious groups is punishable by up to three years in prison.

Maas added that ‘specialist teams’ within each firm will be easily contactable for users to complain and report incidents of hate speech.

In August, a letter penned by Maas invited Facebook to meet and discuss ways to rid the the social network of racial hatred. Maas argued that German users complaining about hate-mongering and xenophobia had often been ignored, the U.S. tech giant instead focussing its efforts on cutting down pornography and nude content.

Facebook replied that it took the concerns ‘very seriously’: ‘We are very interested in an exchange of views with Minister Maas about what society, companies and politicians can do together against xenophobia spreading in Germany.’

The social network had also updated its global community standards in March, promising users that it would not allows the site to become a platform for hate speech and terrorism.