Migrating WordPress to Next.js without losing SEO
A redirect strategy, schema preservation plan, and gotchas I've hit on 10+ migrations.
Why SEO is the #1 migration risk
A site migration that tanks organic traffic can cost a SaaS company 6–12 months of marketing spend. I've seen it happen. Here's how to avoid it.
The pre-migration audit
Before touching any code:
1. Export all URLs from Google Search Console (last 16 months) 2. Crawl the current site with Screaming Frog 3. Export all meta titles, descriptions, and schema markup 4. Document the top 100 pages by organic traffic
The redirect map
Every old URL needs a 1:1 redirect to the new URL. Build this as a JSON/CSV file BEFORE launch.
// next.config.mjs
async redirects() {
return [
{ source: '/blog/old-slug', destination: '/writing/new-slug', permanent: true },
// ... all mappings
];
}
Schema preservation
Article, Organization, Breadcrumb schemas — all need to carry over. Use structured data testing tool to verify before launch.
Launch day checklist
- Update sitemap.xml
- Submit to Search Console
- Monitor Core Web Vitals
- Check 404 rate in Vercel analytics for 72 hours
Gotchas
- Trailing slashes: pick one convention and redirect the other
- Image URLs: if you rehost, update references in all content
- Canonical tags: don't let old and new URLs both index
On the last migration I did, we saw zero dip in organic traffic over 30 days — and a 180% increase within 90 days thanks to the performance boost.
Related articles
A practical checklist for 95+ Lighthouse
The few things that actually move LCP/CLS consistently: image strategy, font loading tactics, predictable layouts, and the small CSS choices that compound across pages.
n8n workflows that scale: retries, idempotency, alerts
Build automations like product features — observable, debuggable, safe at 2 AM.
Shipping AI assistants with guardrails & source transparency
UX patterns that make retrieval trustworthy and reduce support risk during rollout.