I had this issue; it paired fine the first time in-app but never worked again when trying to pair or connect directly from Android Studio.
What I now do to connect/pair is the following:
- Open your phone’s settings and be sure to enable wireless debugging in developer options
- Click
Pair device with pairing code
, and keep it on that screen. - Now, go into a terminal and
cd
into the%LOCALAPPDATA%\Android\sdk\platform-tools
directory. - After that, type
adb pair <PHONE_IP>:<PHONE_PORT>
- Input the pairing code when prompted
- Finally, run
adb connect <PHONE_IP>:<PHONE_PORT_PROVIDED_ABOVE_PAIR_WITH_QR_BUTTON>
, and it should connect; Android Studio will automatically detect the connection, so that’s it!