Here's how to write meta descriptions that get clicks: give each page a unique, plain-language summary of what that specific page offers. Put the most useful concrete detail first (a price, a date, a result, a format), and match the wording to the query the page is meant to rank for. Google doesn't set a character limit, but it truncates snippets to fit the device, so the first sentence has to work on its own.
That's the short version. The rest of this guide covers what Google actually says about snippets, why it rewrites some descriptions, how to control snippets, templates for common page types, programmatic generation for large sites, and how to audit and measure the results in Search Console.
What Google says about meta descriptions
Google's snippet documentation is the primary source, and a few lines from it shape everything else:
- Snippets come mainly from page content. Google says snippets "are primarily created from the page content itself", picking the text most relevant to each search. The same page can show different snippets for different queries.
- The meta description is used when it's better. Google "sometimes uses the meta description HTML element" when it gives a more accurate description than the on-page text.
- There's no length limit. "There's no limit on how long a meta description can be", but the displayed snippet is truncated as needed, "typically to fit the device width".
- Descriptions should be unique. Google discourages repeating the same description across many pages. Use a site-level description on the home page and aggregation pages, and page-specific descriptions elsewhere.
- Programmatic generation is fine. Large database-driven sites can generate descriptions automatically, as long as they read naturally and differ from page to page. Strings of keywords "are less likely to be displayed as a snippet".
Notice what's missing: Google doesn't say meta descriptions are a ranking factor, and nothing in the documentation suggests they are. Their job is to earn the click once you already rank.
Why Google rewrites meta descriptions
Google doesn't publish a list of rewrite triggers, but its documentation and examples point to clear patterns. A description is likely to be replaced when it:
| Problem | Example | Fix |
|---|---|---|
| Doesn't match the query | A pricing page description that only talks about "our mission" | Describe what's on the page, not the brand story |
| Is a keyword list | "Sewing supplies, yarn, colored pencils, sewing machines" | Write a sentence a person would say |
| Is duplicated across pages | Every article uses the site tagline | Generate per-page descriptions |
| Is too thin | "Mechanical pencil." | Add specifics: material, size, price, use |
| Is outdated | Shows last year's price or a discontinued offer | Generate from live data |
| Covers only part of a long page | A guide with 12 sections, description covers 1 | Summarise the page's main purpose |
Because snippets are query-dependent, a rewrite for one query isn't a failure. A broad page that ranks for hundreds of queries will get different snippets for many of them. What you control is whether the description is the best summary for the page's primary query.
How to write meta descriptions: a simple formula
For most pages, three parts are enough:
- What this page is or does, in the searcher's words.
- One concrete detail or proof: a number, price, date, format, scope or constraint.
- What they get by clicking: the outcome, the next step, or what makes this page different.
Rules that follow from Google's guidance:
- Front-load the useful part. You can't control exactly where truncation happens, so the first sentence should stand alone.
- Use the primary query naturally. Google picks the snippet text that best matches each search, so a description written in the searcher's own wording has a better chance of being used. Once is enough.
- Be specific, not superlative. "Covers 14 templates and a Next.js example" beats "the ultimate guide".
- Don't promise what the page doesn't deliver. A click followed by a quick return to the results page doesn't help anyone.
Meta description length: think in pixels, not characters
Snippet truncation is based on display width, not a fixed character count, and the width depends on the device and font. That's why "155 characters" rules from SEO tools never line up perfectly with what you see. Those figures are heuristics from tool vendors, not Google limits.
A practical approach:
- Aim for one or two sentences, roughly the length of a short tweet.
- Make sure the core message fits before the likely truncation point by previewing it in a SERP preview tool.
- Don't pad a description to hit a number, and don't cut useful detail just to stay under one.
Our SEO meta generator drafts title and description pairs you can preview and then edit by hand.
Meta description templates for every page type
Templates keep descriptions consistent across a site without making them identical. Fill the bracketed parts from real page data.
| Page type | Template | Example |
|---|---|---|
| Product | [Brand] [product] with [key feature]. [Price], [stock]. [Shipping/returns]. | Northpeak Trail Runner 4 with a waterproof Gore-Tex upper. $129.00, in stock. Free 2-day shipping and 60-day returns. |
| Category | Shop [count] [category] from [brands/price range]. Filter by [attributes]. [Offer]. | Shop 84 trail running shoes from 9 brands, $69–$219. Filter by drop, width and waterproofing. Free returns. |
| Article / guide | [Answer or outcome in one line]. Covers [scope], with [format detail]. | How to rotate API keys without downtime. Covers AWS, GCP and Azure, with scripts and a rollback plan. |
| Tool page | Free [tool] that [does what] in [time/steps]. No sign-up. [Output/limits]. | Free keyword density checker for any URL or pasted text. No sign-up. Flags overused and underused keywords in seconds. |
| Local business | [Service] in [area] since [year]. [Hours/availability]. [Proof]. [Call to action]. | Emergency plumbing in North Austin since 2009. Open 24/7, licensed and insured. Call for a same-day visit. |
| Comparison | [A] vs [B]: [the deciding difference]. Compares [criteria] with [evidence]. | Postgres vs MySQL for SaaS: which handles JSON and multi-tenancy better. Compares features, tooling and costs. |
Two notes on these:
- Numbers must be live. If you put a price, count or date in a template, generate it from the same data the page renders. Stale numbers are one of the easiest ways to get a description ignored, and they mislead users.
- Local descriptions should include what people check before calling: area served, hours, and whether you're open now.
Generating meta descriptions programmatically
For a site with thousands of product, listing or documentation pages, hand-writing descriptions doesn't scale. Google explicitly allows programmatic descriptions, as long as they read naturally and vary by page. If you're choosing a platform for this, our roundup of programmatic SEO software compares the options.
A description builder (TypeScript)
Keep the logic in one pure function so you can unit-test it. This one builds a product description from structured data and trims at a word boundary:
type Product = {
name: string
brand: string
price: number
currency: string
inStock: boolean
keyFeature?: string
shipping?: string
}
// Cut at a word boundary so the description never ends mid-word.
export function clip(text: string, max = 160): string {
const clean = text.replace(/\s+/g, ' ').trim()
if (clean.length <= max) return clean
const cut = clean.slice(0, max)
return cut.slice(0, cut.lastIndexOf(' ')).replace(/[,;:.\s-]+$/, '') + '…'
}
export function productDescription(p: Product): string {
const price = new Intl.NumberFormat('en-US', { style: 'currency', currency: p.currency }).format(p.price)
const sentences = [
`${p.brand} ${p.name}${p.keyFeature ? ` with ${p.keyFeature}` : ''}`,
`${price}, ${p.inStock ? 'in stock' : 'currently out of stock'}`,
p.shipping,
].filter(Boolean)
return clip(sentences.join('. ') + '.')
}
The output for two products:
Northpeak Trail Runner 4 with a waterproof Gore-Tex upper. $129.00, in stock. Free 2-day shipping and 60-day returns.
Northpeak Socks 3-pack. $18.50, currently out of stock.
The 160-character cap in clip is a safety net against runaway text, not a target. The description should be complete well before it.
Wiring it into Next.js generateMetadata
In the Next.js App Router, generateMetadata returns a Metadata object, and its description field renders as <meta name="description">. In current versions, params is a Promise:
// app/products/[slug]/page.tsx
import type { Metadata } from 'next'
import { getProduct } from '@/lib/products'
import { productDescription } from '@/lib/describe'
type Props = { params: Promise<{ slug: string }> }
export async function generateMetadata({ params }: Props): Promise<Metadata> {
const { slug } = await params
const product = await getProduct(slug)
return {
title: `${product.brand} ${product.name}`,
description: product.seoDescription ?? productDescription(product),
}
}
export default async function Page({ params }: Props) {
const { slug } = await params
const product = await getProduct(slug)
return <h1>{product.name}</h1>
}
Three details from the Next.js docs that matter here:
- Manual overrides win. The
product.seoDescription ??pattern lets editors hand-write descriptions for top pages while everything else falls back to the generator. - Fetches are memoized.
fetchcalls with the same data are shared betweengenerateMetadataand the page, so you don't pay twice. If you use a database client instead offetch, wrap the loader in React'scache. - Metadata can stream. Since Next.js 15.2, metadata from
generateMetadatacan be streamed and appended to<body>for bots that execute JavaScript (Next.js says it has verified Googlebot handles this). For HTML-limited bots, detected by user agent, it waits and puts the tags in<head>. If you run a crawler-based audit, check which user agent it sends, because results can differ.
How to audit missing, duplicate and rewritten descriptions
Find missing and duplicate descriptions
This script reads a sitemap, fetches each URL and flags missing, duplicate, unusually short or unusually long descriptions. The 70 and 300 character thresholds are review flags, not Google rules; adjust them.
import sys
import xml.etree.ElementTree as ET
from collections import defaultdict
from concurrent.futures import ThreadPoolExecutor
import requests
from bs4 import BeautifulSoup
UA = {"User-Agent": "Mozilla/5.0 (compatible; meta-audit/1.0)"}
NS = {"sm": "http://www.sitemaps.org/schemas/sitemap/0.9"}
def sitemap_urls(sitemap_url: str, limit: int) -> list[str]:
root = ET.fromstring(requests.get(sitemap_url, headers=UA, timeout=20).content)
return [loc.text.strip() for loc in root.findall(".//sm:loc", NS)][:limit]
def meta_description(url: str) -> tuple[str, str | None]:
try:
soup = BeautifulSoup(requests.get(url, headers=UA, timeout=20).text, "html.parser")
except requests.RequestException:
return url, None
tags = soup.find_all("meta", attrs={"name": lambda v: v and v.lower() == "description"})
if len(tags) > 1:
print(f"MULTIPLE {url} ({len(tags)} description tags)")
return url, (tags[0].get("content") or "").strip() if tags else ""
if __name__ == "__main__":
urls = sitemap_urls(sys.argv[1], int(sys.argv[2]) if len(sys.argv) > 2 else 200)
with ThreadPoolExecutor(max_workers=8) as pool:
results = list(pool.map(meta_description, urls))
by_text = defaultdict(list)
for url, desc in results:
if desc is None:
print(f"ERROR {url}")
elif not desc:
print(f"MISSING {url}")
else:
by_text[desc.lower()].append(url)
if len(desc) < 70:
print(f"SHORT {url} ({len(desc)} chars)")
elif len(desc) > 300:
print(f"LONG {url} ({len(desc)} chars)")
for desc, pages in by_text.items():
if len(pages) > 1:
print(f"DUPLICATE x{len(pages)}: {desc[:70]!r}")
for page in pages:
print(f" {page}")
print(f"checked {len(results)} URLs")
pip install requests beautifulsoup4
python3 audit_meta.py https://example.com/sitemap.xml 500
It only reads a flat urlset sitemap; for a sitemap index, run it once per child sitemap. Keep concurrency low on sites you don't own.
Check which descriptions Google actually shows
Search Console doesn't report snippet rewrites. To spot-check them:
- In the Performance report, filter to one page and open the Queries tab.
- Take the top three queries by impressions.
- Search each one (signed out, in your target country) and compare the snippet to your meta description.
- Log the result: used as-is, partially used, or replaced with page text.
If your description is replaced for the page's main query, rewrite it to answer that query more directly. If it's replaced only for secondary queries, that's usually fine.
Snippet controls: nosnippet, max-snippet and data-nosnippet
Google's robots meta tag documentation defines three controls:
<!-- No text snippet at all -->
<meta name="robots" content="nosnippet">
<!-- Cap snippet length; 0 = no snippet, -1 = let Google decide -->
<meta name="robots" content="max-snippet:120">
<!-- Keep one part of the page out of snippets -->
<p>Plan details: <span data-nosnippet>internal reference code 4471-B</span></p>
data-nosnippetonly works onspan,divandsectionelements, and the HTML has to be valid.- The same rules apply to AI features:
nosnippetalso stops content from being used as direct input for AI Overviews and AI Mode, andmax-snippetlimits how much can be used.
That last point is a real trade-off. Blocking snippets to force users to click can also remove you from AI answers. Our AI Overviews ranking guide covers that visibility in more detail.
Measuring meta description CTR in Search Console
Click-through rate depends heavily on position, so a raw before/after CTR comparison is misleading if rankings moved too. A cleaner method:
- Pick pages with stable rankings. In Search Console, filter to the page and check that average position for its top queries barely moved over the last four weeks.
- Record the change date. Change the description and request indexing with the URL Inspection tool.
- Wait for recrawl. Confirm the new description appears in results before you start measuring.
- Compare like with like. Use comparison mode for equal-length periods before and after, filtered to the same page and the same top queries.
- Check position first. If average position changed noticeably, the CTR comparison isn't telling you about the description.
For whole template changes (all product pages, for example), compare the changed group against a similar group you left alone over the same dates. That controls for seasonality and SERP layout changes. If clicks fall while impressions and position hold, look at the results page itself: AI answers and other features can reduce clicks whatever your description says. Our zero-click search strategy guide covers that case, and our free rank checking guide shows how to pull position data per query.
Frequently Asked Questions
How long should a meta description be?
Google says there's no length limit, but it truncates snippets to fit the device width. Write one or two sentences, make sure the first sentence carries the main message, and preview it. Character counts from SEO tools, usually around 150–160, are approximations of pixel width, not Google rules.
Do meta descriptions affect rankings?
Google's documentation presents meta descriptions as a way to influence the snippet shown in results, not as a ranking signal. Their value is in click-through rate: a clear, specific description can earn more clicks from the same position.
Why does Google ignore my meta description?
Usually because it doesn't match the query as well as text on the page does, or because it's generic, duplicated, a keyword list, too short or out of date. Snippets are query-dependent, so Google may use your description for one query and page text for another.
Should every page have a unique meta description?
Google recommends unique descriptions for each page, with site-level descriptions on the home page and aggregation pages. If you can't cover every URL, prioritise your most important and most visited pages, and generate the rest from page data.
Can I use AI to write meta descriptions?
Yes, as long as you review the output. Feed the model the page's actual content and primary query, ask for a specific one-to-two-sentence summary, and check every number and claim against the page. Google's guidance is about the result being accurate and human-readable, not how it was drafted.
Does nosnippet stop my page from appearing in AI Overviews?
According to Google's robots meta tag documentation, nosnippet prevents the content from being used as direct input for AI Overviews and AI Mode, and max-snippet limits how much can be used. Weigh that before using either just to control the text in a regular snippet.
Conclusion
Learning how to write meta descriptions is mostly about specificity. Summarise what this page offers, lead with a concrete detail, use the searcher's wording, and keep any numbers live. Generate descriptions from real data on large sites, with manual overrides for the pages that matter most. Then audit for missing and duplicate tags, spot-check which snippets Google actually shows, and measure CTR only on pages whose rankings held steady.