Search code examples
phpandroiddatabasehost

free host for database


I send my android application data in a table in localhost using phpmyadmin. but when I use my app in an actual device, clearly the data can't be inserted to the localhost table because I don't have a valid IP address. what should I do to have a temporarily valid IP without changing anything? (I used php code to receive my app's data to save in database)


Solution

  • Use an http tunnel like ngrok

    example: ngrok tcp 3306

    it will expose your tcp port

    Forwarding tcp://0.tcp.ngrok.io:16922 -> localhost:3306