Custom domain doesn't show because of stale 301 redirect


I’ve converted my wordpress blog to gatsby which I’m hosting on netlify at

I already had a domain ( and I asked the hosting company (lowesthosting) to sort out the forwarding. They did that with the following .htaccess file:

RewriteEngine on
RewriteBase /
RewriteRule (.*)$1 [R=301,L]

…This forwarded users ok, but it left ‘’ in the address bar. Lowesthosting weren’t able to offer a satisfactory solution to this.

So I did some research and have now set things up successfully by setting up the custom domain in netlify, copying across all the DNS records, and pointing the lowesthosting nameservers at the netlify ones.

So this seems to work perfectly now (i.e. type in and you get the gatsby site and see ‘’ in the address bar). BUT in my own browser I still see - I guess the 301 is cached. Of course, i can clear my browser’s cache, but the point is that any visitors who visited in that period when the 301 was in force (i.e. before I configured the netlify DNS etc.) will see ‘’ …forever?! (I don’t know much about redirects, but I understand you can put an expiry on 301s - unfortunately the lowesthosting person didn’t!)

This stackoverflow post mentions setting a redirect right back, in the hope (?) that a browser will see the circular redirects and invalidate their own cached redirect. But I’d greatly appreciate the insight of any netlify experts in case there is something else I can do - or indeed if they are able to confirm or deny that this redirect-back idea will work and won’t break anything else!

@getzg Welcome to the Netlify community.

Have you tried setting up a redirect instruction along these lines?* 301!


@gregraven thank you so much! Following your suggestion it appears I have fixed it as follows (in case it helps anyone else one day…):

I set up such a redirect in my netlify.toml:

  from = "*"
  to = ""
  status = 301
  force = true

Got a brief error in my browser (think it was ‘too many redirects’) before it sorted itself and now it works consistently fine (no errors). I presume users with cached redirect will have the same experience.

Thanks again!