How does the www redirection of the Kirby site work?


I was just wondering how redirects to I can’t see nothing in htaccess Kirby Site.

Thank you.

The Kirby site actually uses nginx, so these rules are all in the server configuration.

For your convenience, here’s a piece of Apache .htaccess config you can use:

# Rewrite www.<domain> to <domain>
# Works for all domains dynamically and even works multiple times (www.www.www.<domain>)
RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC]
RewriteRule (.*) http://%1/$1 [R=301,L]

I think that’s automatically but i’m not Sure

Servers only do what you tell them to do. :wink:

1 Like

Yap This is Right :smiley:

@lukasbestle your htaccess solution is shorter and less complexe than the one I use :wink:
Thanks for this…

1 Like