Website redirects not working

I created some redirects using the _redirects file. When the build runs and completes successfully in the build logs it says that 4 redirect rules were processed without error. When I visit the URL I am not redirected. What am I doing wrong? Thanks.

Would you mind sharing your _redirects file? I’m not sure if it’s possible to guess without it.

Absolutely, here it is

/support*    https://help.carbmanager.com/               301
/signup*     https://my.carbmanager.com/                 301
/login*      https://my.carbmanager.com/account/signin   301
/forums*     https://forums.carbmanager.com/             301

You can try using force, that is 301! instead of just 301. This will force those rules.

2 Likes

that actually worked, thanks a bunch! :pray:

1 Like

@hrishikesh so I just realised that this isn’t actually resolved.

If I navigate to a page that gets redirected (I.e. /support) by clicking a button or link, then the redirect does not work. If I navigate directly to the same URL or press refresh, then the redirect works.

Any ideas?

Can I see the website?

The _redirect file is only hit when you load data from the server. If you navigate using javascript you never hit the server and thus do not trigger the redirect. You’d need to solve this client side too in this case.