Forum Moderators: Robert Charlton & goodroi
Upgrade to HTTPS - Absolute vs. Relative Links?
This has been posted a few times, but maybe should be posted in this thread as well:
- Generic Steps to Switch from HTTP to HTTPS -
• Read all info at your host concerning certificates & switching to HTTPS and when applicable, follow those instructions.
• Install security certificate.
• Have you host enable HTTPS (if needed.) This will enable access from both HTTP & HTTPS.
• Go through site, page by page & make sure all file paths are relative (no protocol.) Test by accessing site using HTTPS and look for any browser alerts.
• Install 301 code in .htaccess fileNote: your server may require a different codeRewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
• Go through site again, page by page, and test. Any remote absolute links will need to be HTTPS including those found in scripts & pluggins. If you publish Adsence or other advertising, links in these scripts need to be HTTPS also (or just remove the protocol altogether.)
• Update sitemap.xml (if applicable) and submit to appropriate agencies (Google, Bing, Yandex, etc)
• In Google Search Council create a new site using HTTPS (do not use the Change of Address form.) It will take a few days to start populating information. This is normal & traffic to old site (HTTP) will drop off accordingly.
• Bing Webmaster Tools, Yandex & others should update automatically once they crawl your new pages. Updating/re-submitting sitemap.xml should speed up this process.
[edited by: not2easy at 8:18 pm (utc) on Jun 13, 2017]
[edit reason] Added quote from original Thread [/edit]
my web host changed all my urls to relative from absolute
[edited by: phranque at 6:34 am (utc) on Jun 7, 2017]
[edit reason] disable accidental linking [/edit]
" Go through site, page by page & make sure all file paths are relative (no protocol.) Test by accessing site using HTTPS and look for any browser alerts."I think Lucy24 explained it pretty well. Protocol is something the browser negotiates with the web server. In today's internet, it's best to not interfere in that process.
I have been working to change them back to absoluteI would advise to keep these relative.
I had them change it back from // to https:// because an SEO person told me that I should have these changed back immediately.@DChan, same advice.
[edited by: keyplyr at 9:47 pm (utc) on Jun 6, 2017]
Do you think putting the urls back to relative may clear up any problems that could be caused by the change over?No. As said earlier, the protocol (if correctly done) has nothing to do with SE ranking, so shouldn't play much of a part in sales performance. I say "shouldn't play much of a part" because by being HTTPS, some very old browsers will not display your content.
All I know is I am beginning to wish I had not changed over to HTTPS.That's only because you didn't have the correct information. Your host should have supplied that, possibly via a knowledge base.
[edited by: not2easy at 2:01 am (utc) on Jun 7, 2017]
[edit reason] cleanup splicing debris [/edit]
if they try to process the http sitemap again it will give an error if I remove it from my server?Google understands what's going on when a site is upgraded to HTTPS. If you have installed the 301 redirect properly, Google will now be served the new HTTPS sitemap.xml.
I have had a few customers contact me that they are unable to use my shopping cart properly (it is just paypal buttons, actual transaction is not performed on my site) and that the page disappears and other weird things.
submit sitemaps including both HTTP & HTTPS URLs with new change-dates (in the long run, just keep the HTTPS sitemap)IMO this is not only bad advice, but serves no purpose. The 301 will take everyone, including Googlebot, to the HTTPS sitemap.xml. Having 2 conflicting records is not a good thing. Just let Googlebot crawl the new links and be done with it.
[edited by: DChan at 3:16 am (utc) on Jun 7, 2017]