HTTPS and TLS done right — a practical configuration guide | Scanthra

Scanthra · 8 min read · Updated May 2026

May 2026
TL;DR: HTTPS itself is free and easy in 2026 (Let's Encrypt + your hosting panel's one click). The interesting part is what comes after: forcing HTTPS via HSTS, picking modern protocols and ciphers, auto-renewing the certificate, and not silently breaking old browsers in ways that matter. This guide gives you a known-good baseline you can copy verbatim.

Why "we have HTTPS" usually isn't enough

A site that loads on HTTPS but also still responds on plain HTTP — or uses TLS 1.0, an expired cert, or weak ciphers — is the equivalent of a deadbolt on a door that's been left ajar. Every modern security questionnaire, browser warning, and compliance regime (GDPR Art. 32, NIS2 Art. 21(2)(h), PCI DSS 4.0) treats TLS hygiene as a baseline, not an extra.

The five things to get right

1. A valid, modern certificate

Free, automated, trusted by every browser: Let's Encrypt. Most hosting panels (cPanel, Plesk, DirectAdmin, ISPmanager) ship a one-click installer. For VPS users, certbot or acme.sh renew every 60 days automatically. Pick RSA-2048 or ECDSA P-256 — both are fine.

2. HTTPS only — no HTTP, no mixed content

Every plain-HTTP request should redirect to HTTPS with a 301 (not 302 — search engines treat them differently). Mixed content (HTTPS page loading an HTTP image or script) silently breaks the security guarantee — most browsers block it but some legacy embeds get through. Audit with the browser dev tools' "Security" tab.

3. HSTS — tell the browser to remember HTTPS

Without HSTS, every first visit still includes a plain-HTTP request that can be intercepted. The fix is one HTTP response header:

Strict-Transport-Security: max-age=31536000; includeSubDomains; preload

4. Modern protocols and ciphers

Disable SSLv3, TLS 1.0 and TLS 1.1 — they have known weaknesses and no modern client needs them. Enable TLS 1.2 and TLS 1.3.

For nginx (Mozilla "intermediate" baseline, generated from ssl-config.mozilla.org):

ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384;
ssl_prefer_server_ciphers off;

For Apache:

SSLProtocol -all +TLSv1.2 +TLSv1.3
SSLCipherSuite ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305
SSLHonorCipherOrder off

5. OCSP stapling and HTTP/2

OCSP stapling lets your server include the cert's revocation status in the TLS handshake, avoiding a separate (slow, sometimes failing) call from the browser to the CA.

ssl_stapling on;
ssl_stapling_verify on;

HTTP/2 isn't a security feature per se, but most modern security checkers count its absence as a sign of an outdated stack:

listen 443 ssl http2;

Cloudflare-only shortcut

If your origin sits behind Cloudflare, most of the above is one toggle:

Renewal — the boring thing that bites you

The single most common TLS incident is "certificate expired on a Sunday morning, nobody noticed, customers couldn't reach the site for six hours". Two defences:

How to verify your setup

Common gotchas

How Scanthra detects TLS issues

Our SSL/TLS module checks: cert validity and expiry, protocol versions supported, HSTS presence and policy, certificate chain trust, and a few common misconfigurations. Findings appear in the report with severity, plain-English explanation and a copy-paste fix — same shape as in this article.

Want to know if your site has this issue?

Scanthra runs a friendly, passive check and emails you a plain-English PDF report.

Scan your site free