Note: This post is part of a larger set on using Fiddler with Windows Phone 7. This post covers the Windows Phone Emulator only.
Recently, some developers have asked me why Fiddler no longer works with the Windows Phone 7 emulator. Fiddler properly captured traffic from the CTP version of the emulator, but not from the final RTM version. I’ve asked the Phone team for more details, but today I’ll share a workaround with you that allows you to see traffic from the RTM version of the emulator.
- Install Fiddler 188.8.131.52.
- Start Fiddler.
- Click Tools > Fiddler Options.
- Open the Connections tab and tick the Allow remote computers to connect box
- Click OK to close the Fiddler Options dialog.
- In the QuickExec box under the session list, type prefs set fiddler.network.proxy.registrationhostname HostName where HostName is the name of your desktop computer.
- Close and restart Fiddler.
- Start (or restart) the Windows Phone 7 Emulator.
- Open Internet Explorer on the Emulator.
- Observe, your traffic shows in Fiddler.
If the browser on the phone works properly, but you don’t see the traffic in Fiddler, that suggests that you may have a Filter applied which is hiding the traffic. See this help topic for more information.
If you have enabled HTTPS Decryption in Fiddler, note that the Phone’s browser will show a certificate warning page when navigating to HTTPS pages. The Phone Emulator uses a different root certificate store than the desktop, so even if your desktop trusts the Fiddler Root, the Phone Emulator will not.
Thanks for using Fiddler, and thanks for developing for Windows Phone 7!
PS: Please remember that you’ve reconfigured Fiddler as in Step #6. If you ever rename your computer to something else, you’ll find that Fiddler “mysteriously” stops working, because it will be telling everyone to use a proxy on a non-existent machine name. 🙂 To fix this, simply type about:config in the QuickExec box, and delete the entire row containing fiddler.network.proxy.registrationhostname.
Update: These steps also work in Windows Phone 8’s emulator as of 10/31/2012