One template + a database = hundreds of landing pages and free traffic on autopilot.
Most websites have a fixed number of pages — homepage, about, pricing, blog. Programmatic SEO is different. You build one template and generate a unique page for every row in a database.
Real examples
• Zillow: "[city] homes for sale" — one page per city, 30,000+ pages
• TripAdvisor: "Best [type] in [city]" — millions of pages
• G2: "[Tool A] vs [Tool B]" — every comparison exists
• Glassdoor: "[Job title] salary in [city]" — endless permutations
Each page targets one specific long-tail keyword. None of them get tons of traffic individually. Together, they get millions.
The whole strategy hinges on finding a search pattern with two parts: a template phrase and a variable.
Best [tool] for [use case]
Best CRM for freelancers · Best CRM for startups · Best CRM for agencies
[city] [activity] guide
Lyon coffee guide · Paris wine guide · NYC bookstore guide
[A] vs [B]
Notion vs Coda · Airtable vs Notion · Linear vs Jira
How to [task] in [tool]
How to add a column in Notion · How to invite users to Linear
Tip: Use Google's "People also ask" box and Reddit threads to find patterns people actually search for. Don't guess — research.
Each page needs real, unique content — not just "[city]" swapped in. The data lives in your database, a CSV, or an API.
Public datasets
Wikipedia, OpenStreetMap, government data, Kaggle. Free and rich. Great for cities, countries, products, jobs.
Manual research
You research 20-50 entries by hand to seed quality. Slower but the best for niche topics.
AI-generated + verified
Use AI to generate first drafts, then manually verify every page. Faster than manual but still high quality.
User-contributed
Users add entries themselves (like Yelp). The flywheel kicks in once you have 100+ pages.
Third-party APIs
Stripe, Crunchbase, Hunter, Apollo. Pay for data, save time. Best for B2B niches.
In Next.js, this is a single dynamic route file. Every URL matches the pattern, every page renders from your data.
The structure
app/[city]/coffee-guide/ page.tsx → /lyon/coffee-guide /paris/coffee-guide /nyc/coffee-guide
One file. Hundreds of URLs. Each one fetches its city's data and renders the same template with that data.
BUILD A pSEO TEMPLATE
"Build a programmatic SEO route in my Next.js app. Pattern: /[city]/coffee-guide. The page should: (1) accept a city slug as a param, (2) fetch coffee shop data for that city from my Supabase coffee_shops table, (3) render a long-form guide with a hero, intro paragraph, list of 10-15 shops with descriptions, FAQ, and a CTA. Use generateStaticParams to pre-render every city. Add unique meta tags, OG image, and JSON-LD structured data per city."
You generated 500 pages. Google doesn't know they exist. The fix: a dynamic sitemap that lists every URL.
In Next.js:
DYNAMIC SITEMAP
"Update my sitemap so it automatically includes every one of my auto-generated pages. Look at my coffee shops data, get the list of cities, and add a /[city]/coffee-guide entry for each one. Use the date each city was last updated so Google knows when the page changed, and mark these pages as updated weekly."
Bad pSEO is spam. Good pSEO ranks for years. The difference is whether each page is genuinely useful. Five quality checks:
Unique data per page
Every page has at least 60% unique content. The template is the same; the meat is different.
200+ words minimum
Below 150 words and Google considers it "thin content." Aim for 400-800.
Real-world value
Could a real person actually use this page? If you wouldn't share it on Twitter, don't publish it.
Internal links
Link from each page to related pages (other cities, related topics). Builds the network.
No duplicate titles
Each page's <title> tag must be unique. "Coffee in [city]" is fine if [city] is always different.
Pages are all almost identical
Add more unique data per page. Pull richer info from your sources, or write 2-3 unique sentences per page.
Build takes forever (5 min+)
You're using generateStaticParams for 10,000+ pages. Switch to dynamic rendering with ISR (revalidate every hour).
Google indexes 50 pages then stops
Crawl budget exhausted. Improve internal linking and submit the sitemap directly in Search Console.
Pages get indexed but rank for nothing
Your keyword pattern has no search volume. Use Ubersuggest or Ahrefs to verify before scaling up.
You have a travel SaaS and want to capture searches like 'best things to do in Lyon' or 'Paris weekend itinerary'. Manually writing 200 city guides would take months. With programmatic SEO, you scrape OpenStreetMap and Wikipedia for each city, store the data in Supabase, and build one Next.js template that renders all 200 pages — each with unique content, photos, and meta tags.
Build this with AI
"I want to build programmatic SEO city guides for my travel app. Pattern: /city/[slug] (e.g., /city/lyon, /city/paris). For each city, pull data from my cities table in Supabase (name, country, population, top 10 attractions, best season to visit, average daily budget). Build the page template with: hero image, intro, attractions list with descriptions, when-to-visit section, budget breakdown, FAQ, and a CTA to my main app. Add dynamic OG images, unique meta tags per city, and include all 200 cities in my sitemap.xml."
COMPARISON PAGES
"Build comparison pages for my app at /vs/[tool-a]/[tool-b]. For each pair, fetch both tools' data (name, pricing, features) from my Supabase tools table and render a side-by-side comparison table, pros and cons, verdict, and a CTA. Generate every possible pair from my 20 tools. That's 380 pages."
JSON-LD STRUCTURED DATA
"Add structured data (JSON-LD) to my programmatic pages. For each city guide, include schema.org Place, FAQPage, and BreadcrumbList. This helps Google show rich snippets in search results."
ANALYTICS PER PAGE
"Add page-level analytics tracking so I can see which programmatic pages are getting traffic. Use Vercel Analytics or PostHog. Tag each page with the city/topic so I can filter and find the winners worth doubling down on."