DEV Community

Cover image for How to Recover Deleted Github Repository
Princess
Princess

Posted on

How to Recover Deleted Github Repository

Have you ever deleted a GitHub repository and wished you hadn't? Deleting a repository might seem like a permanent action, and for a long time, I believed it was. To avoid losing valuable work, I tried my best not to delete repositories, even if they felt cluttered. However, I recently learned that it is possible to recover a deleted repository—and it only takes a few minutes!

In this article, I'll walk you through the steps to restore your deleted repositories.


Steps to Restore a Deleted Repository

1. Log in to GitHub

Start by logging into your GitHub account.


2. Access Your Profile Settings

  • Click on your profile image at the top-right corner of the screen.

    click on profile

  • From the dropdown menu, select Settings.

    click on settings


3. Navigate to Repositories

  • On the Settings page, you’ll find a sidebar on the left.
  • Under the Code, planning, and automation section, click on Repositories. click on repositories

4. Locate the Deleted Repositories

  • On the repositories page, you'll notice two tabs:

    • Repositories: Displays all your active and collaborative repositories.
    • Deleted Repositories: This is where you can find repositories you've deleted.
  • Switch to the Deleted Repositories tab.


    switch to deleted repositories


5. Restore Your Repository

  • Identify the repository you wish to restore.
  • Click on the repository name and then click the Restore button. click on restore

Additional Notes

  • Recovery Time: It might take up to an hour for a recently deleted repository to reappear after restoration. Don’t panic if you don’t see it immediately.
  • Forked Repositories: Forked repositories cannot be restored directly. For assistance, you will need to contact GitHub’s customer support team.

Conclusion

Restoring a deleted GitHub repository is a simple process that can save you from losing important work. I hope you found this guide helpful!

For a more detailed walkthrough, check out my YouTube video on this topic. Don’t forget to like and subscribe for more GitHub tips and tricks.

Top comments (1)

Collapse
 
plaincathy7 profile image
Plain Cathy

Cybersecurity Enthusiast | Writing about Digital Safety

Topics I write about:

  • Recognizing online scams, phishing, and fraud
  • Social media security best practices: 2FA, password management
  • General cybersecurity awareness and prevention

For educational purposes only. I do not provide account access services or financial recovery services. Always use official platform support for account issues.
W h a t s A p p : + 4 4 7 3 8 7 3 0 1 4 0 9