1

I'm migrating a busy web-shop (10'000 IPs/day) to OpenCart, manually copying all the products, tags, descriptions and architecture.

The old website was not built following semantics standards, no h1 tags, alt tags are not filled, etc.

In the new website this is fixed. The text content doesn't change much.

The issue: The URLs on the current website look like this:

https://www.example.com/Some-Category-p/Product-Name.htm

The old CMS added the -p to all of the categories. On the new website, the links look like this:

https://www.example.com/Some-Category/Product-Name.htm

What steps (perhaps some checklist) should I take, not to be penalized by Google once I update to OpenCart and re-register the sitemap?

1

Take each of the URLs and add them as 301 (permanent) redirects to the new URLs.

So accessing Some-Category-p/Product-Name.htm redirects to /Some-Category/Product-Name.htm with a 301 code.

There's 3 reasons for this:

  1. Maintains parity with links.
  2. Google will eventually rewrite with the new URL but while it doesn't, the old one will still work.
  3. It should be standard practice when you're moving content to new URLs. This will be good practice!
|improve this answer|||||
1

Just to add to Yhorian's answer... it's relatively trivial to implement such a redirect. For example, if using Apache's mod_rewrite in .htaccess then it's essentially a one-liner. Something like:

RewriteEngine On
RewriteRule ^([\w-]+)-p/(.*) /$1/$2 [R=301,L]

This specifically works on a URL of the form /Some-Category-p/Product-Name.htm. The regex might need to be adjusted depending on the URL structure.

The ([\w-]+) part captures "Some-Category" and (.*) captures "Product-Name.htm" (everything after the first slash). These are then available in the $1 and $2 backreferences respectively, which is reassembled in the substitution (/$1/$2).

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.