# Google Drive Folder Downloader — Bulk ZIP Shared Folders (`vasram/google-drive-folder-downloader`) Actor

Bulk-download an entire Google Drive folder — every file, all subfolders — as ZIP files in the cloud, with a file manifest. No login or API key needed for public folders. Handles huge folders that make Google's own download button fail.

- **URL**: https://apify.com/vasram/google-drive-folder-downloader.md
- **Developed by:** [Vasram Sonagara](https://apify.com/vasram) (community)
- **Stats:** 1 total users, 0 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 file downloaded (up to 10 mb)s

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### What does Google Drive Folder Downloader do?

**Google Drive Folder Downloader** is the easiest way to **download all files from a Google Drive folder** — including every subfolder — and get them as **ZIP files in the cloud**, plus a structured **file manifest**. Just paste a **shared Drive folder link** and run: no login, no Google account, and **no API key needed for public folders**. It turns a Google Drive folder into a ZIP archive you can grab in one click.

Try it in under a minute: paste a small public folder link (the input comes pre-filled with a working example), press **Run**, then download your ZIP from **Storage → Key-value store**.

Everything lands in **your own Apify storage** — nothing is uploaded anywhere else, nothing is retained. That is what makes it a trustworthy **shared folder downloader** and a safe alternative to sketchy "drive downloader" websites. As an Apify Actor it also gives you scheduling, an API, integrations (Make, n8n, Zapier), monitoring and webhooks out of the box.

### Why use this Google Drive folder downloader?

Google Drive's own **"Download folder" button fails** on real-world folders: more than ~50 files often stalls, ~2 GB ZIPs fail silently, and your browser must stay open the whole time. This actor fixes that by running in the cloud:

- **Zero setup for public folders** — no API key, no OAuth, no Google Cloud project. Paste the link and go.
- **Huge folders welcome** — streaming, multi-part ZIPs (default 200 MB per part) never blow up RAM or the browser.
- **Google Docs, Sheets, Slides & Drawings handled** — they get exported to PDF/DOCX/XLSX/PPTX/PNG automatically (the feature most downloaders forget).
- **Recursive** — subfolders are traversed automatically, with optional depth caps.
- **Filtering** — download only PDFs, only images, size windows, date windows, or glob patterns like `photos/**` and `~$*`.
- **Automation-ready** — run on a schedule, get webhook notifications, or **incrementally sync** a Drive folder into your Apify storage.

### How to download an entire Google Drive folder (step by step)

1. In Google Drive, right-click the folder → **Share** → set *General access* to **"Anyone with the link"**.
2. Copy the share link and paste it into the **Folder URL** input field.
3. Click **Run** (a 10-file test folder costs about **$0.03**).
4. When the run finishes, open **Storage → Key-value store** and download `drive-download-part-001.zip` (…, `-002`, etc.). Each part is a normal, openable ZIP file.
5. Check the **Storage → Dataset** tab for the file manifest: one row per file showing exactly what was downloaded, exported, skipped or failed.

Private folders: share them as "Anyone with the link", or supply an OAuth access token in the `oauthToken` input.

### Input parameters

| Field | Default | Description |
|---|---|---|
| `folderUrl` | — (required) | Folder share link, `open?id=` link, or bare folder ID. |
| `apiKey` | — | *Optional.* Your own Google Drive API key → uses the official Drive API (exact file sizes, MD5 checksums, Shared Drives). Recommended for heavy use. |
| `oauthToken` | — | *Optional.* OAuth access token for private folders (scope `drive.readonly`). |
| `downloadSubfolders` | `true` | Recurse into subfolders. |
| `maxDepth` | `-1` | `-1` = unlimited depth. |
| `includePatterns` / `excludePatterns` | — | Glob patterns, e.g. `*.pdf`, `photos/**`, `~$*`. |
| `typeFilter` | `all` | `images` | `documents` | `spreadsheets` | `pdfs` | `videos` | `audio` | `archives`. |
| `minSizeMB` / `maxSizeMB` | `0` | Size window filter (needs an `apiKey` — the no-key view doesn't expose sizes). |
| `modifiedAfter` | — | Only files modified after this date (cheap incremental runs). |
| `exportDocsAs` | `pdf` | Export Google-native files as: `pdf` | `docx` | `xlsx` | `pptx` | `csv` | `skip`. |
| `outputMode` | `zip` | `zip` | `individual-files` (each file as its own storage record) | `manifest-only` (listing only, no downloads). |
| `zipPartSizeMB` | `200` | Split size for ZIP parts (0 = single ZIP). |
| `preserveStructure` | `true` | Keep the folder tree inside the ZIP; `false` flattens everything. |
| `compression` | `store` | `store` (fastest — best for photos/videos) | `fast` | `best`. |
| `maxFiles` | `5000` | Safety cap — the run aborts *before downloading anything* if the folder is bigger, so you never get surprise charges. |
| `concurrency` | `5` | Parallel downloads (1–20). |
| `incremental` | `false` | Sync mode: re-runs download only new/changed files. |
| `stateStoreName` | `drive-sync-state` | Named Key-Value store for incremental state. |
| `notifyWebhookUrl` | — | Completion webhook (full JSON summary). |
| `telegramToken` + `telegramChatId` | — | Completion message to Telegram. |
| `proxyConfiguration` | off | Optional proxy if Google rate-limits the run. |

### Output: ZIP files and the file manifest

- **Key-Value store:** `drive-download-part-001.zip`, `-002`, … (default mode) or `files/<relative-path>` (individual-files mode), plus `SUMMARY.txt` and an `OUTPUT` JSON run summary.
- **Dataset (manifest):** one record per file — a complete audit trail. Export it as JSON, CSV, Excel or HTML.

```json
{
  "fileName": "IMG_2041.jpg",
  "relativePath": "day-1/IMG_2041.jpg",
  "status": "downloaded",
  "sizeBytes": 2538291,
  "modifiedTime": "2025-11-02T14:03:11Z",
  "delivery": { "zipPart": "drive-download-part-001.zip" },
  "viewLink": "https://drive.google.com/file/d/…/view"
}
```

| Field | Meaning |
|---|---|
| `fileName` / `relativePath` | File name and its path inside the shared folder |
| `status` | `downloaded` · `exported` (Google-native) · `skipped` · `failed` |
| `skipReason` | Why a file was skipped (filter, unchanged, manifest-only, …) |
| `sizeBytes` / `modifiedTime` | File metadata (exact in API mode; dates in no-key mode) |
| `delivery` | Where the file ended up (ZIP part or storage key) |
| `viewLink` | Direct link back to the file in Google Drive |
| `error` | Failure details for `failed` files — nothing is ever silently missing |

### How much does it cost to download a Google Drive folder?

Pay-per-event — you only pay for files that are **successfully delivered** (failed attempts are never billed):

| Scenario | What you pay |
|---|---|
| Try it: 10 photos (~20 MB) | **≈ $0.03** |
| Typical: 100-photo folder (~800 MB) | **≈ $0.30** |
| Big: 2,000 mixed files (~10 GB) | **≈ $5.80** |
| Daily incremental sync (30 new files/day) | **≈ $1.80/month** |

Events: small file (≤10 MB) $0.002 · large file (>10 MB) $0.01 · Google-native export $0.003 · ZIP part $0.005. The Apify free plan's $5 monthly credit covers roughly 2,300 small files.

### Tips for bulk-downloading large Drive folders

- **Preview for free:** set `outputMode` to `manifest-only` to list a folder without downloading anything — also the way to sanity-check a huge folder before committing.
- **Big folders:** raise the run timeout (15–60 min) in the run options; everything streams, so memory stays flat.
- **Scheduled sync:** enable `incremental` + a daily schedule to keep your Apify storage mirrored with a Drive folder — re-runs fetch only what changed.
- **Heavy usage:** provide your own `apiKey` for exact sizes, MD5 checksums, size filters and Shared Drives support.
- **Rate limits:** if Google throttles the run (rare), re-run later, provide an `apiKey`, or enable the optional proxy input.

### FAQ, disclaimers and support

#### How do I download all files from a shared Google Drive folder without an API key?

Paste the folder's share link into `folderUrl` and run — the default mode reads Google's public folder view directly, no credentials needed. Only folders shared as "Anyone with the link" can be accessed this way.

#### Why does Google Drive fail to download large folders natively?

Drive's browser ZIP export is size- and file-count-limited and dies on long downloads. This actor streams files server-side and splits the result into independent ZIP parts, so there is no browser timeout and no 2 GB ceiling.

#### Is it safe? Do you store my files?

No — files flow from Google into *your own* Apify Key-Value store and are deleted per Apify's normal retention. The actor keeps no copy.

#### Can I download a Google Drive folder as multiple ZIP files?

Yes — that's the default. `zipPartSizeMB` (default 200) controls the split; every part is a self-contained, openable ZIP.

#### Are Google Docs, Sheets and Slides included?

Yes. Google-native files can't be downloaded directly, so they are exported (Docs→PDF/DOCX, Sheets→XLSX/CSV, Slides→PPTX, Drawings→PNG) — or skipped entirely with `exportDocsAs: skip`.

#### Is this allowed?

The actor only accesses folders that are already shared publicly with you, and stores results in your own Apify storage. Respect copyright — download only content you have the right to download. Unofficial access to Google may occasionally be rate-limited; retries are built in.

#### Known limitations?

In the default no-key mode Google doesn't expose exact file sizes or MD5 checksums (dates are available), so size filters need an `apiKey`. Very large folders (thousands of files) may need a raised `maxFiles` and run timeout.

#### Can I use this to back up or sync a Google Drive folder?

Yes. Enable `incremental` and schedule the actor (e.g. daily): each run lists the folder, downloads only new or changed files, and appends them to your Apify storage — an easy **Google Drive folder backup/sync** setup for course materials, client assets or public datasets.

#### Bugs or feature requests?

Open an issue on the **Issues** tab. Need a custom solution (S3 push, private-folder OAuth flow)? Reach out via Apify.

# Actor input Schema

## `folderUrl` (type: `string`):

Paste the share link, e.g. https://drive.google.com/drive/folders/1AbC… — the folder must be shared as 'Anyone with the link' (or provide an OAuth token below for private folders). A bare folder ID also works.

## `apiKey` (type: `string`):

Optional. Uses the official Drive API (better metadata incl. MD5, Shared Drives support). Create one at console.cloud.google.com → enable Drive API → Credentials → API key. Leave empty to use the default no-key mode for public folders.

## `oauthToken` (type: `string`):

Only needed for private/restricted folders. Requires https://www.googleapis.com/auth/drive.readonly scope. Leave empty for public folders.

## `downloadSubfolders` (type: `boolean`):

Recurse into subfolders and download everything inside.

## `maxDepth` (type: `integer`):

-1 recurses the whole tree. A positive number limits how deep subfolders are followed.

## `includePatterns` (type: `array`):

Glob patterns matched against the file name or relative path, e.g. \*.pdf or photos/\*\*. Empty = download everything.

## `excludePatterns` (type: `array`):

Glob patterns to skip, e.g. *.tmp or ~$* (Office lock files).

## `typeFilter` (type: `string`):

Only download files of the selected type.

## `minSizeMB` (type: `integer`):

Skip files smaller than this. 0 = no minimum. Note: file sizes are only known in API-key mode — in the default no-key mode this filter is skipped (a warning is logged).

## `maxSizeMB` (type: `integer`):

Skip files larger than this. 0 = no maximum. Note: file sizes are only known in API-key mode — in the default no-key mode this filter is skipped (a warning is logged).

## `modifiedAfter` (type: `string`):

ISO date, e.g. 2026-01-01. Only files modified after this date are downloaded — handy for scheduled incremental runs. Files whose date is unknown are kept.

## `exportDocsAs` (type: `string`):

Google-native files (Docs, Sheets, Slides, Drawings) cannot be downloaded directly — they get converted: Docs→PDF/DOCX, Sheets→XLSX/CSV, Slides→PPTX/PDF, Drawings→PNG/PDF. Use 'skip' to ignore them.

## `outputMode` (type: `string`):

zip = multi-part ZIPs in the Key-Value store. individual-files = every file stored separately under files/<path>. manifest-only = just list the files without downloading anything.

## `zipPartSizeMB` (type: `integer`):

Output ZIPs are split into parts of this size (0 = a single ZIP). Each part is an independent, openable ZIP file in the Key-Value store.

## `preserveStructure` (type: `boolean`):

true keeps the exact folder tree inside the ZIP; false flattens everything into one folder.

## `compression` (type: `string`):

store = no compression (fastest — best for photos/videos which are already compressed). fast/best = deflate.

## `maxFiles` (type: `integer`):

If the folder contains more files than this, the run stops BEFORE downloading anything (and before charging) so you never get surprise costs.

## `concurrency` (type: `integer`):

How many files to download at the same time (1–20).

## `timeoutSecPerFile` (type: `integer`):

Maximum time allowed per file download.

## `maxRetries` (type: `integer`):

Retries on network errors, 5xx and rate limits (exponential backoff, honors Retry-After).

## `incremental` (type: `boolean`):

Stores sync state in a named Key-Value store; on re-runs only new/modified files are downloaded. Great with scheduled runs.

## `stateStoreName` (type: `string`):

Named Key-Value store used to remember what was already downloaded in incremental mode.

## `notifyWebhookUrl` (type: `string`):

A JSON summary is POSTed here when the run finishes (success or failure). Works with Make, n8n, Zapier.

## `telegramToken` (type: `string`):

Bot token used to send a completion message via Telegram (needs telegramChatId too).

## `telegramChatId` (type: `string`):

Chat or channel ID that receives the completion message.

## `proxyConfiguration` (type: `object`):

Optional. Use only if Google rate-limits or blocks the actor. Using a proxy increases platform costs.

## Actor input object example

```json
{
  "folderUrl": "https://drive.google.com/drive/folders/1FYLaoscxWBV_BU5sFouf7XCrv7cKktBY",
  "downloadSubfolders": true,
  "maxDepth": -1,
  "typeFilter": "all",
  "minSizeMB": 0,
  "maxSizeMB": 0,
  "exportDocsAs": "pdf",
  "outputMode": "zip",
  "zipPartSizeMB": 200,
  "preserveStructure": true,
  "compression": "store",
  "maxFiles": 5000,
  "concurrency": 5,
  "timeoutSecPerFile": 120,
  "maxRetries": 3,
  "incremental": false,
  "stateStoreName": "drive-sync-state",
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `results` (type: `string`):

No description

## `zipParts` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "folderUrl": "https://drive.google.com/drive/folders/1FYLaoscxWBV_BU5sFouf7XCrv7cKktBY"
};

// Run the Actor and wait for it to finish
const run = await client.actor("vasram/google-drive-folder-downloader").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "folderUrl": "https://drive.google.com/drive/folders/1FYLaoscxWBV_BU5sFouf7XCrv7cKktBY" }

# Run the Actor and wait for it to finish
run = client.actor("vasram/google-drive-folder-downloader").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "folderUrl": "https://drive.google.com/drive/folders/1FYLaoscxWBV_BU5sFouf7XCrv7cKktBY"
}' |
apify call vasram/google-drive-folder-downloader --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,vasram/google-drive-folder-downloader"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/462A4L1d6LPnXnJEP/builds/uL0NUAUOIkE5gjuDe/openapi.json
