Next.js gives you the APIs. This guide tells you which ones to use, in what order, and what to check before calling it done. Organized as a checklist — work through it top to bottom.
Foundation (do first)
- Set
metadataBaseinapp/layout.tsx. Every OG image, canonical, and sitemap URL resolves against this. Without it, paths are relative and social previews break. - Add
generateMetadatato every public page. Title (55–60 chars), description (150–160 chars),alternates.canonicalpointing to itself. - Set the title template:
{ default: "Site", template: "%s | Site" }. Usetitle.absoluteon the homepage to avoid double-branding. - Create
sitemap.tswith all public routes. Tier priorities: homepage 1.0, money pages 0.8–0.9, blog 0.6–0.7. Use reallastModifieddates, notnew Date(). Once it's live, run it through the free sitemap inspector to confirm the URL count and freshness look right before you submit it to GSC. - Create
robots.ts. Disallow/api/,/dashboard,/editor/, auth routes. Point to sitemap. Not sure what to disallow, or want AI-crawler blocking presets? The free robots.txt generator builds it with a line-by-line explanation.
Structured data
- Organization JSON-LD in root layout (once, globally).
- BreadcrumbList on every non-homepage page.
- FAQPage on any page with a visible FAQ accordion.
- BlogPosting on blog posts with
datePublished,dateModified,author. - Product + Offer on pricing pages with real prices.
Open Graph images
- Create
opengraph-image.tsxin the app root. UseImageResponsewith edge runtime. 1200×630px. - Per-route OG images for money pages. Each route folder can have its own
opengraph-image.tsx. - Test with the Facebook Debugger and Twitter Card Validator.
Core Web Vitals
- Font
display: swapon all Google Fonts. images.formats: ["image/avif", "image/webp"]in next.config.- Above-fold images get
priority. Below-fold getloading="lazy". - DNS prefetch for external image domains.
- Third-party scripts use
strategy="lazyOnload".
Security headers (trust signals)
- HSTS with
includeSubDomains; preload. - X-Content-Type-Options: nosniff
- X-Frame-Options: SAMEORIGIN
- Referrer-Policy: strict-origin-when-cross-origin
- X-Robots-Tag: noindex on preview/non-canonical hosts.
Internal linking
- Header nav links to all money pages.
- Footer links to all public pages + legal pages.
- Every page has ≥3 inbound internal links.
- Blog posts cross-link to related posts.
- No
href="#"placeholder links anywhere.
Final verification
Before submitting to Google Search Console:
- Every page has a unique title and description — check truncation with the free SERP simulator before you ship it.
- Every page has exactly one
<h1>. - Every page's canonical tag points to itself, not somewhere else — verify with the free canonical URL checker.
- Sitemap returns 200 and valid XML.
- No noindex'd pages appear in the sitemap.
- Rich Results Test passes for all schema types.
- PageSpeed Insights scores green on all three Core Web Vitals.
- Run the page through a free on-page audit as a final gate — it checks the title, canonical, OG image, JSON-LD, and indexability signals above in one pass.