Pular para o conteúdo

Tips to Debug React Native under Android

Tips to Debug React Native under Android

Hello, I'm Luiz, a 26-year-old Software Engineer from São Paulo, Brazil. Today, I want to share some essential tips for debugging Android apps using React Native and ADB (Android Debug Bridge). Whether you're an experienced developer or just starting out, these tips will help make your debugging process more efficient. Let's dive in!

ADB

What is ADB? ADB, or Android Debug Bridge, is a versatile command-line tool that allows developers to communicate with and control Android devices. It facilitates a variety of device actions, such as installing and debugging apps, and provides access to a Unix shell that you can use to run various commands on a device.

Connect your device over WiFi to install or debug

ADB, has a feature that will allow us to connect our android device over wi-fi so this way we can debug without the need of a cable connected to the device.

To make this happen make sure that you follow the steps

  1. Make sure that your device and your computer are under the same wi-fi network, ADB Debugging and Wireless Debugging are enabled in the Android Device's Developer options
  2. Get the IP Address of the Device, Searching for IP address on the device settings or by connecting via USB and running this command adb shell "ip addr show wlan0 | grep -e wlan0$ | cut -d\" \" -f 6 | cut -d/ -f 1"
  3. Now if you have any cables connected remove from the device and run adb connect <ip_address>:5555

Redirecting ports

Sometimes, Android and React Native encounter issues fetching localhost URLs. What does this mean? It indicates that Android is unable to find the ports on your machine. To resolve this, you can use some commands to proxy the ports to your computer to the Android Device:

adb reverse tcp:PORT tcp:PORT
adb -d reverse tcp:PORT tcp:PORT
adb -e reverse tcp:PORT tcp:PORT

Typically, this issue arises with the React Native bundler. To fix it, you just need to replace PORT with 8081:

adb reverse tcp:8081 tcp:8081
adb -d reverse tcp:8081 tcp:8081
adb -e reverse tcp:8081 tcp:8081

Control your device with your computer

There is a Tool that you can install and control devices that are connected over ADB on your computer, called scrcpy:

To start the application just run type on your terminal

scrcpy

Thats all Folks

Debugging Android apps with React Native and ADB can make your life a lot easier. Using features like wireless debugging, port redirection, and tools like scrcpy helps you stay connected and fix issues without hassle. Keep experimenting and stay updated with new tools to make your debugging process smooth and efficient. Happy coding!

Profile picture
Luiz Fernando - Senior Software Engineer

Obrigado por ler!

Espero que você tenha gostado de ler este artigo. Se você tiver alguma dúvida ou feedback, não hesite em entrar em contato comigo nas minhas redes sociais abaixo. Tenha um ótimo dia!

Carousel imageCarousel imageCarousel imageCarousel imageCarousel image
Próximo / Tudo começa com uma boa conversa

Grandes ideias.
Little Luiz.

Um produto para tirar do papel? Um time para fortalecer? Vamos descobrir o que podemos construir juntos.

Escolha seu caminho
01Freelance / Products

Tenho um projeto

Freelances, produtos e desafios técnicos para resolver juntos.

  • Da descoberta do produto à entrega
  • Engenharia web, mobile e backend
  • Escopo claro. Colaboração direta.
Vamos criar algo
02Hiring / Teams

Estou formando um time

Vagas de engenharia e oportunidades para construir a longo prazo.

  • Engenharia full-stack sênior
  • Visão de produto e responsabilidade técnica
  • Experiência com times distribuídos
Me chame para o seu time
03Résumé / Versions

Explore currículos

Versões sob medida para engenharia geral, health-tech, fintech e mais.

  • Seis variantes focadas
  • Exportação PDF pronta para impressão
  • Atualizado para cada vaga
Veja meu currículo
luizepauloxd@gmail.com

Prefere e-mail? Escreva diretamente ou comece um rascunho aqui.

Me conte o que você tem em mente.

© 2026 Luiz Fernando Feito com intenção. E um pouco de curiosidade.Voltar ao topo