A powerful, pixel-perfect, single-page web application to download files or folders from GitHub repositories. It supports public URLs, private repositories (via Token), and requires no server.
- Download Sub-folders: Download any specific folder from a repo as a ZIP.
- Client-Side Only: Works 100% in the browser (GitHub Pages / Vercel compatible).
- Smart Routing: Share links like
https://gitfolderdownloader.github.io/?=https://github.com/user/repoto auto-start downloads. - Private Repo Support: Enter a Personal Access Token (stored locally) to access private files.
- Partial Downloads: Download large repositories in steps (e.g., files 0-100) to avoid browser limits.
- Beautiful UI: Smooth animations, file previews, and progress bars.
- Theming: 8 Themes including Dracula, Cyberpunk, AMOLED, and more.
To share a direct download link with a friend, simply add the GitHub URL after the hash (?=):
https://gitfolderdownloader.github.io/?=https://github.com/facebook/react/tree/main/packages
If a repository is too large, you can limit the number of files to download using &st (Start) and &mx (Max).
&st=50: Start downloading from the 50th file.&mx=150: Stop downloading at the 150th file.
When the user visits this link, the app will:
- Parse the URL.
- Auto-fill the input and limit fields.
- Immediately start fetching and zipping files 50 to 150.
- Generate a GitHub Token (Settings > Developer Settings > Personal Access Tokens).
- Scopes needed:
repo(for private) or just public access. - Open Git Folder Downloader > Click Gear Icon (⚙️).
- Paste token. It is saved in your browser's LocalStorage and never sent to any 3rd party server.
To embed a direct download link within your website/page, simply use this pattern. The API also supports the &st and &mx parameters.
<!-- Download all files -->
<a href="https://gitfolderdownloader.github.io/api/?=https://github.com/facebook/react/tree/main/packages&name=react-core">Download Core</a>
<!-- Download files 0 to 100 only -->
<a href="https://gitfolderdownloader.github.io/api/?=https://github.com/facebook/react/tree/main/packages&name=react-core&st=0&mx=100">Download Part 1</a>function triggerDownload() {
const repo = "https://github.com/facebook/react/tree/main/packages";
// Optional: Add limits for large folders
const params = "&st=0&mx=200";
const apiUrl = `https://gitfolderdownloader.GitHub.io/api/?url=${repo}${params}`;
window.open(apiUrl, '_blank');
}gitfolderdownloader also provides a GitHub-integrated userscript that adds a native-looking Download button directly inside GitHub menus.
- Injects a “Download Repo / Folder / File” action into GitHub’s context menus
- Automatically detects:
- Repository menu → shows Download Repo
- Folder menu → shows Download Folder
- File menu → shows Download
- Opens a GitHub-themed custom popup to set an optional download name
- Auto-fills the popup with the current repo / folder / file name
- Fully matches GitHub light & dark themes
- Uses the official gitfolderdownloader API under the hood
- Tampermonkey
- Violentmonkey
- ScriptRunner (Chromium-based extensions)
- Other userscript-compatible extensions
- Install a userscript manager (Tampermonkey / ScriptRunner).
- Create a new userscript.
- Paste the provided gitfolderdownloader userscript code or direct link in url bar.
- Save and enable the script.
- Visit any GitHub repository, folder, or file.
- Open the GitHub menu → click Download Repo / Folder / Download.
No configuration required. Works instantly on GitHub pages.
The gitfolderdownloader userscript can also be packaged as a lightweight browser extension using ScriptRunner-style extensions.
- Zero background services
- No permissions beyond GitHub pages
- Runs fully client-side
- Injects UI only when GitHub menus are detected
- SPA-safe (works with GitHub Turbo / PJAX navigation)
- Personal daily GitHub usage
- Developers frequently downloading subfolders
- Lightweight alternative to full GitHub downloader extensions
- No tracking, no analytics, no servers
- No data is collected
- No GitHub tokens are accessed by the script
- Downloads are handled entirely by gitfolderdownloader API in a new tab
Feel free to open issues or submit PRs. The code is written in JS/CSS for maximum simplicity and performance.