How to View the Source Code of a Chrome Extension

Developer News – A not so neat little trick. I found this cool post on Digital Inspiration which tells you how to view the source of a Chrome extension.

Why should you view the source? Here are the two main reasons according to the blogger on DI.

There are two main reasons why you may want to read the source code of any Google Chrome extension (including Web Apps and Chrome Themes):

  1. If the Chrome extension has been created by an unknown developer,  you want to ensure that it does what the description says and nothing more. You would not like to download a Chrome extension on your machine that tracks your search logs or browsing history.
  2. You are learning how to write a Chrome extension (or theme) and are curious to know how some of the good extensions have been written. The licenses of some Chrome extensions may even allow code reuse with attribution.

However many developers share their source code and invite everyone to take a look at it and contribute. But most of them won’t do that.

So, ready to grab the source of an extension?  Here is the full post with easy instructions. They have listed a way to get the source of extensions installed on your Chrome, and also a nice little bookmarklet that lets you download the source without installing the extension. So cool!

2 responses to “How to View the Source Code of a Chrome Extension”

  1. IMO if you distribute your extension it would be unreasonable to expect people NOT to look at your extension’s source code.

    The only way really to hide it would be to obfuscate it (annoying but not entirely irreversible, especially thanks to Chrome’s Dev Tools) or to use a Native Client binary or a plugin, and thus you can ship compiled code. But for the latter it would require a manual inspection of your extension by Google anyway.

  2. PAEz – Australia – My tag is PAEz, my name is unimportant.

    Once again if your on windows and want an even easier way theres my tool…..

Leave a ReplyCancel reply