Change “View Source” editor in Internet Explorer and Edge

Switch Editor in Internet Explorer

Those of you, who create websites do well to ensure that these are displayed correctly in all major browsers. But as most of you should know, due to differences between Internet Explorer, Firefox, Chrome and Safari this succeeds only in the rarest cases right away.

Thus, as a developer you’ll frequently have a look to the source code of a website, which in most cases just hurts in Internet Explorer, because the default editor of the “View source code” function is just a new window in IE instead of a good editor. Maybe it’s ok for a quick look, but not for getting work done.

Anyone who prefers to use Notepad++, SublimeText or another editor of choice to display the source code of a webpage in Internet Explorer, should give me his attention for the next minutes. In the following article I want to show you, how you can adjust the default editor in different Internet Explorer (IE) versions.

Change “View Source” editor in Internet Explorer 8-10

In Internet Explorer versions 8 to 10 the default source code editor can be modified easily via a menu setting. For this purpose, first the developer tools must be opened. This can be done either by pressing the F12 key or via the following menu path: Tools -> Developer Tools.

Internet Explorer 8-10 Sourcecode-Editor setzen - Step 1  Internet Explorer 8-10 Sourcecode-Editor setzen - Step 2

If the Developer Tools windows is shown, the settings can be accessed via the File menu. In the File menu click the “Customize Internet Explorer View Source”. That’s the point where the default source code editor can be set. By clicking the “Other …” button, you can choose any text editor you want.

Change the “View Source” editor in Internet Explorer 11

Unfortunately in Internet Explorer 11 this comfortable way of setting the default editor no longer exists. (Hey, this wasn’t done to annoy you, but to show you, that it’s an original Microsoft product. If it would have become easier it wouldn’t be a Microsoft product…)  In IE 11 the only way to change the “View Source” editor is an intervention in the Registry. Therefore open the Registry over the Start menu or via the Run dialogue (Win + R) and the command “regedit”. The necessary adjustments must be made below the following key:

HKEY_CURRENT_USERSoftwareMicrosoftInternet Explorer

First, a new key called “View Source Editor” must be created. Then another key named “Editor Name” must be created below the first key.

Internet Explorer 11 Sourcecode-Editor - Step 1  Internet Explorer 11 Sourcecode-Editor - Step 2

If both keys are created, the default value of the second key has to be adjusted. Here you enter the full path to your editor of choice.

Internet Explorer 11 Sourcecode-Editor - Step 3  Internet Explorer 11 Sourcecode-Editor - Step 4

Unfortunately this setting also brings an unsightly disadvantage, which is related to Microsoft’s Edge browser…

How to change the “View Source” editor in Microsoft Edge

Let’s talk about Microsoft’s latest browser – Edge. For this “browser” I’ve not found any solution to replace the default editor. Clicking on the “View Source” button will automatically open the Developer Tools – no ifs and buts. Also in the Microsoft forum there has been no solution until today.

However the following fact is just more worse. So Edge not only will not accept the registry settings for Internet Explorer 11 (see section above) , but also it gets broken by this settings. That means in plain text – one uses the above workaround to change the default editor for IE 11 and at the same time loses the opportunity in Edge to use the “View Source” button. Hey Microsoft, if the settings done work for Edge, please ignore them completely! Hopefully this will be fixed in the future!

2 Comments

  1. Mark A.says:

    I expect Internet Explorer will be removed when support for Windows 7 ends in 2020 and Edge (IE engine) is replaced by Edge (Chrome engine)
    So having no way to edit the source code with Edge is getting more important.
    Until Microsoft add an option to use Notepad with Edge, lets all start sending Microsoft messages to add this option until they get fed up with all the messages and give us this option that existed in 1995.

  2. Thank you very much for a quick and clean solution to my problem!

Leave a comment

Please be polite. We appreciate that. Your email address will not be published and required fields are marked