How to export your data from GitHub
GitHub lets you download a tar.gz archive of your personal account's profile and repository metadata from Settings > Account, and separately lets you back up actual repository code and history with standard Git commands or migration archives.
✓ Verified against GitHub's official documentation, August 2026
Step by step
- 1Click your profile picture in the upper-right corner of any GitHub page, then click Settings.
- 2In the left sidebar, click Account.
- 3Under 'Export account data', click Start export (or New export if you've done this before).
- 4Wait for GitHub to prepare the archive — you'll receive an email at your primary address with a download link once it's ready.
- 5Click the download link in the email and re-enter your password if prompted; you'll be redirected to a tar.gz file to download.
- 6Extract the tar.gz file (use a third-party tool if your OS can't unpack tar.gz natively).
- 7Separately, for each repository's actual code and history, clone it with git clone --mirror <repo-url> so all branches, tags, and commits come with you.
- 8To revoke a pending export link before it expires, go back to Settings > Account and click Delete next to that export.
What the export includes
- ✓Repository and profile metadata tied to your personal account's activity
- ✓Full Git commit history, branches, and tags for any repository you clone directly with Git
What it doesn't include
- ✗Full Git history/code of your repositories is not part of the account metadata export — you must clone repositories separately to get the code
- ✗The export reflects only data as of when you started it, so anything created after you clicked 'Start export' won't be included
Before you start
- ⚠The download link expires after 7 days by default
- ⚠The generated tar.gz file reflects the data stored at the time you started the export, not when you download it
- ⚠If your operating system can't open tar.gz natively, you'll need a third-party unzip tool
- ⚠Exports are managed one at a time from Settings > Account — start a new one or delete a pending one from the same screen
Where to take your data
Free and cheaper tools that can take a GitHub export. See all GitHub alternatives →
GitLab Free
Push your locally cloned --mirror copy to a new GitLab repo with git push --mirror, or use GitLab's built-in GitHub importer for repos plus (partial) issues/PRs.
GitHub Free
If you're only downgrading (not leaving GitHub), move repos into a Free-tier personal account or organization — no export/import needed, code and history stay intact.
Protocol Land
Add Protocol Land's git remote to your locally cloned repository and push your code and history there; GitHub-specific metadata like issues, PRs, and Actions won't transfer automatically.
Exporting from GitHub: common questions
Does requesting a data export affect my repositories or account?+
No — exporting your account data doesn't change or delete anything on GitHub; it just packages a copy of your metadata for you to download.
How long does the export take to prepare?+
GitHub processes it in the background and emails you a download link when it's ready. There's no published fixed turnaround time; accounts with more activity may take longer.
Can I export just one repository instead of my whole account?+
The account data export in Settings > Account covers your whole personal account's metadata. To move a single repository's code, clone it directly with Git instead.
What happens if I miss the 7-day download window?+
The link expires and you'll need to start a new export from Settings > Account.
Do I need a paid plan to export my account data?+
No — the export is available from Settings > Account on any personal GitHub.com account, regardless of plan.
How do I take issues, pull requests, and wikis with me, not just code?+
A plain git clone only captures code and commit history. Issues, PRs, and wikis require GitHub's migration archive/API or a third-party migration tool in addition to cloning the repo.
Sources
This guide was written from GitHub's own documentation and checked against it in August 2026. If a step has changed, the official page wins.
GitHub head-to-head
More Dev Tools tools people are leaving
All Dev Tools alternatives →What would you save without GitHub?
Pick your team size and see the yearly number.