TL;DR: HTTPS is HTTP inside a TLS connection: it encrypts the request and response, proves the server’s identity with a certificate, and detects tampering. It does not hide the server’s IP address, usually does not hide the hostname (SNI), and does not hide how much data moves and when. Use HTTPS everywhere, then add HSTS.
Side By Side
| HTTP | HTTPS | |
|---|---|---|
| Transport | Plain TCP | TLS over TCP, or QUIC for HTTP/3 |
| Default port | 80 | 443 |
| Encrypted | No | Yes (path, query, headers, cookies, body) |
| Server identity verified | No | Yes, by certificate chain and hostname match |
| Tampering by network | Possible: ads, injected scripts, rewritten downloads | Detected and rejected |
| HTTP/2 in browsers | Not supported | Required in practice (browsers only do HTTP/2 over TLS) |
| HTTP/3 | Not available | Available (HTTP/3 always uses TLS 1.3) |
| Browser features | Powerful APIs such as service workers, geolocation, camera, and Secure cookies are restricted | Available |
| Cert cost | n/a | Free certificates exist via Let’s Encrypt and others |
What TLS Adds
- Confidentiality. A passive observer on the same Wi-Fi or upstream network sees ciphertext.
- Integrity. Any modification in transit breaks the record authentication, so ISPs and hotspots cannot inject content.
- Server authentication. The certificate chain must validate to a trusted root and match the hostname, which is what stops a man-in-the-middle from impersonating the site. Failures surface as errors such as
NET::ERR_CERT_COMMON_NAME_INVALID; see ERR_CERT_COMMON_NAME_INVALID.
Here is what a plain HTTP request exposes to everyone on the path:
GET /account/settings?tab=billing HTTP/1.1
Host: shop.example.com
Cookie: session=7d3c1c2e...
On HTTPS, the observer sees only a TLS handshake to shop.example.com and then opaque records.
What HTTPS Does Not Hide
| Visible to the network | Why |
|---|---|
| Destination IP address | Packets must be routed to it |
| Hostname, in most cases | The TLS ClientHello carries it in the SNI extension in cleartext, unless ECH is used |
| DNS lookups | Separate protocol; encrypted only with DoH or DoT |
| Request and response sizes, timing, direction | Traffic analysis can distinguish pages and sometimes infer what a user did |
| That you used HTTPS at all | The handshake is recognizable |
ECH status. Encrypted Client Hello is published as RFC 9849, a Proposed Standard on the Internet Standards Track. It encrypts the inner ClientHello, including SNI, under a public key the server publishes in a DNS HTTPS record. It requires TLS 1.3, and both the client and the server or CDN must support it, with the key discovered over DNS. It also helps most when many sites share one frontend, since the IP still reveals a single-tenant server. Check your specific browser and hosting provider before telling users it is on.
Also visible at the application layer: anything a corporate TLS-inspection proxy can decrypt. Managed devices with an installed enterprise root certificate allow that proxy to read the traffic.
HSTS: Closing The First-Request Gap
Typing shop.example.com in a browser usually starts with http://, and a redirect to HTTPS happens only after that cleartext request, which is where an attacker on the network can strip or intercept. HSTS makes the browser remember to use HTTPS:
HTTP/1.1 200 OK
Strict-Transport-Security: max-age=31536000; includeSubDomains
- The header only counts when received over HTTPS; browsers ignore it on HTTP responses.
- While it is active, the browser rewrites
http://tohttps://itself and refuses to click through certificate errors for that host. - The
preloadtoken plus a submission at hstspreload.org gets the domain hardcoded into browsers, which requiresmax-ageof at least one year andincludeSubDomains. Preloading is hard to undo, so confirm every subdomain serves HTTPS first.
Details and rollout order are in Strict-Transport-Security.
Mixed Content
An HTTPS page that requests http:// subresources undermines the whole page. Browsers block active mixed content (scripts, stylesheets, iframes, fetch/XHR) and handle passive content (images, audio, video) by upgrading or warning, depending on the browser and version. A typical console message is Mixed Content: The page at 'https://...' was loaded over HTTPS, but requested an insecure script 'http://...'. This request has been blocked. The fix is to change the URL in the HTML, CSS, or database content. See Mixed content blocked for diagnosis. Content-Security-Policy: upgrade-insecure-requests is a stopgap while you clean up hardcoded URLs.
Behind a TLS-terminating proxy, apps that build absolute URLs from the incoming scheme will emit http:// links unless they trust X-Forwarded-Proto.
SEO, Stated Carefully
- Google has called HTTPS a lightweight ranking signal since 2014, and it is one of many. Moving to HTTPS is not a shortcut to rankings, and it is not harmful when done cleanly.
- What can hurt is a sloppy migration. Redirect every HTTP URL to its exact HTTPS equivalent with a 301 or 308 (see 301 vs 302), keep one canonical host, update canonicals, hreflang and sitemap URLs, and fix mixed content.
- In Search Console, HTTP and HTTPS are separate properties unless you use a Domain property.
- Redirect loops after enabling HTTPS usually come from a proxy that terminates TLS but tells the app the request was HTTP; see ERR_TOO_MANY_REDIRECTS.
Common Mistakes
Believing HTTPS makes an app secure. It protects the transport only. SQL injection, broken access control and leaked tokens are unaffected.
Serving HTTPS but leaving port 80 open without a redirect. Users who type the bare domain end on a dead or HTTP-only page.
Redirecting with 302 during migration. Use a permanent redirect so search engines consolidate on the HTTPS URL.
Cookies without Secure. A session cookie lacking Secure is also sent over any plain-HTTP request to the host, which defeats HTTPS. Pair Secure with HSTS.
Enabling includeSubDomains or preload before checking every subdomain. Forgotten internal hosts that only speak HTTP become unreachable.
Assuming a padlock means the site is trustworthy. It means the connection is encrypted to whoever holds a valid certificate for that name. Phishing sites have valid certificates too.
Expecting a CDN to fix an expired origin certificate. Depending on the SSL mode, edge-to-origin TLS can still fail with 525 or 526; see 525 SSL handshake failed.