Remote debugging Chrome for iOS

I've had some success with the iOS remote debug webkit adapter.

Install ios-webkit-debug-proxy and libimobiledevice

npm install remotedebug-ios-webkit-adapter -g

Enable remote debugging in Safari - iOS Settings => Safari preferences => enable "Web Inspector"

Make your computer trust your iOS device- starting iTunes could prompt the "Trust this computer" dialog.

remotedebug_ios_webkit_adapter --port=9000

Open tabs should show up in chrome://inspect/#devices Chrome debuig device inspection


You cannot directly remote debug Chrome on iOS currently. It uses a uiWebView that may act subtly different than Mobile Safari

You have a few options.

Option 1: Remote-debug Mobile Safari using Safari's inspector. If your issue reproduces in Mobile Safari, this is definitely the best way to go. In fact, going through the iOS simulator is even easier.

Option 2: Use Weinre for a slimmed down debugging experience. Weinre doesn't have much features but sometimes it's good enough.

Option 3: Remote debug a proper uiWebView that functions the same.

Here's the best way to do this. You'll need to install XCode.

  1. Go to github.com/paulirish/iOS-WebView-App and "Download Zip" or clone.
  2. Open XCode, open existing project, and choose the project you just downloaded.
  3. Open WebViewAppDelegate.m and change the urlString to be the URL you want to test.
  4. Run the app in the iOS Simulator.
  5. Open Safari, Open the Develop Menu, Choose iOS Simulator and select your webview.
  6. Safari Inspector will now be inspecting your uiWebView.

enter image description here

enter image description here

enter image description here


The Firefox Tools Adaptor allows one to use Firefox DevTools to debug websites on Safari or Google Chrome for iOS or Android.

https://github.com/mozilla/valence#debugging-safari-firefox-and-other-webviews-on-ios


Is it true that I need Safari on MacOS X to remote debug Chrome for iOS?

As far as I understand, yes.

Does Desktop Chrome allow anything?

No

Is Chrome for iOS just a webview application?

Yes, the app would be rejected otherwise, this is why Mozilla originally did not build a browser for iOS.