Bookmarks

HTTPS — HTTPS

HTTP Secure

A way of carrying HTTP inside a protected TLS connection: pages and API requests are encrypted and verified along the whole path from client to server.

Also: secure HTTP, HTTP over TLS, HTTP over TLS

checked 9 Nov

All terms

HTTPS is ordinary HTTP wrapped in an encrypted TLS channel. Almost the whole modern web works this way: browsers treat a secure context as a precondition for powerful platform features, and an intermediary between client and server can neither read the data nor alter it unnoticed.

How it works

The client starts the TLS handshake: it sends a ClientHello and agrees the protocol version and ciphers with the server. The server presents a certificate issued by a certificate authority, and the client checks that the domain name in the address matches the one in the certificate and verifies the chain of trust — without this check an intermediary could pose as the server. After the handshake, ordinary HTTP requests and responses travel inside the channel: the transport changes, not the protocol itself.

  • Confidentiality: only the client and the server can read the traffic; an intermediary sees just the server’s address and the volume of data.
  • Integrity: any change to the data in transit breaks the cryptographic check and is detected.
  • Server authenticity: the certificate binds the domain to the key with which the server signs the handshake.

How HTTPS differs from HTTP

URL schemeDefault portChannel
http://80plain text, no protection
https://443TLS: encryption, integrity, server authenticity

The specification fixed the practice of using a separate port for protected traffic back in May 2000: RFC 2818 described how HTTP over SSL, the predecessor of TLS, was already used. Secure and insecure content must not be mixed on one HTTPS page: browsers upgrade images, video and audio from HTTP to HTTPS on their own, and block scripts and other requests made over HTTP. A server can reinforce this with the Strict-Transport-Security header, which forbids the browser to visit the domain over HTTP or to click through certificate errors.

Where HTTPS is required

Browsers treat pages loaded over HTTPS as a secure context: only they can use service workers, geolocation, camera access through getUserMedia and dozens of other platform features. Newer versions of HTTP itself also depend on encryption: HTTP/2 is rarely seen without TLS — upgrading to it through the Upgrade: h2c header is deprecated, leaving only a connection to a server known in advance — and HTTP/3 is built on QUIC, where TLS 1.3 is part of connection setup.

Sources

the term is written from these pages

Verified 9 Nov

Not to be confused with

what it is mixed up with and how it differs

  • TLSTLS protocol

    TLS is the protection protocol itself; HTTPS is just the case where HTTP runs over TLS, and TLS also protects email and other protocols.

  • HTTPHTTP

    HTTP sends data as plain text; HTTPS is the same protocol inside an encrypted TLS channel, on port 443 by default.

  • SSHSSH protocol

    SSH encrypts remote access to servers and tunnels; HTTPS covers the transfer of web pages and API requests.

In depth in the references

where the topic is covered in detail