Write Google Ads Using Dynamic Keyword Insertion with AI

Tested prompts for ai write ads with dynamic keyword insertion compared across 5 leading AI models.

BEST BY JUDGE SCORE Claude Opus 4.7 8/10

Dynamic keyword insertion (DKI) lets Google swap a placeholder in your ad copy with the search term that triggered it. The result: ads that mirror what someone just typed, which typically lifts click-through rates by making the headline feel custom-built for that search. The syntax looks like this in a headline: {KeyWord:Default Running Shoes}. If the keyword fits, Google inserts it. If it does not fit, the fallback text appears instead.

The problem most advertisers hit is writing DKI ads that still sound natural when any keyword in the ad group gets inserted. A bad default, a headline that reads awkwardly with a long keyword, or body copy that clashes with the inserted term can make the ad worse than a static version. That is where AI helps: you feed it your keyword list, your character limits, and your offer, and it generates headline and description combinations that stay coherent regardless of which keyword drops in.

This page shows you the exact prompt to use, what four leading models produce from it, and how to judge which output is actually ready to upload to Google Ads.

When to use this

This approach works when you have a tightly themed ad group with keywords that share a common intent and roughly similar character counts. AI accelerates the process of writing multiple headline and description variants that hold up grammatically and contextually no matter which keyword Google inserts, saving hours of manual copy review.

  • Building single keyword ad groups (SKAGs) or tightly themed ad groups where every keyword fits the same offer
  • Scaling campaigns across many product categories that share the same landing page structure
  • Refreshing existing DKI ads that have stale copy or low quality scores without rebuilding from scratch
  • Testing multiple fallback text variations quickly to find which default drives the best CTR when insertion fails
  • Writing responsive search ad (RSA) headlines where some slots use DKI and others use static copy that AI can balance

When this format breaks down

  • Ad groups with keywords that span wildly different intents or character lengths, where any single headline template will read awkwardly for half the terms
  • Brand campaigns where inserting a competitor keyword accidentally would violate policy or confuse the user
  • Ads for regulated industries like pharmaceuticals or financial products where specific claims must be reviewed by compliance before any dynamic text goes live
  • Display or video campaigns where DKI is not supported and the AI output will include syntax that simply does not work in those formats

The prompt we tested

You are an expert Google Ads copywriter specializing in Dynamic Keyword Insertion (DKI). Using the product or business details below, write Google Ads that properly use the {KeyWord:default} syntax in headlines (and optionally descriptions) so ads dynamically match the searcher's query while staying grammatical and within character limits.

Rules:
Use correct Google Ads DKI syntax like {KeyWord:Fallback} with appropriate capitalization (KeyWord, Keyword, or keyword) based on context; keep every headline ≤30 characters and every description ≤90 characters including the fallback text; ensure the ad remains grammatical and compelling whether the inserted keyword is short or the fallback triggers.

Product/Business details:
We're an online running shoe retailer called PaceLab selling trail, road, and racing shoes from brands like Hoka, Nike, and Brooks. We want to run a Google Ads campaign targeting keywords such as 'trail running shoes', 'mens road running shoes', and 'lightweight racing flats'. Free shipping over $75 and 90-day returns.

Produce 3 ad variations. For each variation, output:
- 3 Headlines (max 30 characters each, at least one using {KeyWord:FallbackTerm})
- 2 Descriptions (max 90 characters each)
- Final URL path suggestion
- A brief note explaining the DKI fallback choice and how it stays grammatical when the keyword expands or triggers the fallback.

Model comparison

ModelQualityCostLatencyTokens
Claude Opus 4.7 8 $0.1085 19.3s 506 / 1346
Claude Haiku 4.5 5 $0.0051 10.1s 344 / 959
GPT-5.4 7 $0.0084 11.0s 286 / 510
Grok 4.1 Fast Reasoning 6 $0.0004 38.0s 434 / 617

Outputs

Claude Opus 4.7 8/10
# PaceLab Google Ads — DKI Variations

---

## Variation 1: Brand-Forward

**Headlines:**
1. `Shop {KeyWord:Running Shoes}` (28 chars max with fallback)
2. `Hoka, Nike & Brooks` (19 chars)
3. `Free Shipping Over $75` (22 chars)

**Descriptions:**
1. `Find your perfect {KeyWord:running shoes} at PaceLab. Free shipping $75+. Shop now.` (84 chars w/ fallback)
2. `Top brands, 90-day returns, fast delivery. Road, trail & racing shoes in stock.` (80 chars)

**Final URL path:** `/shop/running-shoes`

**DKI Note:** Fallback "Running Shoes" keeps Headline 1 at 28 characters — safely under 30. Since all target keywords (e.g., "Trail Running Shoes", "Mens Road Running Shoes") are noun phrases, "Shop [keyword]" stays grammatical either way. "Mens Road Running Shoes" = 23 chars, so "Shop Mens Road Running Shoes" = 28 chars ✅. Longer queries will trigger the fallback automatically.

---

## Variation 2: Deal-Focused

**Headlines:**
1. `{KeyWord:Racing Flats} Sale` (27 chars with fallback)
2. `Lightweight & Fast` (18 chars)
3. `90-Day Free Returns` (19 chars)

**Descriptions:**
1. `Shop {keyword:racing flats} from Hoka, Nike & Brooks. Free shipping on orders $75+.` (83 chars w/ fallback)
2. `Built for PRs. Trail, road & track-ready. Try 90 days risk-free at PaceLab.` (75 chars)

**Final URL path:** `/sale/racing`

**DKI Note:** "Racing Flats" fallback = 13 chars, making Headline 1 = 18 chars. "Trail Running Shoes Sale" = 24 chars ✅; "Mens Road Running Shoes Sale" = 28 chars ✅. Lowercase `{keyword:...}` in the description keeps it reading naturally mid-sentence. "Sale" works as a universal suffix across all product-type keywords.

---

## Variation 3: Category/Intent Match

**Headlines:**
1. `{KeyWord:Trail Shoes} In Stock` (30 chars with fallback — exact limit)
2. `Hoka, Brooks, Nike +More` (24 chars)
3. `Free Ship $75 | 90-Day` (22 chars)

**Descriptions:**
1. `Huge selection of {keyword:trail shoes}. Expert picks, real reviews, fast free shipping.` (88 chars)
2. `PaceLab stocks road, trail & racing shoes for every runner. Shop top brands today.` (82 chars)

**Final URL path:** `/collections/running`

**DKI Note:** Fallback "Trail Shoes" (11 chars) lands Headline 1 at exactly 30 characters — the tightest safe fallback. Critically, "{KeyWord} In Stock" works grammatically for every target keyword: "Trail Running Shoes In Stock" (28), "Lightweight Racing Flats In Stock" ❌ (33 — Google would truncate or swap in fallback). To be safe, Google auto-substitutes the fallback when the inserted keyword would exceed the 30-char cap, so this ad gracefully degrades to "Trail Shoes In Stock" on over-length queries.

---

### ⚠️ General DKI Safety Tip
Google Ads automatically serves the **fallback** whenever the inserted keyword would push the headline over 30 characters. Always design the fallback to be the *shortest, most generic* version of your keyword theme so the ad stays compelling if a long-tail query triggers substitution.
Judge notes: Excellent production-quality output with correct DKI syntax, accurate character counting, and smart grammatical reasoning, but Variation 3's self-identified "Lightweight Racing Flats In Stock" overflow issue (flagged but not resolved) and the "/sale/racing" URL path being misleading for a non-sale ad slightly undercut production readiness.
Claude Haiku 4.5 5/10
# PaceLab Google Ads Campaign – 3 Variations

---

## **Variation 1: Product-Focused**

**Headlines:**
1. `{KeyWord:Running Shoes}`
2. `Shop {KeyWord:Shoes} Today`
3. `Premium {KeyWord:Footwear}`

**Descriptions:**
1. `Find Hoka, Nike & Brooks {keyword:options}. Free shipping over $75. 90-day returns on all orders.`
2. `Expert-curated trail, road & racing {keyword:styles}. Fast delivery & hassle-free returns guaranteed.`

**Final URL Path Suggestion:**
`/shop/shoes?utm_source=gads&utm_content=product_focus`

**DKI Note:**
The headlines use `{KeyWord:Running Shoes}` and `{KeyWord:Shoes}` as fallbacks to keep copy under 30 characters. When searchers query "trail running shoes" or "lightweight racing flats," the keyword inserts naturally. The fallback "Running Shoes" triggers for generic or unmatched queries, keeping ads relevant. Descriptions use lowercase `{keyword:options}` and `{keyword:styles}` as plurals that grammatically work whether the keyword is singular or multi-word.

---

## **Variation 2: Benefit-Driven (Speed & Selection)**

**Headlines:**
1. `{KeyWord:Running Shoes}`
2. `Best {KeyWord:Shoes} Online`
3. `Find Your Perfect {KeyWord:Fit}`

**Descriptions:**
1. `Browse top {keyword:brands & styles}. Ships free over $75. Try risk-free for 90 days.`
2. `Expert {keyword:selection} from Nike, Hoka & Brooks. Premium quality, unbeatable prices.`

**Final URL Path Suggestion:**
`/shop?category=running&utm_source=gads&utm_content=benefit_driven`

**DKI Note:**
Headline 1 uses `{KeyWord:Running Shoes}` as a broad fallback for maximum flexibility. Headline 3 uses `{KeyWord:Fit}` (a noun) to allow searchers querying "best road running shoe fit" or "men's racing flat fit" to see their intent reflected. Descriptions use lowercase `{keyword:brands & styles}` and `{keyword:selection}` as generic plurals that remain grammatical whether a single-word or multi-word keyword inserts. This variation emphasizes trust and ease.

---

## **Variation 3: Urgency & Promotional**

**Headlines:**
1. `Save on {KeyWord:Running}`
2. `{KeyWord:Shoes} on Sale`
3. `Get {KeyWord:Gear} Fast`

**Descriptions:**
1. `Premium {keyword:running footwear} at unbeatable prices. Free shipping on $75+. 90-day guarantee.`
2. `Shop Hoka, Nike & Brooks {keyword:selections}. Limited stock—order your {keyword:pair} today!`

**Final URL Path Suggestion:**
`/shop/sale?utm_source=gads&utm_content=urgency_promo`

**DKI Note:**
Headline 1 uses `{KeyWord:Running}` as a noun-friendly fallback that works whether someone searches "trail running shoes" (inserts "trail running") or triggers the fallback "running." Headline 2 keeps keyword insertion simple with `{KeyWord:Shoes}`. Headline 3 uses `{KeyWord:Gear}` as a broad fallback for flexibility. Descriptions use lowercase `{keyword:running footwear}`, `{keyword:selections}`, and `{keyword:pair}` as flexible phrases that grammatically accommodate various keyword lengths and remain compelling even with fallback text.

---

**Campaign Strategy Tip:** Test all three variations against high-intent keywords (trail running shoes, men's road running shoes, lightweight racing flats) and monitor CTR. Variation 2 typically performs best for informational intent; Variation 3 for transactional searches with price sensitivity.
Judge notes: The output fundamentally misuses DKI syntax throughout — Google Ads does not support `{keyword:options}` or `{keyword:brands & styles}` in descriptions as substitution fields with custom fallbacks; DKI in descriptions works only as `{KeyWord:Fallback}` inserting the matched keyword, not as a replacement for arbitrary words, making most of the description DKI usage invalid and potentially confusing for any practitioner trying to deploy these ads.
GPT-5.4 7/10
Here are 3 Google Ads variations using DKI correctly and within limits.

---

## Variation 1

### Headlines
1. Shop {KeyWord:Running Shoes}  
2. Trail, Road & Racing Shoes  
3. Free Shipping Over $75  

### Descriptions
1. Find Hoka, Nike & Brooks. Fast online shopping with 90-day returns.  
2. Trail, road, and racing shoes for every run. Free shipping over $75.  

### Final URL path suggestion
`running-shoes/all`

### DKI note
Fallback is **“Running Shoes”**, which is broad, grammatical, and relevant if the user’s keyword is too long to fit. “Shop {KeyWord:Running Shoes}” reads naturally whether it inserts “trail running shoes” or falls back to “Running Shoes.”

---

## Variation 2

### Headlines
1. {KeyWord:Trail Running Shoes}  
2. Shop Hoka, Nike & Brooks  
3. 90-Day Returns Available  

### Descriptions
1. Buy trail, road & racing shoes online. Free shipping on orders over $75.  
2. Top shoes for training and race day. Easy returns within 90 days.  

### Final URL path suggestion
`running-shoes/trail-road-racing`

### DKI note
Fallback is **“Trail Running Shoes”**, which fits the 30-character headline limit and is highly aligned with campaign intent. If a longer query like “mens road running shoes” can’t fit, the fallback still makes a clean, product-specific headline.

---

## Variation 3

### Headlines
1. Buy {KeyWord:Racing Shoes}  
2. Lightweight Styles In Stock  
3. Free Shipping & Returns  

### Descriptions
1. Shop road, trail & racing shoes from PaceLab. Free shipping over $75.  
2. Discover Hoka, Nike & Brooks running shoes with 90-day returns.  

### Final URL path suggestion
`running-shoes/racing`

### DKI note
Fallback is **“Racing Shoes”**, chosen because it is concise and keeps the headline grammatical with “Buy.” For shorter queries like “lightweight racing flats,” insertion can work; if not, the fallback still reads naturally and stays compelling.

If you want, I can also create:
- a more aggressive CTR-focused set,
- a brand-heavy set featuring Hoka/Nike/Brooks,
- or a campaign/ad-group structure matched to your target keywords.
Judge notes: The DKI syntax and fallbacks are correct and well-explained, but the character limit validation is unverified (e.g., "Trail, Road & Racing Shoes" is 26 chars, fine, but no proof-of-count is shown), and the ads lack urgency/differentiators beyond generic free-shipping copy that any competitor could use, weakening PaceLab's distinctiveness.
Grok 4.1 Fast Reasoning 6/10
### Ad Variation 1
**Headlines**  
1. Shop {KeyWord:Trail Shoes} (22 chars with fallback)  
2. Hoka Nike Brooks Shoes (21 chars)  
3. Free Ship Over $75 (18 chars)  

**Descriptions**  
1. Premium trail road racing shoes from Hoka Nike Brooks. Free shipping $75+. 90-day returns. (82 chars)  
2. PaceLab: Top brands for runners. Easy online shopping. Free ship over $75 orders. (72 chars)  

**Final URL path suggestion**  
/running-shoes  

**Note**  
DKI in Headline 1 uses {KeyWord:Trail Shoes} fallback ("Trail Shoes" fits generically for running keywords). Structure "Shop [DKI]" ensures ≤28 chars even with longest keyword (e.g., "Shop Mens Road Running Shoes"); title case insertion reads naturally as imperative headline. Fallback "Shop Trail Shoes" stays compelling/grammatical for non-fits or broad matches.

### Ad Variation 2
**Headlines**  
1. {KeyWord:Road Shoes} Here (21 chars with fallback)  
2. Lightweight Racing Flats (23 chars)  
3. 90-Day Returns Guaranteed (24 chars)  

**Descriptions**  
1. Mens trail road racing shoes in stock. Hoka Nike Brooks. Free shipping over $75. 90-day returns. (85 chars)  
2. Find your perfect pair at PaceLab. Top brands free ship $75+. Hassle-free 90-day returns. (78 chars)  

**Final URL path suggestion**  
/road-running-shoes  

**Note**  
DKI in Headline 1 uses {KeyWord:Road Shoes} fallback ("Road Shoes" suits road/trail/racing queries). " [DKI] Here" totals ≤27 chars max (e.g., "Mens Road Running Shoes Here"); flows grammatically as call-to-action. Fallback triggers cleanly for mismatches, keeping "Road Shoes Here" punchy/relevant.

### Ad Variation 3
**Headlines**  
1. Buy {KeyWord:Racing Flats} (24 chars with fallback)  
2. Trail & Road Shoes Sale (21 chars)  
3. Free Shipping $75+ Now (21 chars)  

**Descriptions**  
1. Shop PaceLab for Hoka Nike Brooks. Trail road racing flats. Free ship over $75 + 90-day returns. (84 chars)  
2. Best running shoes online. Free shipping orders $75+. 90-day return policy on all brands. (76 chars)  

**Final URL path suggestion**  
/racing-flats  

**Note**  
DKI in Headline 1 uses {KeyWord:Racing Flats} fallback ("Racing Flats" targets speed-focused searches broadly). "Buy [DKI]" ≤27 chars max (e.g., "Buy Lightweight Racing Flats"); imperative phrasing grammatical in title case. Fallback ensures "Buy Racing Flats" motivates purchases seamlessly if keyword expands beyond limits.
Judge notes: The character count claims are demonstrably wrong in several cases (e.g., "Shop Mens Road Running Shoes" is 28 chars but the full DKI token "{KeyWord:Trail Shoes}" itself counts differently, and "Mens Road Running Shoes Here" exceeds 30 characters), undermining the core technical accuracy that DKI ads require, and the descriptions/headlines are generic rather than differentiated across variations.

What makes these work

  1. 01
    Give AI your full keyword list

    Do not just describe the ad group theme. Paste the actual keywords into the prompt. The AI can then check that each headline stays under the character limit when the longest keyword is inserted, and flag any terms that will always trigger the fallback. This one step eliminates most character-count errors before upload.

  2. 02
    Specify the fallback text explicitly

    The fallback is what runs when a keyword is too long or triggers a policy filter. If you leave it up to the AI, it will invent one. Tell it exactly what fallback you want, then ask the model to confirm every headline reads naturally with that fallback. A weak fallback can tank impression share on high-volume broad terms.

  3. 03
    Ask for a character-count audit in the same prompt

    Append a line like: 'After writing the headlines, list the character count for each headline using the fallback text and again using the longest keyword.' This turns the AI into a quick pre-flight checker and catches limit violations without you manually counting in the Google Ads interface.

  4. 04
    Keep descriptions static or semi-static

    DKI in descriptions is allowed but often backfires because a raw keyword phrase mid-sentence reads unnaturally. Use AI to write descriptions that are specific to the ad group theme without needing insertion, then let the headlines do the dynamic work. This also gives Google Ads more predictable copy to score for relevance.

More example scenarios

#01 · E-commerce: running shoes ad group
Input
Write 3 Google Ads RSA headlines using dynamic keyword insertion for a running shoes ad group. Keywords include: mens trail running shoes, lightweight running shoes, cushioned running shoes. Character limit 30 per headline. Fallback text: Running Shoes. The offer is free shipping over $75 and a 30-day return policy.
Expected output
Headline 1: {KeyWord:Running Shoes} – Free Ship $75+ | Headline 2: Shop {KeyWord:Top Running Shoes} Today | Headline 3: {KeyWord:Running Shoes} | 30-Day Returns. Each headline stays under 30 characters with the fallback and only slightly exceeds it with the longest keyword, flagging it for review.
#02 · B2B SaaS: project management software
Input
Write 2 RSA headlines and 1 description using DKI for a B2B project management SaaS. Keywords: agile project management software, team task management tool, project tracking software. Fallback: Project Management Software. USP: 14-day free trial, no credit card required. Headlines max 30 chars, description max 90 chars.
Expected output
Headline 1: {KeyWord:Project Management Tool} Free Trial | Headline 2: Try {KeyWord:Project Software} 14 Days Free | Description: Manage tasks, deadlines, and team workloads in one place. Start your free 14-day trial, no credit card needed.
#03 · Local services: HVAC repair
Input
Write Google Ads headlines with DKI for a local HVAC company targeting: AC repair near me, emergency AC repair, same day AC repair. Fallback: AC Repair. Tone: urgent and trustworthy. Max 30 chars per headline. Include a call to action.
Expected output
Headline 1: {KeyWord:AC Repair} – Call Now 24/7 | Headline 2: Fast {KeyWord:AC Repair} Same Day | Headline 3: Licensed {KeyWord:AC Repair} Experts. The fallback keeps each under 30 characters. The word 'Licensed' in H3 adds trust without relying on the inserted keyword.
#04 · Legal services: personal injury law firm
Input
Write DKI Google Ads for a personal injury law firm. Keywords: car accident lawyer, truck accident attorney, slip and fall lawyer. Fallback: Personal Injury Lawyer. Headline limit 30 chars. Description limit 90 chars. Key message: free consultation, no fee unless you win.
Expected output
Headline 1: {KeyWord:Injury Lawyer} – Free Consult | Headline 2: No Fee Unless You Win | Description: Injured? Our {KeyWord:personal injury lawyers} fight for maximum compensation. Free consultation, zero fees unless we win your case.
#05 · Online education: certification courses
Input
Generate 3 RSA headlines with DKI for an online certification platform. Keywords: PMP certification course, Google Analytics certification, AWS certification training. Fallback: Online Certification. Emphasize self-paced learning and job-ready skills. 30 char headline limit.
Expected output
Headline 1: {KeyWord:Online Certification} – Self-Paced | Headline 2: Get Job-Ready: {KeyWord:Certification} | Headline 3: {KeyWord:Online Cert} Starts Today. Note: 'Starts Today' adds urgency that works with any inserted keyword, and the fallback for H3 at 18 chars gives Google flexibility to insert most keyword variants.

Common mistakes to avoid

  • Using DKI in every headline slot

    Google recommends mixing DKI headlines with static ones in RSAs. If every slot uses insertion, the ad loses the brand voice and benefit-driven messaging that convinces someone to click. AI-generated ads that stuff DKI into all 15 headlines will underperform because there is no anchor message.

  • Ignoring Title Case vs. Sentence case

    The DKI syntax controls capitalization: {keyword} gives lowercase, {Keyword} capitalizes the first word, {KeyWord} title-cases each word. Asking AI for help without specifying which format you want means the model may mix them across headlines, creating inconsistent ad styling that looks unprofessional in search results.

  • Not testing the fallback at scale

    Advertisers focus on whether the inserted keyword looks good and forget that on broad or phrase match, the fallback fires more often than expected. If the fallback text is generic, those impressions get a weaker ad. Always preview the ad with just the fallback text before launching.

  • Mixing unrelated keywords in one DKI ad group

    DKI only improves relevance when the keywords share the same intent and landing page. Putting 'running shoes' and 'hiking boots' in the same ad group with one DKI template produces ads that insert the right keyword but lead to the wrong page. AI will write the ad correctly but cannot fix a flawed campaign structure.

  • Skipping policy review for sensitive categories

    Google restricts DKI for certain industries including finance, healthcare, and adult content. An AI-generated DKI ad for a payday loan or prescription drug keyword may pass the AI's output check but get disapproved immediately at the ad level. Verify category restrictions before building the prompt.

Related queries

Frequently asked questions

Can AI write the DKI syntax correctly or do I need to edit it manually?

Most major models understand DKI bracket syntax when you explain it in the prompt or show a single example. GPT-4, Claude, and Gemini all produce {KeyWord:Fallback} formatting reliably if you include the format in your instructions. Still spot-check every bracket before uploading, since a missing colon or wrong capitalization breaks the feature silently.

Does dynamic keyword insertion work with responsive search ads?

Yes. You can use DKI in any headline slot of an RSA. Google recommends using it in no more than one or two of your 15 headline slots and combining it with benefit-focused static headlines. AI is particularly useful here because it can generate the full set of 15 headlines in one pass, mixing DKI and static copy in the right ratio.

What is the character limit for DKI headlines in Google Ads?

Google Ads headlines are capped at 30 characters. The character count is measured against the inserted keyword, not the fallback. So if your fallback is 18 characters but your longest keyword is 34 characters, Google will use the fallback for that keyword. Always give AI your longest keyword so it can flag which terms will always fall back.

Is it better to use AI for DKI ads or just write them manually?

For a single ad group with five keywords, manual is fast enough. AI becomes worth it at scale: when you have 20 or more ad groups that each need DKI headlines, descriptions, and fallback text, AI can produce a full set in minutes. The real value is the consistency check, making sure every combination reads naturally before you upload.

Will Google penalize me for using DKI in every headline?

Google will not penalize you directly, but its ad strength rating will likely score the ad lower because headline variety is reduced. More practically, ads with only DKI headlines tend to underperform because there is no static message communicating your offer or brand. Google's own guidance recommends treating DKI as one ingredient, not the whole recipe.

How do I handle keywords that are too long for DKI insertion?

Any keyword over 30 characters for a headline slot automatically triggers the fallback text. When building your prompt, tell the AI which keywords exceed the limit and ask it to write a fallback that still feels relevant to those long terms. You can also create a separate ad group for the long-tail terms with a static headline tailored to them.

Try it with a real tool

Run this prompt in one of these tools. Affiliate links help keep Gridlyx free.