Thailand has threatened Facebook with legal action unless it removes 131 pages it considers illegal, including posts critical of the monarchy, within four days.

“If even a single illicit page remains, we will immediately discuss what legal steps to take against Facebook Thailand,” Takorn Tantasith, secretary-general of the National Broadcasting and Telecommunications Commission, told reporters.

“Every person must comply with Thai laws, and strictly follow rulings by local courts,” Takorn was quoted as saying in the Bangkok Post.

He set the deadline for the social media giant to comply at 10am local time on Tuesday.

Thailand’s has some of the world’s strictest laws protecting the royal family from public criticism.

The royalist military government has led a focused crackdown since it took power in a 2014 coup. With each offence punishable by up to 15 years in jail, more than 105 lese majeste, meaning royal insult, charges have been raised since the junta took power.

Sensitivity over anything perceived as criticism of royal affairs has surged since the much-loved former king died in October and his son, Maha Vajiralongkorn, ascended to the throne.

Facebook has already removed 178 of the 309 pages drafted by Thai courts for removal, Takorn said. “Facebook must either remove the remaining 131 pages by Tuesday morning or face legal action,” he said.

He warned that the digital economy and society ministry could file a complaint with the police against Facebook Thailand.

The Thai army’s Cyber Centre also announced this week it had identified 820 online cases deemed to insult the monarchy during the past seven months, split between Facebook, YouTube and Twitter.

More than half have been blocked, the army said according to local media.

Google, which owns YouTube, had an 85% compliance rate for Thailand’s content removal requests during the second half of 2015, according to its transparency report. The Guardian has requested updated figures.

Facebook did not immediately respond to a request for comment.

The draconian royal defamation law forces local and foreign media in Thailand to regularly self-censor.

Last month, Thai authorities banned any online interaction with three of its most prominent overseas critics, including two academic and a anti-monarchist writer. At least five people have been arrested for sharing Facebook posts by one of the scholars, Paris-based historian Somsak Jeamteerasakul.

The Facebook pages for all three of the banned critics remain viewable on Friday in Thailand.

Separately, human rights lawyer Prawet Prapanukul has been hit with ten counts of royal defamation meaning he could face a maximum 150-years in jail. The 57-year-old remains in detention.