ngrok on termux

How to Install & Use ngROK on Termux Android Mobile Phone?

NGROK is a tool that allows you to expose a web server running on your local machine to the internet. It is particularly useful for web developers who want to test their web applications on different devices and networks. In this article, we will explore how to install and use NGROK on Termux, a popular terminal emulator for Android devices.

Installing NGROK on Termux

The first step in using NGROK on Termux is to install Termux itself. You can download Termux from the Google Play Store or from the Termux website. Once you have Termux installed on your device, you can use the following commands to install NGROK:

  • Open Termux and enter the command
pkg install wget
  • After the installation completes, enter the command
wget https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-arm.zip
  • Unzip the NGROK file with the command
unzip ngrok-stable-linux-arm.zip
  • Finally, run the ngrok command with the command
./ngrok authtoken YOUR_AUTH_TOKEN

You can get YOUR_AUTH_TOKEN by signup on ngrok offical website. https://ngrok.com/

Using NGROK on Termux

Once you have installed NGROK on Termux, you can start using it to expose a web server running on your local machine to the internet. Here are some basic commands to get started:

  • To start NGROK, enter the command ./ngrok http PORT_NUMBER where PORT_NUMBER is the port number that your local web server is running on. For example,
./ngrok http 8000.

NGROK will provide you with a public URL that you can use to access your local web server from anywhere on the internet.

  • You can use the subdomain option to specify a custom subdomain for your NGROK URL. For example,
./ngrok http --subdomain=myapp 8000.
  • You can also use the region option to specify a geographic region for your NGROK server. For example,
./ngrok http --region=us 8000

NGROK provides a wide range of options for customization, so you can configure the service to suit your needs. Once you have configured NGROK, you can start using your local web server from anywhere on the internet by accessing the NGROK URL.

Conclusion

NGROK is a powerful tool for exposing a local web server to the internet and making it accessible from anywhere on the internet. By using NGROK on Termux, you can perform this task on your Android device. With its user-friendly interface and customizable options, NGROK is an essential tool for web developers who want to test their applications on different devices and networks.

error: Content is protected !!