Google has responded to a growing number of brands’ suspending their advertising from its services after finding their ads were appearing next to inappropriate and extremist content. In a blog post, the company said “we can do a better job” and that it would update its ad policies and tools to give brands more control over where their ads appear.

The online advertising giant was summoned to appear before the UK government on Thursday after authorities found that ads for taxpayer-funded bodies – such as the BBC, the Royal Air Force, and the Royal Navy – had been positioned next to “extremist” YouTube videos. The government has pulled all its advertising from Google until the company can provide assurances that government ads will appear only in safe environments.

A source told Business Insider that Google would meet with the cabinet office on Friday.

Brands including The Guardian, Channel 4, the FCA, Transport for London, and L’Oreal have all suspended their campaigns from Google after finding their ads had appeared in inappropriate places on Google’s websites.

In a blog post published Friday, the managing director of Google UK, Ronan Harris, said the company had policies to prohibit ads from appearing on pages or videos with “hate speech, gory, or offensive” content but acknowledged that with the millions of sites in its network and the 400 hours of video uploaded to YouTube every minute, “we don’t always get it right.”

Harris said: “We’ve heard from our advertisers and agencies loud and clear that we can provide simpler, more robust ways to stop their ads from showing against controversial content. While we have a wide variety of tools to give advertisers and agencies control over where their ads appear, such as topic exclusions and site category exclusions, we can do a better job of addressing the small number of inappropriately monetized videos and content.”

Harris continued to say Google had begun a “thorough review” of its ads policies and brand controls and would be making changes in the coming weeks to give brands more control over where their ads appear on Google’s services.

When brands pay for online ad campaigns, they usually do not buy each ad placement individually. Instead they use a method called programmatic that uses automated systems to target large audiences across a swathe of websites or different YouTube videos.

Programmatic advertising is seen as an efficient way to reach specific audiences online, but it can also risk some ads inadvertently appearing next to undesirable content if proper white lists, blacklists, and other safety checks are not put in place by both the ad platform and the ad buyer.

Here is the full blog post from Ronan Harris, the managing director of Google UK and Ireland:

“From our founding days at Google, our mission has always been to make information universally accessible and useful. We believe strongly in the freedom of speech and expression on the web-even when that means we don’t agree with the views expressed.

“At the same time, we recognize the need to have strict policies that define where Google ads should appear. The intention of these policies is to prohibit ads from appearing on pages or videos with hate speech, gory or offensive content. In the vast majority of cases, our policies work as intended. We invest millions of dollars every year and employ thousands of people to stop bad advertising practices. Just last year, we removed nearly 2 billion bad ads from our systems, removed over 100,000 publishers from our AdSense program, and prevented ads from serving on over 300 million YouTube videos.

“However, with millions of sites in our network and 400 hours of video uploaded to YouTube every minute, we recognize that we don’t always get it right. In a very small percentage of cases, ads appear against content that violates our monetization policies. We promptly remove the ads in those instances, but we know we can and must do more.

“We’ve heard from our advertisers and agencies loud and clear that we can provide simpler, more robust ways to stop their ads from showing against controversial content. While we have a wide variety of tools to give advertisers and agencies control over where their ads appear, such as topic exclusions and site category exclusions, we can do a better job of addressing the small number of inappropriately monetized videos and content. We’ve begun a thorough review of our ads policies and brand controls, and we will be making changes in the coming weeks to give brands more control over where their ads appear across YouTube and the Google Display Network.

“We are committed to working with publishers, advertisers and agencies to address these issues and earn their trust every day so that they can use our services both successfully and safely.”