I did a search and could not find an answer on here to my question. What I am confused about is what URLs on an https
page need to be https
, as opposed to http
.
I am making a series of pages my website that must be accessed over https
. At the top of the pages is a menu. I accidentally included a style sheet into the page using http
, instead of https
, and all the browsers I tried gave me a warning about insecure content. But, I can leave the menu links at the top of the page http
, and there's no problem.
So, am I correct in saying that things that are being loaded onto the page, such as style sheets and images, need to have https
in the link, but that plain old href
links can just have http
in them?
Thanks for your advice.
It's not necessary but it is more secure to use both. If you want to ensure your internet access is secure and private, use HTTPS and a VPN. HTTPS gives you end-to-end encryption, and a VPN encrypts data from your computer to the VPN server.
Fortunately, there are two quick checks to help you be certain: Look at the uniform resource locator (URL) of the website. A secure URL should begin with “https” rather than “http.” The “s” in “https” stands for secure, which indicates that the site is using a Secure Sockets Layer (SSL) Certificate.
Simply put, any website that requires login credentials or involves financial transactions should use HTTPS to ensure the security of users, transactions and data.
To use HTTPS with your domain name, you need a SSL or TLS certificate installed on your website. Your web host (Web Hosting Provider) may offer HTTPS security or you can request a SSL/TLS certificate from Certificate Authorities and install it yourself. SSL/TLS certificates may need to be renewed periodically.
Generally your secure pages such as purchase page, credit card etc processing pages are set to https
or sometimes all pages such as websites for banks or other financial institutes or even login pages.
You can leave it to browser to deciper http
or https
part by using what is called protocol-relative URLS in which you simply do not specify either of http
or https
and still browser will be able to figure it out. An example:
//example.com
//google.com
Let's say your domain is foo.com
, you would specify all URLs like:
//foo.com/page1.html
//foo.com/otherpage
So you simply leave the http
or https
part in your URLs.
To know more about protocol-relative URLS, see:
Yes, all links that are used to create the page itself (the HTML, the CSS, JavaScript, the images) need to be served over https
. That means all URLs of that domain need to be served over https
.
Links to other websites can be http
just fine. You may want to check if those links can be visited over https
as well because then the user will use a secure connection to visit those website as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With