iOS Remote Debugging: A Comprehensive 2021 Guide

Last updated

When it comes to testing and debugging of mobile applications, the important element is target devices. Well, if you have the possibility to connect iPhone or iPad directly to your development machine, you don’t have to worry. But what if you needed to inspect an app running on a device that couldn’t be physically connected to your Mac? Remote debugging will probably be the best option in that case.

If you are wondering how to debug iOS apps on a device wirelessly or even remotely, in this article you’ll find out about the most convenient ways to do that.

FlexiHub

Windows, macOS, Linux, Android
4.8 Rank based on 78+ users
The efficient solution for enabling Xcode remote debugging is FlexiHub, dedicated software for sharing USB over any distance.
FlexiHub

Software for iOS remote debugging

FlexiHub is designed to virtualize USB devices, (like iPhone, iPad, iPod, etc.) and redirect them over the network. The solution works across LAN, Ethernet, and the Internet.

With FlexiHub, you will have access to the iPhone or iPad despite any distance between the Mac running Xcode and the device itself. FlexiHub will become a useful addition to those teams that are working remotely but still need to perform iPhone USB debugging.

What is more, FlexiHub works across a wide range of platforms including Mac, Windows, and Linux. This means that you will be able to connect a device to any of them and run iOS remote debugging on a single Mac with Xcode.

How to debug iPhone remotely

Here’s how FlexiHub can help you access and debug the iOS app on devices remotely:
1
Firstly, register a FlexiHub account and sign up for a free trial.
 flexihub free account
2
To establish a remote connection to your iOS device, you’ll need to install Flexihub on both the local machine running the debugger and a remote computer with the iOS device physically attached.
 Download Flexihub
3
Launch FlexiHub on the local machine and sign into the account.
 log into flexihub account
4
Start the software on the remote computer and log into the FlexiHub account using the same credentials.
 remote ios debugging with flexihub
5
In the software interface on the local PC, you’ll see iPhone/iPad available for connection. Click “Connect”.
 connect ios device for remote debugging

That’s it. Now you can access the remote iOS device from your local computer as though it were directly connected to your machine.

We have also made a brief video to demonstrate a hands-on experience of connecting iOS devices to Mac for remote debugging:



Note: For best performance with iOS devices, it is recommended to use a direct connection in FlexiHub, which involves machines with the public IP addresses on both sides. If the iOS device is connected over WAN for remote debugging, for latency decrease it is essential to deploy a tunnel server.

How to debug iOS app wirelessly

Wireless debugging has become a reality thanks to the new feature available since Xcode 9.

This feature eliminates the need to always connect and disconnect the device for app installation and debugging.

However, you should bear in mind that, despite its many advantages, this method has some drawbacks:

  • For remote debugging of your iOS device, you’ll still need to physically attach the device to your Mac at least once.
  • Mac system and iPhone/iPad should share the same network. If the iOS device and Mac are not connected to the same LAN, or iPhone/iPad is located miles away from the programmer’s computer, the remote iOS debug feature becomes unavailable.
  • Before you start, make sure that you use Xcode 9.0 or later, macOS 10.12.4 or later, and iOS 11.0 or later.

To set up iPhone, iPad, follow these steps:

  1. Open your project on Xcode.
  2. Select Window > Devices and Simulators.
  3. In the window that appears, click “Devices”.
  4. Link your device to your Mac via a USB cable.
  5. In the left column, choose the device, and in the detail area, check the box “Connect via network”. Xcode wireless debugging Now, Xcode will pair with your device. If Xcode can connect with the device over the network, a network icon will appear next to the device in the left column.
  6. Disconnect your device.

Now you are ready to start remote debug of iOS apps.

FlexiHub

Requirements: Windows 7/8/10, Server 2008 R2/2012/2016/2019
Size: 6.99MB
Version: 4.1.13108 ()
User rating: (4.8 based on 78+ users)