2

For the SEO experts:

A long time ago, I created a website with some pages that used underscores instead of hyphens to separate words (e.g., "page_1.html"). I understand now that Google likes hyphens a lot better than underscores, so I want to change those pages (e.g., "page-1.html"). These pages already rank very well on Google, but I want to make sure they are ranking as well as possible, hence I want to make this change. (And I assume the redirects won't hurt the SEO they already have)

I know how to set up 301 directs with htaccess file, so that's not the issue. My question: once I get the 301 redirects in place, do I submit the OLD page URL to Google Search Console for re-indexing or the NEW page URL?

Also, should I delete the old page files once the redirects are in place, or keep them, or it doesn't matter?

2 Answers 2

2

Ideally at the same time when you have the .htaccess file with the 301 redirects in place:

You want to have to correct / desired / new URL in your sitemap and in the Google Search Console. The old files should no longer matter because they are effectively invisible to the outside world, provided that there are no errors in the redirect.

After your action, testing is obviously recommended.

Google search console should list the redirects of the old pages for your information. It is basically a service so that you can confirm that what you did was done on purpose.

1
  1. Use the old ones when asking Google to reindex them. That way, it will see the redirect and make a note.
  2. You don't need to keep the old ones as they will not be accessed.
  3. After a few weeks, you should request Google to remove the old ones. They will only be removed if there are no internal references to the old pages and they do not exist.
  4. If you have hundreds of pages and they don't follow a pattern, this can make .htaccess rather large and could potentially slow down the server. An alternative is to keep the old pages but replace the content with a 301 redirect. This way, only access to that page is slower, not the whole site.

A large .htaccess will slow down your website performance. An empty .htaccess will slow down your website performance (if it is used). The only thing that will not slow down your website performance is not reading .htaccess by means of setting AllowOverride None in the directory configuration. Everything that can be done in .htaccess, can be done in the main configuration of the webserver.

From Oswald on Stack Overflow

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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