How to download a CRX file from the Chrome web store for a given ID? [closed]

The CRX file itself can be directly downloaded from
https://clients2.google.com/service/update2/crx?response=redirect&prodversion=[PRODVERSION]&acceptformat=crx2,crx3&x=id%3D[EXTENSIONID]%26uc

  • [PRODVERSION] is the version of Chrome, which must be 31.0.1609.0 at the very least, and
  • [EXTENSIONID] is the ID of the extension

(New in 2018) acceptformat=crx2,crx3 instructs the server to also respond with extensions in the CRX3 format (instead of 204 No Content when the extension is not available as CRX2).

If the extension you’re using contains OS-specific modules (e.g. NaCl), then you have to add additional parameters (os, arch, nacl_arch).

For the full logic of generating a complete CRX download URL, see the get_crx_url function in https://github.com/Rob–W/crxviewer/blob/master/src/cws_pattern.js.

This is a part of the Chrome Extension Source Viewer extension, available in the Chrome Web Store: https://chrome.google.com/webstore/detail/chrome-extension-source-v/jifpbeccnghkjeaalbbjmodiffmgedin


Note that opening the previous URL in Chrome will not trigger a download because Chrome automatically intercepts responses whose Content-Type is set to application/x-chrome-extension. If you want to programatically download the crx file in a Chrome extension, change the MIME-type to application/octet-stream (e.g. as done in src/lib/crx-to-zip.js).

Leave a Comment