From 6b72b57184bf3a5a7d8918f5cc8f7a66806ef8a6 Mon Sep 17 00:00:00 2001 From: Alex Assistant Date: Thu, 19 Feb 2026 17:59:00 +0300 Subject: [PATCH] Add .htaccess redirects to HTTPS and non-www --- .htaccess | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 .htaccess diff --git a/.htaccess b/.htaccess new file mode 100644 index 0000000..144290c --- /dev/null +++ b/.htaccess @@ -0,0 +1,9 @@ +RewriteEngine On + +# Force HTTPS +RewriteCond %{SERVER_PORT} !^443$ +RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L] + +# Force non-www +RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC] +RewriteRule ^ https://%1%{REQUEST_URI} [R=301,L]