Support Forums

Calling API from react does not work when hosted on Netlify

I have developed a Web-App using react. During development when I make API calls by adding a “proxy” server, it works. API works fine. But when I deployed it on Netlify App. it says “Route not found”. And instead of calling the API route, the client app is using its own API. Like my server is hosted on www.myserver.com/api/get_data. We need to call this API. But my client app is calling www.client.com/api/get_data. How to solve this! I know this may be a little confusing. But I need your help.

hi there, i think we would need to see some code or a live site to really assist with this - can you provide a but more information, please?