All posts

Why won’t my .dev domain load without HTTPS?

·1 min read

You register a .dev domain, open it for the first time, and the browser refuses to connect. Your server is fine. That’s how this top-level domain works.

What is HSTS preload?

Browsers ship with a list of domains that may only be loaded over HTTPS: the HSTS preload list. The entire .dev TLD is on it, and so is .app. In practice http://example.dev doesn’t exist: the browser rewrites the address to https:// before any request leaves your machine. Look up your own domain on hstspreload.org and you’ll see it’s covered through the TLD.

Without a valid certificate the page won’t load, and visitors don’t get a “proceed anyway” option. The HSTS standard requires browsers to fail such connections with no user recourse (RFC 6797).

Fixing it on Hostinger

On Hostinger’s web hosting plans, a free SSL certificate is installed automatically for every domain and subdomain you add. If it isn’t, installing it by hand is quick (Hostinger docs):

  1. In hPanel, open your site’s dashboard and go to Security → SSL.
  2. Pick the domain and click Install SSL.
  3. The status turns “Active” within a few minutes. Subdomains (blog., demo. and so on) fall under the same rule, so check that each one has an active certificate.
  4. Test the site in a private window.

Redirect HTTP anyway

Browsers switch to HTTPS on their own, but tools like curl and some bots don’t. Adding this rule to .htaccess is a good habit:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

In short: on .dev, SSL isn’t optional. The upside is that your site is served securely from day one without any extra setup.

Thinking about something similar?

Approval flows, Microsoft 365 and Power Automate automation, ERP and e-invoice integrations, and company websites for small businesses.

Tell me about it