Impression Share Drop Alert Google Ads Script

Get Alerted When Your Impression Share Drops With this Google Ads Script

Here’s another quick script in our series of free scripts we’ve been creating based on requests we receive on social media.

The script looks through all of your campaigns (or a subset of campaigns if the campaignsContain parameter is used) and finds any where the impression share has dropped more than a certain percentage between two days ago and yesterday (unfortunately today’s impression share data isn’t available via scripts).

It then sends you an alert with any of the campaigns it’s found – simple as that!

/*

    _   ___ _   _ _____ ___   _     
   /_\ / __| | | |_   _/ _ \ (_)___ 
  / _ \ (__| |_| | | || (_) || / _ \
 /_/ \_\___|\___/  |_| \___(_)_\___/


*/

var config = {
  campaignsContain: 'Brand', // Script will only look for campaigns that contain this string - leave blank to work on all campaigns
  imprShareDropThreshold: 0.1, // The percent change to trigger an alert (0.1 = 10% change)
  emails: '[email protected], [email protected]', // Comma-separated list of emails to alert 
}

function main() {
  var startDate = new Date();
  startDate.setDate(startDate.getDate() - 2);
  var formattedStartDate = Utilities.formatDate(startDate, AdsApp.currentAccount().getTimeZone(), 'EEE, MMM d, YYYY');
  startDate = Utilities.formatDate(startDate, AdsApp.currentAccount().getTimeZone(), 'YYYYMMdd');
  var endDate = new Date();
  endDate.setDate(endDate.getDate() - 1);
  var formattedEndDate = Utilities.formatDate(endDate, AdsApp.currentAccount().getTimeZone(), 'EEE, MMM d, YYYY');
  endDate = Utilities.formatDate(endDate, AdsApp.currentAccount().getTimeZone(), 'YYYYMMdd');

  var campaignFilter = config.campaignsContain.length > 0 ? ' AND CampaignName CONTAINS "' + config.campaignsContain + '" ' : '';
  var query = 'SELECT CampaignName, SearchImpressionShare, Date FROM CAMPAIGN_PERFORMANCE_REPORT WHERE CampaignStatus = ENABLED ' + campaignFilter + 'AND AdvertisingChannelType = SEARCH DURING ' + startDate + ',' + endDate;
  var report = AdsApp.report(query);
  var campaigns = {};
  var rows = report.rows();
  while (rows.hasNext()) {
    var row = rows.next();
    var campaign = row.CampaignName;
    var imprShare = parseFloat(row.SearchImpressionShare.replace('%', '')) / 100;
    var date = row.Date.replace(/-/g, '');
    if (!campaigns[campaign]) campaigns[campaign] = {};
    if (!campaigns[campaign][date]) campaigns[campaign][date] = imprShare;
  }
  
  var alerts = [];
  Object.keys(campaigns).forEach(function(campaign) {
    var difference = (campaigns[campaign][endDate] - campaigns[campaign][startDate]) / campaigns[campaign][startDate];
    campaigns[campaign].difference = difference;
    if (difference < -config.imprShareDropThreshold) {
      alerts.push('    - ' + campaign + ': from ' + (campaigns[campaign][startDate] * 100).toFixed(2) + '% to ' + (campaigns[campaign][endDate] * 100).toFixed(2) +'%');
    }
  });
  
  var message = 
      'Hello, \n\n' +
      'The following campaigns saw impression share drop by more than ' + (Math.abs(config.imprShareDropThreshold) * 100).toFixed(2) + '% between ' + formattedStartDate + ' and ' + formattedEndDate + '. \n\n' +
      alerts.join('\n') + '\n\n' +
      'Thanks,\nAcuto Scripts';
  
  if (alerts.length > 0) {
    MailApp.sendEmail(config.emails, 'Impr. Share Drop Alert!', message);
  }
}

How to Use Scripts in Google Ads

Using scripts in Google Ads is a great way to optimize your campaign and increase the efficiency of your workflow. 

Here’s a quick reminder of how to implement them:

  1. Sign in to your Google Ads account
  2. From the toolbar select the Tools and Settings drop-down menu
  3. Under the Bulk Actions list, select Scripts
  4. Click the blue + icon to create a new script.
  5. Choose whether you want to create a New script or Start from a template
  6. Enter a name for your script in the name bar
  7. Copy & paste your script code into the editor
  8. You will need to click Authorize to allow the script to run on your account
  9. At this point you can Save & Preview your script
  10. Check the logs on your preview to ensure the script will run as expected
  11. When you are ready, click Run to implement the script

What is Impression Share in Google Ads?

Impression share (IS) is a way of measuring how many times your Google ad was shown to potential customers. It takes the number of times your ad could have been displayed and compares it to the amount it was actually shown to come up with a percentage.

For example, if you had an ad that was eligible to be displayed on 1000 occasions, but it actually appeared 700 times, your impression share for this ad would be 70%.

What is a Good Impression Share Rate?

A healthy impression share rate is considered to be between 80% and 100%

While a 100% IS rate is rare, if it drops below 80%, you might want to consider using some of the tips below to optimize your campaign.

What Factors Affect Impression Share?

An impression share rate can be affected by numerous factors, including:

Budget & bid strategy

Ads with a higher budget and more bids will inevitably tend to have a better potential impression share rate.

Targeting settings & competition

Wider targeting may improve the share rate. But be aware of the other factors, such as how many other companies are competing for the same targets, because that can also limit your potential share.

Ad quality & relevance

Google’s quality score (rated 1-10) is based on your ad’s expected click-through rate (CTR) and its relevance to people who see it and click it. Higher quality scores usually result in a better IS rate.

Impression Share Drop Alert Google Ads Script

What Causes Impression Share to Drop in Google Ads?

Insufficient Budget

It is important to set a budget for your ad that aligns with the goals of your campaign. A more limited budget will lower your impression share and, ultimately, the number of conversions you can expect your campaign to generate. 

Lower budgets also mean you can’t bid as highly as other competitors, and therefore your ad may be displayed lower on the page, if at all.

Low Quality Score

As we saw earlier, Google provides a quality score rating for every ad based on how it compares to those of other advertisers on several metrics. These include the expected click-through rate (CTR), the ad relevance and the experience of users when reaching your landing page. Rated on a scale of 1-10, a low score can notably decrease your impression share.

Campaign is In Review

It should be noted that while your campaign is still under review, your ad will not be visible to potential customers, which in turn decreases your impression share. It’s important to carefully follow Google’s guidelines to ensure this process runs as smoothly as possible.

Current Ad Relevance

The algorithms Google uses aim to display the most relevant ads to each of its users. If your ad is deemed to have lower relevance, it will be shown less frequently, which will inevitably impact your overall impression share.

How to Improve Impression Share in Google Ads

If you do find your ad’s impression share has dropped below your desired level, try the following to give it a boost:

Refine Your Keyword List

By including more specific and appropriate keywords, your ad is more likely to align with a potential customer’s aims and appear in their search results. This should increase the overall visibility of the ad, the click-through rate and your impression share.

Use Negative Keywords

Likewise, identifying negative keywords that aren’t relevant to your product avoids wasting your ad spend on users who are unlikely to convert by preventing your ad from showing up for unrelated searches.

Increase Your Bids and Budget

As we touched upon earlier, budget allocation and understanding how it affects your impression share are crucial factors in maximizing the potential of your campaign. 

By allowing your ad to show up in higher ad positions and more frequently, higher daily budgets and bids will inevitably make your ad more competitive. This in turn increases its visibility.

Adjust Your Ad Targeting

Spending some time optimizing factors such as your target demographic, location and language will really help ensure your ad is being seen in the right places. By reaching more relevant people who are more likely to convert.

Improve Your Ad Copy and Creatives

The style, content and copy of your ads are also crucial for capturing the attention of potential customers. Utilizing eye-catching visuals and compelling ad copy will help make your ad stand out from the crowd.

Improve your Quality Score

Increasing the relevancy, expected click-through rate, and landing page experience of your ad will improve your ad’s quality score. This in turn makes it more likely to show up in higher positions on search result pages. 

Want to automate Google Ads with custom scripts?

If you liked this script or would like a personalized one, we’re here to help! Our team of developers with experience in PPC can create custom scripts to automate any aspect of your Google Ads accounts. Schedule a discovery call to discuss how we can assist you in implementing automation scripts effectively.

Key Takeaways

There are numerous factors to be aware of when trying to improve the impression share of your Google ad. This includes bids and budget, keywords and negative keywords, ad targeting, copy and creatives, and Google’s quality score.

You might also consider using a Google Ads alert script. Acuto’s free impression share script, for example, is a great way to stay on top of things, sending an instant alert if your impression share drops below the desired level.

Combining this script alarm with some of the tips above will ensure your campaign runs as efficiently as possible.

Recent Posts
google ads high CPC alert script

Google Ads High CPC Alert Script

Discover how Google Ads high CPC alert script can revolutionise the way marketing agencies optimise their campaigns.

pause google ads with low CTR script

Pause Google Ads with Low CTR Script

Use this free script to pause Google Ads with low CTR to help improve the efficiency of your campaign and avoid wasted ad spend.

Recent Posts