How to Get Direct Download Links of Google Drive Files

Last Updated:
3 min read

3 years ago, I had shared a tool to generate direct download link for a Google Drive file. But what if you need to create direct links for the files inside a specific folder or simply all your drive files. There's a Sheets Add-on which lets you do it.

Google Drive Direct Download links

Upon installation, it requires permission to access your Google drive files.
Basically, there are two ways you can use this add-on.

1. Files inside specific folders

Using this feature, you can select the list of folders you want. All the files inside those folders will be exported to a sheet.

2. All the files inside Google drive

Simply all your files are exported to a sheet.

File details include folder name, path of the folder on Google Drive, file name, direct link & with whom you've shared the file. Each row on spreadsheet represents a file on your Drive.


How to install & use

You can install the Add-on using this link - Direct Download links for Google Drive. Click INSTALL, it will ask for your permission. Click Continue and choose your Google account to authorize the app.

Now you're all set to use the Add-on, on your sheet select Add-ons → Direct Drive Links → Generate Links. A pop-up opens as showed in the image below.

drive direct links sheets add-on select-folder-prompt

If you choose Selected folders, folder picker pop-up opens and you can select the folders you want. When you select All folders, the pop-up closes and a sheet opens with details of all your Google Drive files.

If you need links to the files shared with you, you have to tick the Include Shared with me folders checkbox.

Selected folders

Once you pick the folders, a pop-up opens with the list of folders you select. From that pop-up, you can add/remove a folder.

drive direct links sheets add-on folder list modal

You have to tick Recursively pick folders, if you want to cover the files inside nested folders. To explain this, let's take the following file system hierarchy.

    My Drive
    |--Folder 1
    |  |--File 1
    |  |--Folder 11
    |     |-- File 11
    |--Folder 2

Here, My Drive has two folders Folder 1 and Folder 2. Folder 1 contains a file File 1 and a folder Folder 11. Let's say your folder list contains only,

My Drice > Folder 1 >

So, if you select Generate without opting for recursive operation, you'll end up with File 1 info alone. If you had ticked the checkbox, your sheet will also have Folder 11 and File 11 entry.

Note: The sheet will generate pdf download links for Google Documents, Sheets and Presentations by default, however, you can change that by replacing pdf with xlsx or doc or pptx.

The best thing is you can also use this add-on as a Google Drive file manager by opting for All folders in the prompt. It'll simply list all your files.

Settings and Configuration

At any point of time, you can change the way you use this add-on. For example, if you want to pick folders after selecting all folders, you can do that by selecting Add-ons → Direct Drive Links → Select folders for links.

If you had selected too many unwanted folders and want to remove all at once, you can select Reset on the folder list pop-up.

For now, there are two configurations for you to use according to your needs,

1. Auto refresh

By default, whenever you open the sheet, it'll refresh the links automatically for you. But if you open the sheet more than once between 6-hour interval, automatic refresh won't happen. If you want to get the links to newly added files in the meantime, you can use Refresh Links option that's available under Add-ons → Direct Drive Links.

You can also disable the auto refresh option altogether, select Add-ons → Direct Drive Links → ✓ Autorefresh on open.

2. Repeat folder names

There is an option for you to repeat the folder path & names in column 2 & 3. When you sort by filename, to know within which folder every file is, you can use this. It is by default disabled, to enable it, just select Add-ons → Direct Drive Links → Repeat folder names. You can toggle if you want to disable later.

Open folders on Google Drive

Hover over the folder name in the first column and click on the link to view the folder contents on Google Drive.

Update Share details

If any of the files are not shared with anyone or you want to share that with more people, you can do that using your sheet, all you have to do is, hover over the file name for which you want to update share details, click on the link, you'll be redirected to the file preview page.

On the top right corner of the page, left to your profile picture, click on the menu and then Share. Now you can share that file with anyone you want.

Issues and Feature requests

If you run into any issues or you want any feature to be added to this add-on, do leave a comment on this post. I'll see what best I can do.