High-speed multi-source downloader powered by JDownloader 2 Headless with automated Google Drive sync
CloudToDrive is an all-in-one universal multi-hoster download manager designed specifically for Google Colab and Jupyter environments. All functionality is consolidated into a single, self-contained notebook: Colab_Downloader.ipynb.
Powered by the official JDownloader 2 (JD2) Headless engine and a clean ipywidgets GUI, it crawls, resolves, and streams links from over 1,000+ file hosting providers directly into your Google Drive Downloads/ folder without filling or relying on Google Colab's virtual disk.
- All-in-One Standalone Notebook: Everything (UI, JD2 daemon service, FUSE drive streaming, and crawler) is merged into
Colab_Downloader.ipynb. No extra script files required. - Bypass Colab 87GB Disk Limit (Direct-to-Drive Streaming): Streams downloaded files directly into your mounted Google Drive (
/content/drive/MyDrive/Downloads/), completely bypassing Colab's ~80-90GB virtual disk. You can download files of 100GB, 200GB+ without running out of disk space. - Real-Time Colab Disk Space Display: A dedicated live badge updates every 2 seconds during downloads, displaying Colab's available disk space (
💾 Colab Available Disk: XX GB) to confirm that local disk space is 100% preserved. - Single-Instance Clean GUI: Uses
clear_output(wait=True)to prevent duplicate or stacked widgets, ensuring only one clean interface is shown. - Google Drive FUSE Compatibility: Automatically disables file pre-allocation/sparse file creation and enforces single-connection (
chunks = 1) sequential writes to prevent FUSE filesystem errors. - Dual Execution Modes (Cell 2):
RUN_MODE = "interactive": Interactive GUI with Queue Preview, sorting, and management buttons.RUN_MODE = "direct": Headless console/HTML streaming engine for automated, zero-UI downloading.
- Interactive GUI Features:
- Multi-line Links Input: Paste multiple URLs at once (one per line).
- "Sample Link" (Cyan): 1-click button to insert the sample Yandex Disk link (
https://disk.yandex.com/d/7OcBsRWfzoTozg, ~9.55GB) for instant speed testing. - "Resolve Links" (Green): Triggers JDownloader LinkGrabber to crawl URLs, inspect real filenames and exact sizes, and populates the Queue Preview.
- Queue Preview Management: Full toolbar with
▲ Up,▼ Down,Sort A-Z,Select All,None,▶ Start Download,Cancel, andRemove. - "Quick Download" (Blue): 1-click fully automated resolving and streaming directly into Google Drive without opening the Queue Preview.
- No Account Required: Runs via JDownloader 2's Local RemoteAPI (Port 3128) on
127.0.0.1usingmyjdapi. - Optional MyJDownloader Integration: Supports connecting your
my.jdownloader.orgaccount for remote captcha solving via mobile app/web for captcha-protected hosters.
- Open Google Colab.
- Select Upload → Upload
Colab_Downloader.ipynb. - Click Runtime → Run all (or execute Cell 1 and Cell 2 sequentially).
- Grant Google Drive access permissions when prompted.
- In Cell 2, paste any URL(s) (or click Sample Link), then click Quick Download or Resolve Links!
Colab_Downloader.ipynb: Complete all-in-one Google Colab notebook (Cell 1: Environment Setup & Drive Mount, Cell 2: Download Engine & GUI).test_downloader.py: Automated test suite verifying configuration, LinkGrabber logic, FUSE parameters, and direct streaming directly againstColab_Downloader.ipynb.README.md: English documentation.docs/README_VI.md: Vietnamese documentation.
- Bootstrap & Service Init: The notebook verifies Java JRE, fetches official
JDownloader.jar, writesorg.jdownloader.api.RemoteAPIConfig.json(opening local port3128), and launches the headless daemon. - Drive FUSE Optimization: Generates
GeneralSettings.jsonwithcreatepreallocatedlargefiles: false,maxchunksperserver: 1,maxchunksperdownload: 1, anddefaultdownloadfolder: /content/drive/MyDrive/Downloads/. - LinkGrabber & Decryption: When clicking "Resolve Links", URLs are fed into JDownloader's LinkGrabber. The crawler contacts hosters and retrieves true filenames and exact file sizes.
- Direct Google Drive Streaming: JDownloader 2 streams data sequentially directly into
/content/drive/MyDrive/Downloads/. Colab local disk space is not consumed at all.
Run the automated test suite locally:
python test_downloader.pyAll 11 unit tests verify filename sanitization, size formatting, configuration generation, LinkGrabber queues, direct streaming, real-time disk info widget, and Google Drive buffered transfers.
This project is open-source and licensed under the MIT License. All download decrypters and hoster plugins are powered by the official JDownloader 2 engine.