Can't view source? Compendium

Quick solutions for view source problems in Internet Explorer


When using Internet Explorer, cannot view the source of a web page?

Common causes:

Usually one of these two is the cause.

Cache is too full

Delete the Temporary Internet Files, otherwise known as the disk cache.
Tools > Internet Options... > General > Temporary Internet files > Delete Files...

Still not working? Read Microsoft Knowledge Base article 301057 and if you think you might have incomplete downloads in your cache, follow their workaround steps to move your Temporary Internet Files folder.

To avoid having to clear the cache periodically, reduce the cache size. 50 MB should suffice for most people.
Tools > Internet Options... > General > Temporary Internet files > Settings... > Amount of disk space to use

If clearing the TIF doesn't help, then try deleting files from the Windows temporary folder. You can use Windows Disk Cleanup, and if that doesn't delete enough, remove files manually. One way to get to the folder is with the TMP environment variable.
Start > Run... > enter %TMP% > click OK.
Some files may be locked, so delete what you can.

Notepad on desktop

If there is a file (or shortcut) on the desktop that is named Notepad, rename it to something else. If you're not using the shortcut, simply delete it.
Or if there's a shortcut to Notepad in your Quick Launch toolbar, rename it to something other than Notepad. (instructions)

Other causes:

The following solutions may not apply to everyone. I can view source fine without ever having made these settings. However, if nothing else is working, you may want to try them.

HTML editor settings

Set the HTML editor to Notepad instead of Microsoft FrontPage.
Tools > Internet Options... > Programs > HTML editor

Encoding Auto-Select

Uncheck Auto-Select for Encoding.
View > Encoding > uncheck Auto-Select

User account (specific to XP/IE6)

  • Add another user account in XP with administrator privileges
  • Copy the old user's desktop and favorites folders to the new account
  • If this new user account still can't view source in IE, then delete the new one, and the old one may work

SSL / Do not save encrypted pages to disk

Can't view source at a site using the HTTPS protocol? Look in Tools > Internet Options > Advanced tab > Security section, and look for the option Do not save encrypted pages to disk. When checked off, this option will intentionally disable View Source for SSL-secured content.

Registry setting

Warning: Before modifying the registry, make a backup.
Additional information:
  • Close all instances of Internet Explorer
  • Using regedit, navigate to [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\]
  • Add the key View Source Editor if it's not already there
  • Modify its Default value to be the path of the editor you want to use
    • The editor path will be something like "C:\Windows\notepad.exe"
    • Include the quotation marks if there are spaces in the path
  • Close regedit, and restart Internet Explorer

Microsoft recommendations:

Nobody's told me Microsoft's Knowledge Base solutions have helped, except of course the last one which is the clear cache solution.

Notepad needs to be installed


Specify a valid path for the TMP environment variable


Include the Change permission for the Cookies folder


Delete Temporary Internet files



These aren't solutions, just other possibilities that can narrow down if it's a real view source problem.

Webpage using JavaScript to block view source

A trick some sites use is to remove the browser's menu, and use JavaScript to prevent the right click.
Additional information: Help Preserve Right Click on the Web

view-source protocol

Are the menus not working? Try a different way of viewing source. In the browser's address field, enter view-source: in front of the URL. For example,

If you're using Windows XP SP2, the view-source: protocol in front of a URL will not work. For information about why view-source as a protocol is bad, refer to the article Notepad popups at

Microsoft KB article 904678 explains how disabling the view-source protocol is intentional, because they tightened up their MIME-handling in XP SP2.

For a verbose version of this information, please go my original View Source page. On the compendium page I basically took out chronological information, user feedback credits, supplemental tips, history lessons, and other ramblings. Then I added a couple longshot suggestions to the compendium only.

If you have another solution not listed here, let me know.

About this page: