• Search Engine Land
  • Sections
    • SEO
    • SEM
    • Local
    • Retail
    • Google
    • Bing
    • Social
    • Resources
    • More
    • Home
  • Follow Us
    • Follow
  • Search Engine Land
  • SEO
  • SEM
  • Local
  • Retail
  • Google
  • Bing
  • Social
  • Resources
  • Live
  • More
  • Events
    • Follow
  • SUBSCRIBE

Search Engine Land

Search Engine Land
  • SEO
  • SEM
  • Local
  • Retail
  • Google
  • Bing
  • Social
  • Resources
  • More
  • Newsletters
  • Home
SEM

How to sync your keywords and ad labels with an AdWords Script

Columnist Daniel Gilbert shares a free script to help solve labeling issues by copying labels within an ad group from ads to keywords or vice versa.

Daniel Gilbert on February 20, 2018 at 1:11 pm
  • More

The label functionality in AdWords can sometimes be a bit bewildering, and manually having to label a lot of ads or keywords is a task we wouldn’t wish on anyone.

We’ve all been there: You make a bid adjustment, label some keywords in an ad group to reflect this change, and then when looking at ads within that same ad group, you can’t see the labels. So you set about the mind-numbing chore of copying labels from entity to entity.

Because we feel your pain, my company created a script to solve your labeling issues. It will copy labels within an ad group from ads to keywords or vice versa. And best of all, it’s free!

The script

I have outlined the script code below. Copy the code below into a new blank script in the AdWords Bulk Actions area, and then change the options at the top as I’ve described here.

Script outline

Fill in label names with the names of the labels you want to be copied

Note that this is case-sensitive — type carefully!

  • copyLabelsFrom is the type of entity you’re copying labels from.
  • copyLabelsTo is the type of entity you’re copying labels to.
  • copyLabelsFrom and copyLabelsTo can be any of “Keyword” and “Ad”
  • A threshold is the proportion of entities of the type copyLabelsFrom that must be labeled for the entities of the type copyLabelsTo to be labeled.

For instance, if copyLabelsTo is “Keyword” and copyLabelsFrom is “Ad” then:

  • 1 means the keywords are only labeled if all ads are labeled.
  • 0.9 means the keywords are labeled if at least 90 percent of ads are labeled.
  • 0 means the keywords are labeled if at least one ad is labeled.

Including and excluding certain campaigns

campaignNameContains and campaignNameDoesNotContain filter which campaigns the script gets data from.

For example, if campaignNameContains is [“Brand”, “Generic”], then only campaigns with names containing “brand” or “generic” are included. If campaignNameDoesNotContain is [“Display”, “Competitor”] then any campaigns with names containing “display” or “competitor” are ignored.

This next part is not case-sensitive.

Leave campaignNameContains blank, [ ], to include all campaigns.

If you need to put a double quote into campaignNameContains or campaignNameDoesNotContain — if the campaign name itself uses quotation marks — put a backslash, \, before it.

ignorePausedCampaigns, ignorePausedAdGroups and ignorePausedAdsAndKeywords filter which entities the script looks at based on status. They should all be set to “true” if you only want to look at currently active things.

Removed things are always ignored — they’re deleted, so it’s not like you can change them!

I should mention this does not work for shopping, video or universal app campaigns.

AdWords Scripts can only run for 30 minutes. If your account is too big for the script to run, you could run it multiple times.

Use campaignNameContains and campaignNameDoesNotContain to go over different parts of the account each time.


Opinions expressed in this article are those of the guest author and not necessarily Search Engine Land. Staff authors are listed here.



About The Author

Daniel Gilbert
Daniel Gilbert is the CEO at Brainlabs, the best paid media agency in the world (self-declared). He has started and invested in a number of big data and technology startups since leaving Google in 2010.

Related Topics

Channel: SEMGoogle: Ads ScriptsPaid Search Column

We're listening.

Have something to say about this article? Share it with us on Facebook, Twitter or our LinkedIn Group.

Get the daily newsletter search marketers rely on.
See terms.

ATTEND OUR EVENTS

Lorem ipsum doler this is promo text about SMX events.

February 23, 2021: SMX Report

April 13, 2021: SMX Create

May 18-19, 2021: SMX London

June 8-9, 2021: SMX Paris

June 15-16, 2021: SMX Advanced

August 17, 2021: SMX Convert

November 9-10, 2021: SMX Next

October 2021: SMX Advanced Europe

December 17, 2021: SMX Code

Available On-Demand: SMX

×


Learn More About Our SMX Events

Discover actionable tactics that can help you overcome crucial marketing challenges. Our next conference will be held:

MarTech 2021: March 16-17

MarTech 2021: Sept. 14-15

MarTech 2020: Watch On-Demand

×

Attend MarTech - Click Here


Learn More About Our MarTech Events

White Papers

  • 6 Powerful Ways Experience Analytics Can Help Your Business Now
  • Email Tune-Up: A 5-Point Inspection to Get Your Program in Gear
  • Digital Marketing Report Q4 2020: Benchmarks and Insights for 2021
  • Data SEO – The Next Big Adventure
  • Getting Started with Email Marketing Automation
See More Whitepapers

Webinars

  • How to Avoid the Digital Transformation Trap
  • How to Build a Marketing System of Record
  • Meet BIMI: The brand-boosting email security marketers must have for 2021
See More Webinars

Research Reports

  • Local Marketing Solutions for Multi-Location Businesses
  • Enterprise Digital Asset Management Platforms
  • Identity Resolution Platforms
  • Customer Data Platforms
  • B2B Marketing Automation Platforms
  • Call Analytics Platforms
See More Research

h
Receive daily search news and analysis.
Search Engine Land
Download the Search Engine Land App on iTunes Download the Search Engine Land App on Google Play

Channels

  • SEO
  • SEM
  • Local
  • Retail
  • Google
  • Bing
  • Social

Our Events

  • SMX
  • MarTech

Resources

  • White Papers
  • Research
  • Webinars
  • Search Marketing Expo
  • MarTech Conference

About

  • About Us
  • Contact
  • Privacy
  • Marketing Opportunities
  • Staff
  • Connect With Us

Follow Us

  • Facebook
  • Twitter
  • LinkedIn
  • Newsletters
  • Instagram
  • RSS
  • Youtube
  • iOS App
  • Google Play

© 2021 Third Door Media, Inc. All rights reserved.

Your privacy means the world to us. We share your personal information only when you give us explicit permission to do so, and confirm we have your permission each time. Learn more by viewing our privacy policy.Ok