Analytics Folders PPC Hero

3 Easy AdWords Scripts to Analyze Your Account: Part 1

AdWords Scripts are an oft-neglected feature for most of us in PPC.  They’re squirreled away in the Bulk Operations interface, they require copious amounts of Javascript know-how to make, and can be incredibly intimidating for the coding novices among us.  Luckily for us, the Internet (and Google in particular) is full of brilliant people capable of creating custom scripts that you can plug and play in to your account without hassle.

The examples provided today are primarily concerned with fast and easy account analysis, but scripts are far more than just a resource for simple metric breakdowns.  You can parameterize your ads with them, make scripts to dynamically alter ad copy based on a countdown (“three days left”, etc.), or even automatically alter your bids based on a weather forecast.  I urge you to do some more exploring on your own, and see what you can find.

Update:  For a more visual approach to AdWords Scripts, you can watch a video on script implementation by PPC Hero’s own Sam Owen here.  Happy viewing!

So how do you implement them?

It’s simple.  Go to the “Bulk operations” link on the left-hand side of the AdWords interface, then select either of the “Scripts” links you’ll find on that page, like so:

Scripts 1

I bet you didn’t even know this was here.

You’ll then find yourself in the main AdWords Script management interface.  You can manage or edit your existing scripts, or click the “+ Create script” button to start the process of inserting a new snippet of code in to your account.

Click the highlighted button to create a new script.

Click the highlighted button to create a new script.

You’ll then be taken to a new page with a field to input your script.  Some codes will require your express authorization to run, but you’ll be notified beforehand if that’s the case.  You also have the option of previewing your code before saving it to the account, giving you the option to proactively troubleshoot your code before going live.

Insert code here.

Insert code here.

Some of the scripts I’m about to show you require more setup than others – like saving a seed document to your Google Drive that you can then populate with data that the script pulls from your account.  Make sure you follow the directions closely to make the most of these codes.

If this all sounds terribly complex, stay tuned tomorrow as Sam Owen will provide you with a charmingly British video walkthrough of AdWords script implementation.

1.  Ad Performance Review

This is one of the sample codes provided by the Google tutorial on scripts – it sends you a basic Ad Performance Report containing CTR statistics for your Headline and Destination URL, as well as a raw count of how many instances of each Headline and Destination URL are found in your selected account.

Paste the code found on this page in to the field generated when you hit the “+Create script” button – but be sure to add in your email address rather than the dummy one in the code.

You’ll then receive a link to the newly-generated document in your Google Drive containing the Ad Performance Review.

Script 2

This tab gives a breakdown of CTR by Headline. You’ll also find the same breakdown for CTR by Destination URL and a count of ads using each Headline/URL.

With a little coding know-how, you could easily edit this report to contain more information regarding Description Lines 1 and 2, along with some conversion metrics – providing a comprehensive, easily digestible Ad Performance Report that you can generate in a matter of minutes.

2.  Keyword Performance Report

This is another handy script from the Google scripts tutorial.  It provides you with a quick breakdown of keyword statistics segmented by both Quality Score and Average Position.  It allows you to swiftly examine CTR, Cost, and Count of Keywords based on position and Quality Score.  Again, you’ll want to modify the “Recipient Email” field so that the report is emailed to you correctly.  This is the result:

A script-generated Keyword Performance Report.  We've added a few extra things to this one.

A script-generated Keyword Performance Report. We’ve added a few extra metrics to this one.

We’ve added a little extra spice to this script, modifying the code to provide Conversions and Conversion Rate.  As it turns out, having a Javascript-coding wunderkind on staff has many unforeseen benefits.  As Ferris Bueller once said:  It is so choice.  If you have the means, I highly recommend picking one up.

That being said, you can also achieve this through the use of Pivot Tables on an ordinary Keyword report.  This just automates the process while providing some added graphs to help with your analysis.

3.  Quality Score Tracker

This one comes from Martin Roettgerding at PPC Epiphany – it’s a script designed to track Quality Score over time for a selected portion of your keywords.  It takes a little bit more time to set up, so here’s the process (also found at the above link):

Update (2/1/13):  Martin continues to astound with a new Quality Score Tracker script – this time allowing you to easily select which keywords you’d like to track via AdWords Labels.  This greatly simplifies the implementation process, so I urge you to check it out!

  • Log in to your AdWords account and open this spreadsheet.
  • Select “File” and then “Make a copy…” renaming it to whatever you prefer, then saving it to your account.  This copy is now yours, and is not publicly accessible.  Make a note of the new URL for this document, as you’ll need it later.
  • Paste the script found here in to the “+Create script” field.
  • Paste the URL of your copied document where it says “INSERT_SPREADSHEET_URL_HERE”.  Update the email if you’d like to get notifications for when this report is run.

Now for the fun part:  select your top 100 – 150 keywords based on your KPIs, and paste the Campaign, Ad Group, and Keyword information in to the first tab of your copied spreadsheet.  These are the keywords you’ll be tracking with the script.

Then, you should be ready to run the script.  Here’s the result:

Quality Score being tracked over time.  Niiiiice.

Quality Score being tracked over time.  Nice.

The real power behind this script is the capability to run these reports on a scheduled basis, providing you the opportunity to diagnose Quality Score issues almost as soon as they occur.  A note, however:  The above script takes quite a while to execute, depending on the amount of keywords you’ve selected.  In our experience, the 120 keywords used in the above report gives the script a run time of about eight minutes.

So that’s that.  These little snippets of code can be an incredibly powerful tool that’s often overlooked, so take some time to educate yourself on what you may be missing.  If you’re having trouble getting these scripts up and running in your own account, stay tuned for tomorrow’s update from Sam Owen – he’ll demonstrate via video the processes outlined above.

Have you found any other innovative uses for AdWords Scripts?  Will coding cause your eyes to glaze over like it does for me?  Let us know in the comments and, as always, thanks for reading!

Automation Toolkit

  • http://twitter.com/GnosisArts Gnosis Media Group

    Great stuff, Eric!

    • EricCouch

      Thanks!

  • Marco

    wow! thanks for info. very useful indeed.

    • EricCouch

      Thanks for the compliment, and thanks for reading! They’re super helpful, and something we’ll be exploring at PPC Hero in the future.

  • Rajesh Magar

    Of course Great article as always. But now I am more curious for tomorrows “Sam Owen” walk-through tutorial to learn from the beginning how to implement AdWords script.

    • EricCouch

      Thanks! He’ll have it up later today!

  • Maria Yesufu

    We’ve been experimenting quite some time with scripts and have used all the above tutorials. The quality score tracker was the most important as we wanted to monitor our changes in quality score whilst the SEO department were undertaking some landing page optimisations. At that point historic quality score wasn’t available! The only problem we found was that the script tool itself is still quite buggy, as is Google docs which a lot of the scripts use. We are still experimenting so hopefully these kinks will be ironed out soon!

    • EricCouch

      I definitely agree with you on some of the kinks, but seeing some of the results – and possibilities – makes the experimentation worth it, I think. Thanks for reading!

  • Joe

    Great stuff! Thanks for sharing! Do you know how to write the script to include the following KPIs as well? I’m looking to add these to the Ad Performance Review and the Keyword Performance Report. I’ve tried hacking my way through, but I don’t have much experience with scripts.

    - Conversions (1-per-click)
    -Total Conversion Value
    - Conversions Value/Cost

    • EricCouch

      Personally? No clue. I might be able to goad our coding whiz-kid in to sharing his secret in Part 3, though. Thanks for reading!

      • Joe

        Cool – I hope so! I’ll keep an eye out for it.

  • http://twitter.com/bloomarty Martin Röttgerding

    Hi Eric,
    just wanted to say thanks for the mention that has brought many visitors to my little blog :)

    Have a great weekend!
    Martin

    • EricCouch

      Martin,

      That’s great, and totally deserved! The original script was stellar, and the new version utilizing labels is ingenius – I’ve included an updated link to it, so I hope everyone reading will find it as well. Thanks for sharing your outstanding work!

  • Christian

    I was able to edit the script and get the conversion data in there, if anyone needs it ping me. godsnombre@gmail.com

  • http://twitter.com/just_myx Michelle Rubio

    Good stuff! Will run the script on our campaigns as well.

  • http://www.baldguywebdesign.com/ Pete

    Great read!

  • http://twitter.com/Optmyzr optmyzr.com

    Google not storing historical QS data is a pain point because you don’t know how QS evolves over time. Running scripts is a great idea but using an API based solution is easier and can give you more insight!

  • http://www.safeharbor.com/ Dmitry M

    Great read Eric!

    I am getting an error for the Ad Performance Review script:

    Invalid argument: url (line 42)

    Any ideas?

    • EricCouch

      I double-checked with our Scripts guru, Jake: it looks like that line pertains to the URL generated for the spreadsheet report. Did you try to customize that URL at all? Also, make sure your URL is enclosed in ” ” on both sides, and ends with a ; after the closing quotation mark.

    • David

      I’m getting the same error here. Should I be modifying the values in line 42 in any way?

  • phillip

    Just dropping by to say hello. I love PPC Hero and everyone at Hanapin. You guys have been really helpful in my quest to master Adwords.

    • EricCouch

      And hello to you too! Thank you for the incredibly kind words!

  • Kevin Hill

    The QS report is a great tool. I’ve been using version 2.0 for a while but now I’m getting a “Not completed: Script runtime error” everytime it runs and the spreadsheet is no longer capturing new data. Seems the google doc has reached it’s limit. Anyone know a way around that? I tried recreating the script hoping it would create a new spreadsheet, but that didn’t work. I also tried creating a new spreadsheet and dropping it’s url into the label description but that didn’t do anything either. Any suggestions would be appreciated!

  • Tim Rowley

    That’s brilliant. I look forward to trying them

  • ronmartin05

    One of the best Google Adwords tips I ever got, from a guy named Simon, was to include a solid mix of the three (four including modified) match types, with the correct proportions of broad, phrase, and exact within each ad group. Most people that get started on PPC don’t think to do things that way. If you want to talk to Simon, you can call him at 256-398-3835.