Google Drive Ownership Migration Automation
A resumable Google Apps Script solution that rebuilt third-party folder trees, replaced externally owned files with user-owned copies, and logged every action for auditability.
About the Project
We built a Google Drive migration utility for a client that needed to clean ownership issues before moving a large folder structure into a Shared Drive.
The main challenge was that Google Drive can copy files, but not folders. Whenever a subfolder belonged to a third party, the script had to recreate that folder manually, transplant its contents into a new user-owned structure, and preserve the effective hierarchy recursively.
To make the process usable in real-world migrations, we designed it as a resumable workflow with duplicate avoidance, explicit audit logging, error capture, and protections for the reporting sheet itself.

Key Features
- Recursive processing of folders, subfolders, and files
- Automatic replacement of third-party-owned files with user-owned copies
- Manual reconstruction of third-party folder trees where direct copy was impossible
- Detailed spreadsheet audit log with original owner, path, item ID, and status
- Resumable execution model for large migrations under Google Apps Script time limits
- Progress tracking to avoid duplicate work across multiple runs
- Safe handling of both native Google files and non-Google files
