Download Google Chrome Without a Web Browser using Windows Command Line

Due to the popularity of my old post on how to download firefox without a web browser, I decided to figure out a way to do the same thing with Chrome.  Chrome doesn’t seem easily accessible on FTP, so this method allows you to still download Chrome from a safe web source, via the HTTP link that Google provides.

1.  Open NotePad and paste the below VBScript code into it.

Note: The strFileURL variable is currently set to the URL that Chrome is at as of today.  That might change later.  Find latest Chrome EXE by going here. Click accept and install, then right-click copy the URL titled “Click here to retry.”

' This is the URL of the chrome EXE.
' This is where the file will download to.
strHDLocation = "c:ChromeStandaloneSetup.exe"
' Fetch the file
Set objXMLHTTP = CreateObject("MSXML2.XMLHTTP") "GET", strFileURL, false
If objXMLHTTP.Status = 200 Then
Set objADOStream = CreateObject("ADODB.Stream")
objADOStream.Type = 1 'adTypeBinary
objADOStream.Write objXMLHTTP.ResponseBody
objADOStream.Position = 0 'Set the stream position to the start
Set objFSO = Createobject("Scripting.FileSystemObject")
If objFSO.Fileexists(strHDLocation) Then objFSO.DeleteFile
Set objFSO = Nothing
objADOStream.SaveToFile strHDLocation
Set objADOStream = Nothing
End if
Set objXMLHTTP = Nothing

2. Save your notepad file to your desktop, and use quotes in the filename to overwrite saving as a .txt file:

3. Go to your Windows command prompt (Start > CMD)
4. Navigate to your desktop in the command prompt (cd desktop)
5. Run the command: cscript.exe downloadfile.vbs

6. Open Windows explorer, and right on your C drive you should see the chrome installer at c:ChromeStandaloneSetup.exe

Attribution: This vbscript was adopted by Gareth’s method on

22 thoughts on “Download Google Chrome Without a Web Browser using Windows Command Line

  1. Hey thanks for this invaluable info man! ive been looking to download google chrome without a browser for ages, Quality post.Thanks


  2. I wouldn’t use C: Admin right required for C: many people don’t know this so I’d use a USB Drive.
    Also Type mismatch on line 17. Move it to end of line 16. Other than that it works great.


  3. Love the site! With the Google Chrome VBS file I had to delete line 17 and it then worked on my system. I am not sure if it was specific to me, but I am running Windows XP Media Center with all updates. The link for the chrome installer still works too! Keep up the great work!


  4. Hey Shaun or Matt.

    Could you help me out? I am smart, but know nothing of programming. I had to type it all up (as I had no way of cutting and pasting w/o internet access) and I proofed it. I am getting an error that sounds like what Shaun was talking about and I did not quite understand how Shaun meant to correct the error. (I tried just deleting line 17 as the previous poster stated but that didn’t work.)



  5. This is useful to me … I do data recovery and often have to re-install Windows and prep the machine for the owner. If I fetch Chrome with this I don’t have to start Internet Explorer up at all. When I need the correct URL I look it up with Chrome (on my Macbook Pro, I don’t ever actually use those ol’ Windows these days).


  6. Hi Matt,
    Thanks for the script. Works great!
    I am trying to modify it to download beta and dev releases, but it doesn’t work. Can you tell me how you got the strFileURL? I can’t figure out a pattern to get URLs for beta/dev.


  7. I get the (17,1) Microsoft VBScript runtime error: Type mismatch: ‘strHDLocation’. So I tried Shauwn LaLnde’s suggestion to move line 17, ‘strHDLocation’ to end of line 16. I now get this error: “ADODB.Stream Write to file failed.” I would very much appreciate any suggestion. Both my Chrome and IE browser got killed by some malicious file I tried to download. So my only access now is my notebook PC. By the way this notebook is on a home network with my desktop, and my browsers are okay on the notebook. Anyway to take advantage of that?


  8. Ignore my request for help. My “duh” afterthought about downloading a standalone start-up file to this notebook via my home network. I did that and all is well now on both PC’s.


  9. After I tried this as written it failed on line 17 so I moved line 17 to the end line 16 as per Shauwn LaLnde. Then it failed again on line 18 (which was originally line 19 above) with Write to file failed.
    Can anyone help me, please?


  10. For those getting an error about strHDLocation, it is because of this:

    If objFSO.Fileexists(strHDLocation) Then objFSO.DeleteFile

    It should be on one line:
    If objFSO.Fileexists(strHDLocation) Then objFSO.DeleteFile strHDLocation


  11. How am I supposed to copy and and paste all of this code, on my computer, without access to the internet to get to your blog??? Makes no sense.


  12. Thanks for posting this info. The link to Chrome executable worked. After it downloaded, I copied it to a thumb drive and installed it on a PC that had been reset to how it came from Dell. The reset IE was release 7 and it would fail whenever attempting to download a new browser, even a new IE.


  13. But–

    I wonder exactly how Windows actually fulfills the objXMLHTTP request.

    Isn’t it sort of likely that it probably uses I IE or else some sort of DefaultWebBrowser system setting?

    Furry cows moo and decompress.


  14. I can confirm this worked on Windows 10 (updated) after some system bug made Windows hang after booting up and seemingly corrupted all browsers installed after I restarted it.
    However I also had the error message, which was fixed after I simply cut line 17 (as in the example) and pasted it at the end of line 16.
    Sadly, the installation closes abruptly and the problem persists (can’t start any browser, instant error message)


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s