React app nav not working after deploy

I have successfully deployed and published a react app. When I go to my browser to view it at the index loads the home page correctly but none of the navigation works. When I try to navigate to using the on page navigation or typing url directly, it results in a 404 page not found error. Everything works as expected locally. I made no significant changes to file structure given by create-react-app when initially building the site. Any help is appreciated.

Have you created a _redirects or [[redirects]] in the .toml. Whereby you setup /* to /index.html 200! so that all requests without a static route in your zipped build will return a 200 so that your client side routing can do its thing.

You can search for issues others have already solved on the forum:

Thanks @AaronP. I was not familiar with the need for the _redirects file. Had tried searching for similar issues but without knowing exactly what I was looking for it was hard to find relevant issues. Site is now working as expected!

1 Like

Happy to hear! Have a good day :blush: