React + PHP - How to deploy the API files

Hello i created a litle webpage with React and made an PHP API. Everything works on my PC, but i don't understand where i should upload my PHP files. First of all, when i make a call with axios i should put the url of the API, i can't write simple localhost. Example: "" Correct? I made different Routes in react with react-router-dom and i don't understand how i should be able to access these PHP files and where to put them. They shouldn't be also private from extern? I want to upload the webpage to test it on cPanel and i got stuck with this litle detail and i can't find any youtube video and chatgpt isn't helping me.
No description
1 Reply
John Patrick Onyango
Hi, you should deploy your php api and use endpoints from the hosted api, you can deploy on vercel or render if you dont know how to setup a php server , use this article
How To Deploy PHP App On Vercel FREE - Hostwizly
Looking for tutorial on how to host php website on Vercel platform then you are at the right place in this article I will show you how to deploy php app on Vercel web hosting platform.