How To Redirect Only Your Homepage

A client recently asked me how to redirect your homepage only and not any archive pages.

It took me a long while to figure it out, so for anyone else who’s searching for it, this is how it’s done. You need to add a line to the start of your website’s .htaccess file.

A 301 redirect won’t work as it will redirect the whole site, so you have to use a RedirectMatch. The code below will redirect the home page only to, but leave any other pages and archives in place for people to come to your site.

RedirectMatch ^/$

There are a couple of reasons you might want to do this, so hope it helps!

16 thoughts on “How To Redirect Only Your Homepage”

    1. Hi Nicolai! I only work with sites so I haven’t used Blogger for many years so I don’t know if the solution to that, sorry!

    1. You wouldn’t of course, that’s just an example URL. You would replace that with the site you wanted to redirect to.

Leave a Reply