Page 1 of 1

SEO

Posted: Fri Nov 11, 2022 9:38 am
by colin1661music
Hi Everyone,

I recently started working with an SEO company who offered to help us get our WYSIWYG designed website further up the search engines.

One of the problems they said was that google sees 3 urls for the home page.

https://www.yourdomain.co.uk
www.yourdomain.co.uk
https://www.yourdomain.co.uk/index.php

They suggested we use the following .htaccess file, I’m not how much this has improved our ranking but at least google only sees one url now.

ErrorDocument 404 /index.php
RewriteEngine on
RewriteCond %{HTTP_HOST} ^yourdomain.co.uk$ [NC]
RewriteRule (.*) https://www.yourdomain.co.uk/$1 [R=301,L]
RewriteCond %{THE_REQUEST} ^GET.*index\.php [NC]
RewriteRule (.?)index\.php/(.*) /$1$2 [R=301,NE,L]
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Re: SEO

Posted: Fri Nov 11, 2022 12:23 pm
by wwonderfull
colin1661music wrote: Fri Nov 11, 2022 9:38 am I recently started working with an SEO company who offered to help us get our WYSIWYG designed website further up the search engines.
One of the problems they said was that google sees 3 urls for the home page.
https://www.yourdomain.co.uk
www.yourdomain.co.uk
https://www.yourdomain.co.uk/index.php
They suggested we use the following .htaccess file, I’m not how much this has improved our ranking but at least google only sees one url now.
From my perspective this is an off-topic question and should belong to that thread.

It is ironic that an SEO company who offered to help you get your WYSIWYG designed website further up the search engines could not figure this simple SEO issue which is called canonical url. I also practice SEO tactics myself. From my understanding it may be canonical url issue there.

See more about it in here:
https://support.google.com/webmasters/a ... 0canonical

We seo optimized our website too by clicking here or below

Re: SEO

Posted: Fri Nov 11, 2022 12:33 pm
by BaconFries
From my perspective this is an off-topic question and should belong to that thread
Perhaps, but in this instance it is being offered as a tip on how to setup a .htacess and not a question on the use of such.

Re: SEO

Posted: Fri Nov 11, 2022 1:29 pm
by wwonderfull
BaconFries wrote: Fri Nov 11, 2022 12:33 pm
From my perspective this is an off-topic question and should belong to that thread
Perhaps, but in this instance, it is being offered as a tip on how to setup a .htacess and not a question on the use of such.
True, I reconsider it. Thank you for the guidance @Bacon.

Re: SEO

Posted: Fri Nov 11, 2022 1:33 pm
by wwonderfull
There are posts in this forum where canonical page has been discussed along with htaccess. The codes you have provided we cannot verify the use of it as it was given by the seo agency of yours. Remember to use any code in .htaccess with caution.

See some of these posts for some indication
https://wp-mix.com/canonical-www-htaccess/
http://wysiwygwebbuilder.com/forum/view ... =canonical
https://www.wysiwygwebbuilder.com/forum ... hp?t=94333
http://wysiwygwebbuilder.com/forum/view ... =canonical

Re: SEO

Posted: Fri Nov 11, 2022 10:31 pm
by alan_sh
Well, I wouldn't send an error document to the index page.

But then, I don't understand what the other lines do anyway :D :D