--- id: pydrive2 version: "1.21.3" license: Apache License 2.0 license_treatment: permissive maintenance: active --- # PyDrive2 — Google Drive API made easy. Maintained fork of PyDrive. License: permissive · Maintenance: active · Downloads: 1.1M/mo ## What it is and what it does PyDrive2 is a maintained fork of the original PyDrive, built to simplify working with Google Drive through Python. It wraps google-api-python-client into higher-level classes representing Drive resources (files, folders) and handles OAuth2 authentication in just a few lines of code. Instead of writing raw API calls, you work with objects—create files, set content, upload, download, and query with methods like CreateFile(), Upload(), and GetContentFile(). The package automates common friction points: OAuth2 setup via settings.yaml, pagination through file listings, and efficient upload/update logic that chooses the right API method (insert, patch, or update) based on what changed. It also provides an fsspec-compatible filesystem interface for treating Google Drive like a local filesystem. Supports Python 3.8+ and carries no known security vulnerabilities. Use it for: - Automate bulk file uploads or downloads to/from Google Drive in a data pipeline or backup script. - Build a Python application that needs OAuth2-authenticated access to a user's Drive without writing low-level API boilerplate. - Implement file listing and search with automatic pagination handling across large Drive directories. - Use Google Drive as a remote filesystem backend via fsspec for seamless integration with tools like DVC or data processing workflows. - Manage shared Drive resources programmatically (create, update, delete files) in a team collaboration tool. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. PyDrive2 simplifies Google Drive API V2 operations by wrapping the low-level client library into object-oriented classes and automating OAuth2 authentication, file uploads, downloads, and pagination. Yes. PyDrive2 is actively maintained, carries no known vulnerabilities, has low install friction, and solves a real problem—Google Drive API V2 is verbose and requires careful OAuth2 setup. If you need to interact with Google Drive from Python, this wrapper saves substantial boilerplate. The permissive Apache 2.0 license poses no restriction. The only gotcha is the OAuth2 flow setup; read the documentation first. ## Install pip install pydrive2 uv add pydrive2 poetry add pydrive2 ## Installing PyDrive2 Before you install: Low install friction with a pure Python wheel. Actively maintained as of 2026-08-05 with recent release activity; maintained by the DVC project team. Five runtime dependencies including google-api-python-client and oauth2client handle the underlying API and authentication. License in practice: Licensed under Apache License 2.0 (permissive), allowing use in commercial and private projects with minimal restrictions beyond attribution and liability disclaimers. Quickstart: pip install PyDrive2 from pydrive2.auth import GoogleAuth from pydrive2.drive import GoogleDrive gauth = GoogleAuth() gauth.LocalWebserverAuth() drive = GoogleDrive(gauth) file_list = drive.ListFile({'q': "'root' in parents"}).GetList() Requires client_secrets.json from Google API Console and local web server access for OAuth2 authentication flow. Verify before relying: - Whether the fsspec integration (GDriveFileSystem) is production-ready or still experimental. - Performance characteristics when handling large file uploads or working with deeply nested directory structures. - Concurrency guarantees beyond the stated thread-safety claim—whether it handles quota limits or rate limiting. ## Package facts - License: Apache License 2.0 (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 1.1M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags google drive api wrapper, oauth2 google drive, upload download files google drive, google drive file management, drive api python, google drive pagination, fsspec google drive, google-drive, oauth2, file-management [View on SkillFed](https://skillfed.io/packages/pydrive2) · [View on PyPI](https://pypi.org/project/pydrive2/)