What Are AdWords Scripts?
AdWords scripts are pieces of code that you can use to assist with running your AdWords account.
Many of us that run AdWords accounts are not programmers, and scripts can seem a bit daunting. But the reality is that they don’t have to be.
You can still get a lot of value from AdWords scripts with little to no programming skills. If you don’t want to write your own scripts you can easily utilise many of the prewritten scripts being given away for free. You can also make small tweaks to them to suit your own needs.
No coding required
I want to stress here, that you don’t need to know how to code if you follow this resource, it’s as easy as copy-pasting pre-written scripts into your own account and you can an immense amount of value from running these scripts
Some examples of what you can use scripts for are:
- Alerts – Alert you when a campaign spends too much money
- Custom Reports
- Automation – Set bid changes for certain times of the day
3 Great scripts I 💗
I’m going to walk you through 3 examples of scripts I use all the time. One of them is provided by Google and the other 2 I have adapted from other resources and changed to make them better for my use. I will be sharing these with you for free. In the below sections, these are:
- Link Checker Script
- Experiment reporting script
- AdWords Audit script
How to access them in the new Google Ads interface
Within the new AdWords interface, click on the spanner in the top right. Under the bulk actions menu, select ‘scripts’. This brings you to the scripts IDE where you can begin writing your new script, or copy paste a prewritten script into the editor.
For those of you running an MCC, scripts can also be added at the MCC level under the same menu: bulk operations > scripts. The advantage or running a script at the MCC level is that it can run across all your accounts, saving even more time. This is especially effective if you want to check for errors across all your client accounts.
Resources for scripts
There are a number of great resources for free scripts on the web. Google has a resource section for writing your own scripts. Which includes an IDE complete with prewritten snippets.
Freeadwordsscripts.com is also a great resource with hundreds of scripts.
1. Link Checker Script
As the name implies this script iterates through all of the links within the account and checks whether any of the landing pages are 404 errors. The script will check, ads, extensions and keywords and print to a Google doc a list of errors.
The script was developed by Google and it is provided in 2 versions. Link checker – single account. This is for anyone that wants to run this in a regular AdWords account. And Link Checker – Manager Account, this version runs in an MCC account, it can be set to only check associated accounts with a certain label on them
The user can decide how often to run the script. They can also decide to receive an alert email every time this script runs. I generally set it to run once per week and send me an email. That way I have a chance to review any broken links across all my AdWords accounts weekly. You would be surprised how often 404 errors occur. I can pick up on these quickly and save my clients quite a bit of money.
Below is a print of how the results look inside a Google sheet. There is detail all the way down to keywords and sitelinks, so it is easy to quickly rectify any issues.
How do I implement this?
This script is incredibly easy to implement. Simply follow the links above to the Google developer site. The source code is provided on that page, copy it and paste it into the scripts section in AdWords, authorize the script and run it. You should always preview the script first. Once you have run the script it will provide a link to the logs as to where you can access the google sheet with your printed results.
Everyone should be using this script. Even if you are running a 3-page website, chances are you are not checking it every day, this script will check it for you and email you a summary of results weekly to your inbox. Even more so if you are managing multiple clients or an e-commerce site with 1000’s of product pages. If you haven’t set up this script, go and implement it today!
2. Experiments Reporting Script – Making reporting easier!
The Drafts & Experiments Scripts can be downloaded here:
I love Drafts and Experiments, I think it is one of the best features and also one of the most underused features in Google Ads. Although it’s a fantastic feature, the weakest part of this tool is the analysis and reporting it provides. Luckily for us, we can fix this using Google Ads Scripts. At One Egg we’ve adapted a script to allow us to report better on campaign experiments and make it even easier to analyse results.
The script we’ve built upon was originally developed by Karooya Technologies Pvt. Ltd. We’ve improved the script by adding in revenue and ROI figures to make it relevant to clients that want to track revenue and ROI performance from experiments, which is I’m sure, a whole lot of you out there!
Reporting limitations within the interface
In the script we’ve adapted essentially exports the results of campaign trials and experiments over a period of time and outputs the data into a Google sheet. Currently, when we look at the results of experiments we see the following within the interface:
This is great and very clear but there are a few things that can be better:
- I can only view 1 the results of 1 experiment at a time, I cannot compare or group more than 1.
- There is no information on revenue or ROI, I have to use the KPIs found here.
- There is no way to make any notes
To be fair, on point #2, we can see Revenue figures below the table, but only for the experiment, we can’t see a comparison of the original vs the experiment.
A better way to report, analyse and record results
Enter, AdWords scripts. The script we’ve adapted resolves these three problems. It runs in the account and then exports the results to a Google sheet that looks like this:
Firstly, we can see all the 5 experiments we are running at a glance. This allows us to group similar ones together. I often run a few experiments testing ad copy and then others testing bids, so I can group these together. Furthermore, I can see the total results for all my experiments. That is great because I can get an overview of whether I am receiving more revenue in aggregate from all the experiments I’ve run vs the base campaigns.
Secondly, now I can see revenue figures from experiments! I can make decisions based on whether the experiment or the original has a higher ROI. This was never possible before.
Thirdly, I can write notes next to my experiments, as I did in the screenshot. This gives me an ongoing record as to what I’ve tested, implemented and rolled back and when I made these decisions on an ongoing basis.
Although it is a better way to report, there are currently two limitations to this reporting framework.
Firstly, it doesn’t include the statistical significance symbols that you automatically get within AdWords. I found this useful, so I miss them a bit. But again remember that they only work for the metrics that AdWords show you, so you wouldn’t have these symbols with revenue figures in any case.
Secondly, in the AdWords interface, no matter what date range was set, the report only compared the original to the experiment in the times they were both running. Meaning that the data for the original was only displayed for times the experiment was running and not before or after. In the script version, the data from the original campaign is reported even before the experiment period. Since you often have multiple experiments running at the same time you are likely to have more data for the original than the experiment. Ideally, it would be better to compare the 2 original and experiment only during times they both ran.
These are current limitations which we will look into improving.
3. AdWords Account Audit Script
I spend a lot of my time auditing accounts. Whether that’s a new potential client that I am putting a quote together or an existing client, with a regular account review. Auditing is highly repetitive and much of the work can be automated. These scripts automate the repetitive parts of the audit process. It will probably cut your audit time down by at least half.
I must first give credit Russ Savage who developed the initial script on FreeAdWordsScripts.com. We’ve taken the original script and adapted it. The original script audited features of the account, we have expanded it to audit more aspects of the account and made it more relevant for our audit process.
First download the script below
You simply need to copy/paste it into the scripts section of your Adwords account. You don’t actually need to run this script, simply preview it and in the logs section, it will provide you with a link to a google sheet with your printed audit. (you will need to authorise the script and provide it access to your account).
Before previewing or running the script, you should edit the target location and the excluded location. These are found in lines 35 and 39 respectively:
The script covers the following aspects of an account, it gives a quantities results for the number of campaigns. The script should be used as a starting point for further investigation:
- Campaigns with incorrect location targeting
- We set the location targeting within the script and then the script looks at whether the campaigns are matching that target location
- Campaigns set to ‘Display & Search’
- This setting is not recommended, we check if any of the campaigns use it
- Campaigns without bid modifiers for devices
- If no bid modifiers, we can recommend using them
- AdGroups with too many keywords (more then 25)
- 25 can be adjusted, this is a general rule
- Adgrooups with too many or few ads (more or less then 3)
- 3 is a general rule, which can be adjusted, its recommended to run 3 ads.
- Count of match types.
- Campaigns with no conversions.
- If there are a large number of campaigns with no conversions, it’s likely conversion tracking is not working properly
- Campaigns without extensions
- Campaigns without time scheduling setup
- Campaigns without Audience bid modifiers
- Spend inside & outside target location
- This is based on the target location set inside the script (same as point 1 above). The script will sum the amount of money spent on users located inside target location. If you set your target location to Australia, the script will show you how much money spent on users located outside of Australia.
The following is a print of the output you will be provided in your Google Sheet after the script has run:
The script shouldn’t be used as a full account audit. Rather it should be used as a launch ad for your audit. It provides insight into aspects of the account that should be checked further. Just because there are few conversions, doesn’t mean conversion tracking is not implemented, it should be investigated. Furthermore, the audit is only auditing the quantitative aspects of the account. It’s important to look at qualitative aspects as well, such as the quality of ad copy or the way the account is structured around products.