Web Applications Stack Exchange is a question and answer site for power users of web applications. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying In Google Drive, how can you link directly to "Download" a zip file and not view the contents? but it does not work. I am not sure on how to repeat the question. It downloads a 'file is too big to be antivirus scanned' warning HTML and when I try https://drive.google.com/uc?export=download&confirm=no_antivirus&id= it still downloads that.

Edit: I tried to wget --save-cookies /tmp/cookie.txt --load-cookies /tmp/cookie.txt and repeat it, still no dice.

share|improve this question
Did you ever figure this out? Running into the same problem with bigger files. – Travis R Mar 18 '14 at 19:31
No, I gave up on this. – chx Mar 18 '14 at 20:50
up vote 1 down vote accepted

A cookie must match the "confirm" url parameter, and it is changed on each call.

Here's a perl script to download these files in an unattended way.

With the url from the antivirus scan warning page (https://drive.google.com/uc?export=download&confirm=s5vl&id=XXX) this code should be enough:

use strict;
my $TEMP='/tmp';my $COMMAND;my $confirm;
sub execute_command();
my $URL=shift;my $FILENAME=shift;
$FILENAME='gdown' if $FILENAME eq '';
if (-s $FILENAME < 100000) { # only if file isn't the download yet
    open fFILENAME, '<', $FILENAME;
    foreach (<fFILENAME>) {
        if (/confirm=([^;&]+)/) {
            $confirm=$1; last;   }    }
    close fFILENAME;
    execute_command();    }
sub execute_command() {
    $COMMAND="wget --no-check-certificate --load-cookie $TEMP/cookie.txt --save-cookie $TEMP/cookie.txt \"$URL\"";
    $COMMAND.=" -O \"$FILENAME\"" if $FILENAME ne '';
    `$COMMAND`; return 1;    }
share|improve this answer
I've made a python script, and my cookie matches the confirm parameter in the url. However, it does not work: I am being redirected to a page titled "Sign in - Google Accounts". – Benjamin Toueg Feb 12 '15 at 11:32
Benjamin: you may need to process the url twice... look how the script calls execute_command() twice. – circulosmeos Mar 7 '15 at 16:49

Try this

You can download these files to your computer in the following formats:

For documents: HTML, RTF, Word, Open Office, PDF, Text file.
For spreadsheets: CSV, HTML, ODS, PDF, XLS, TXT (only for a single sheet)
For presentations: PDF, PPTX, TXT
For drawings: PNG, JPEG, SVG, PDF

Download a file to your computer from Google Drive

Click the checkbox(es) next to the item(s) that you'd like to download.
Expand the More drop-down menu, and select Download...
Select a file format to which you'd like convert and download your item, such as Microsoft Word. If you select multiple items, they'll be

compressed into a .zip file Click Download.

You can also download a file when you're viewing the file. Go to the File menu, point your mouse to Download as, and select a file format.

If total file is above 2GB I don't think you'll be able to download without breaking into batches.

share|improve this answer
alas, it's a binary file :( neither of the above. – chx Apr 25 '13 at 2:05

Ok, Google uses the following URL format for the final download link:


Notice the confirm parameter which seems to change every time you go to the original link. Maybe it's a short lived token or cookie matching or something?

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.