Package Information
Documentation
n8n-nodes-google-drive-recursive
This is an n8n community node. It lets you generate a folder tree structure or recursive file list from Google Drive in your n8n workflows, with flexible resource selection and output modes.
Core node for Google Drive can only list files in a single folder, this node recursively lists all files and folders starting from a given root folder ID.
Originally forked from pavelsterba/n8n-nodes-google-drive-tree
n8n is a fair-code licensed workflow automation platform.
šÆ What's New
- Resource Selector: Choose folders by ID or from a searchable list
- Output Mode: Get results as hierarchical tree or flat file list
- Dynamic Folder Loading: Dropdown of all available folders (no need to know IDs!)
- Better Integration: Easier loops and data processing with file list output
Installation
Follow the installation guide in the n8n community nodes documentation.
For Self Hosted/Community Edition N8N Users:
Settings -> Community Nodes -> Install -> n8n-nodes-google-drive-recursive
Credentials
You need to authenticate with googleDriveOAuth2Api credentials.
Usage - Quick Examples
Example 1: Get All Files as a List
Resource: By ID
Folder ID: root
Output Mode: File List
Returns: Array of files ready for loops and processing
Example 2: Browse Folder Structure
Resource: By List
Folder: [Select from dropdown]
Output Mode: Tree
Returns: Hierarchical tree structure
Example 3: Process Files in Loop
Resource: By List
Folder: Marketing
Output Mode: File List
ā For Each Loop
ā Download file
ā Extract text
ā Save to database
Features
ā Two Resource Selection Methods
- By ID: Specify folder ID directly (backward compatible)
- By List: Choose from searchable dropdown of all your folders (new!)
ā Two Output Formats
- Tree: Hierarchical structure with nested children (original)
- File List: Flat JSON array with parent references (new, great for loops!)
ā Full Capabilities
- Recursive folder traversal
- Pagination support (handles 100,000+ items)
- Shared drive support
- Dynamic folder discovery
- Complete MIME type information
ā Advanced Filtering (v1.0.1-beta.16+)
- File Type Filter: Include/exclude specific MIME types
- Property Filters: Search by custom Google Drive properties
- Starred Filter: Include only starred items
- Fields Selection: Choose which metadata to retrieve
- ā ļø Guaranteed Recursion: Filters are applied AFTER recursion completes, ensuring all folders are traversed
Important: Filters are applied to the complete recursively-collected file list (post-processing), NOT during API queries. This ensures that filtering doesn't interrupt folder traversal. For example, if you filter by "PDF files only", the node still traverses ALL folders to find PDFs nested deep in the structure.
Output Format Examples
Tree Mode
{
"id": "folder1",
"name": "Projects",
"mimeType": "application/vnd.google-apps.folder",
"children": [
{
"id": "doc1",
"name": "Proposal.pdf",
"mimeType": "application/pdf",
"children": []
}
]
}
File List Mode (Array of Objects)
[
{
"id": "folder1",
"name": "Projects",
"mimeType": "application/vnd.google-apps.folder",
"parents": ["root"]
},
{
"id": "doc1",
"name": "Proposal.pdf",
"mimeType": "application/pdf",
"parents": ["folder1"]
}
]
Common Workflows
- File Inventory Report - Export all files to CSV
- Sync to Database - Mirror folder structure in your database
- Smart Processing - Different handling for PDFs, Docs, Sheets
- File Discovery - Find and analyze specific file types
- Folder Backup - Audit what's in your Drive
- RAG Sync - Implement with RAG Workflows easily in one step
Support
For detailed information:
- š Getting started? ā BEFORE_AFTER_COMPARISON.md
- š” Need examples? ā INTEGRATION_GUIDE.md
- š§ Want to modify? ā CODE_STRUCTURE.md
- ļæ½ Filtering deep dive? ā FILTERING_ARCHITECTURE.md
- ļæ½š Need everything? ā DOCUMENTATION_INDEX.md