Skip to main content
Marketing Agencies|SEO Specialist / Web Developer

Website Migration SEO Validation

Verify SEO elements are preserved during site migrations

Website migrations often damage search rankings when SEO elements are misconfigured. EdgeDNS validates critical SEO infrastructure to catch issues before they impact traffic.

The Challenge

Website migrations and platform changes frequently cause SEO disasters. Redirects break, canonical tags point to wrong URLs, sitemaps reference old pages, and meta tags get lost. These issues can take months to recover from and cause significant traffic and revenue loss.

The Solution

Run automated SEO validation checks against your staging environment before migration. Verify redirects resolve correctly, canonical URLs are properly set, sitemaps are accessible, and meta tags are present. Compare pre and post-migration to catch regressions.

Endpoints Used

Combine these EdgeDNS endpoints to build this solution.

GET
/v1/domain/canonicalTry in Playground

Canonical URL: Verify canonical tags point to correct URLs

GET
/v1/domain/metaTry in Playground

Meta Tags: Check title, description, and OG tags

GET
/v1/domain/sitemapTry in Playground

Sitemap: Verify sitemap is accessible and valid

GET
/v1/domain/robotsTry in Playground

Robots.txt: Check robots.txt rules and directives

GET
/v1/domain/response-timeTry in Playground

Response Time: Verify site performance post-migration

Results You Can Achieve

Prevent ranking drops

Catch SEO issues before search engines see them

Reduce migration risk

Automated validation provides confidence for go-live

Document migration state

Before/after comparison for troubleshooting

Code Example

SEO validation for website migration

javascript
async function validateMigrationSEO(urls) {
  const headers = { 'Authorization': 'Bearer YOUR_API_KEY' };
  const issues = [];

  for (const url of urls) {
    const domain = new URL(url).hostname;

    const [canonical, meta, sitemap] = await Promise.all([
      fetch(`https://api.edgedns.dev/v1/domain/canonical?url=${url}`, { headers }),
      fetch(`https://api.edgedns.dev/v1/domain/meta?url=${url}`, { headers }),
      fetch(`https://api.edgedns.dev/v1/domain/sitemap?domain=${domain}`, { headers }),
    ].map(p => p.then(r => r.json())));

    // Check canonical points to self or correct URL
    if (canonical.data.canonical && canonical.data.canonical !== url) {
      issues.push({ url, issue: `Canonical mismatch: ${canonical.data.canonical}` });
    }

    // Verify critical meta tags exist
    if (!meta.data.title) {
      issues.push({ url, issue: 'Missing title tag' });
    }
    if (!meta.data.description) {
      issues.push({ url, issue: 'Missing meta description' });
    }
  }

  // Check sitemap accessibility
  const sitemapCheck = await fetch(
    `https://api.edgedns.dev/v1/domain/sitemap?domain=${new URL(urls[0]).hostname}`, { headers }
  ).then(r => r.json());

  if (!sitemapCheck.data.accessible) {
    issues.push({ url: 'sitemap.xml', issue: 'Sitemap not accessible' });
  }

  return { passed: issues.length === 0, issues };
}

Learn More

Explore industry standards and best practices related to this use case.

Ready to build Website Migration SEO Validation?

Get started with 200 free API requests per month. No credit card required.

Other Use Cases