How to connect an iPhone app (rest) to XAMPP using a local WIFI connection?

I'm making an iPhone app communicating (REST) with a PHP web app on wordpress on my local server using XAMPP.

The problem is that I can't reach my local server with my phone whereas I use to do it using the address http://localhost:8080.

I already tried several things I found on this forum an others:

Not sure I did it in the good order or correctly, so don't think it cannot be the solution to use those solutions 🤪

I should reach my XAMPP local server on my Mac using my iPhone. I know it is possible, but I don't know really know how...

1 answer

  • answered 2019-08-17 11:47 Ahmed Nader

    If they're already on the same wifi network then you should be able to reach it through the host PC's IP Address.

    Maybe if that doesn't work try and connect the computer to a hotspot on your phone (no internet needed) and it should show you a list of connected devices with their IP addresses and you can hard code that value in your app.