Netflix has taken down an episode of a satirical comedy show critical of Saudi Arabia in the country after officials from the kingdom complained, sparking criticism from Human Rights Watch, which said the act undermined the streaming service’s “claim to support artistic freedom”.

It comes three months after the brutal killing of the Saudi dissident and Washington Post columnist Jamal Khashoggi – which US senators have blamed on the Saudi crown prince, Mohammed bin Salman – and as the war in Yemen continues to devastate the country.

The American comedian Hasan Minhaj was critical of the Saudi heir in an episode of the standup show Patriot Act, delivering a wide-ranging monologue mocking the Saudis’ evolving account of what happened inside the country’s consulate in Istanbul in October, when the journalist was killed.

“The Saudis were struggling to explain his disappearance: they said he left the consulate safely, then they used a body double to make it seem like he was alive,” Minhaj, an American-born Muslim of Indian descent, said. “At one point they were saying he died in a fist fight, Jackie Chan-style. They went through so many explanations. The only one they didn’t say was that Khashoggi died in a free solo rock-climbing accident.”

He went on to specifically criticise Prince Mohammed, “examining the connection” between the Saudi-led military campaign in Yemen and the starvation and destruction that has unfolded in the Gulf state since 2015. Saudi Arabia has been condemned within the UN for the widespread bombing of civilian areas.

Human Rights Watch said artists whose work is broadcast on Netflix should be outraged, adding that Saudi Arabia has no interest in its citizens exercising democratic rights.

“Every artist whose work appears on Netflix should be outraged that the company has agreed to censor a comedy show because the thin-skinned royals in Saudi complained about it,” a spokesperson said. “Netflix’s claim to support artistic freedom means nothing if it bows to demands of government officials who believe in no freedom for their citizens – not artistic, not political, not comedic.”

Minhaj, 33, became the senior correspondent on Comedy Central’s The Daily Show in 2014 and appeared as the coveted featured speaker at the White House correspondents’ dinner in 2017.

Netflix defended its decision, stressing that it was in response to a “valid legal request” from the kingdom’s communications and information technology commission, to which it acceded in order to “comply with local law”.

“We strongly support artistic freedom worldwide and only removed this episode in Saudi Arabia after we had received a valid legal request – and to comply with local law,” the company told the Financial Times.

It added that the Saudi telecoms regulator cited a cyber-crime law that states that “production, preparation, transmission, or storage of material impinging on public order, religious values, public morals, and privacy, through the information network or computers” is a crime punishable by up to five years in prison and a fine not exceeding SR3m ($800,000).

The episode can still be seen in other parts of the world – and in Saudi Arabia on YouTube – yet it is likely to raise pressing new questions about the limits of free online expression and the responsibility of western companies to uphold liberal values.

Karen Attiah, Khashoggi’s editor at the Washington Post, said that it was outrageous that Netflix had caved to pressure from Saudi Arabia.

“Hasan Minhaj of Patriot Act has been a strong, honest and (funny) voice challenging Saudi Arabia + Mohammed bin Salman in the wake of # khashoggi’s murder,” she tweeted. “He brought awareness about Yemen. Quite outrageous that Netflix has pulled one of his episodes critical of Saudi Arabia.

“When Jamal Khashoggi wrote about the need for free expression in the Arab world (and everywhere), that freedom is not just about journalists. It’s about freedom for artists, comedians, cartoonists, musicians, activists and anyone who wants to express their views on society.”

The NGO Reporters Without Borders in October ranked Saudi Arabia 169th out of 180 countries for press freedom, adding that “it will very probably fall even lower in the 2019 index because of the gravity of the violence and abuses of all kinds against journalists”.

The Saudi information ministry and Netflix did not respond to requests for comment.