Github how to delete Repository

Problem

Your boss is complaining that you have too many repositories on GitHub and need to delete some?

Your old projects are over and you want to clean up by deleting old repositories on GitHub?

I will show you how to delete a repository on GitHub.

Open your Repository on GitHub in your browser. Login into your account.

The url should be something like: https://github.com/$username/$repository

$username is your username

$repository is the name of the repository

e.g. $username frank, $repository backend: https://github.com/frank/backend

GitHub how to delete repository Settings

Go to the Settings menu, at the right side of the menu

There scroll down to Danger Zone, delete your repository

GitHub how to delete repository

Click on “Delete this repository”. GitHub now requests your confirmation that you really want to delete it.

Read the warnings carefully and make sure you understand them. Then type the repositories name into the textfield. The format is $username/$repositoryname, e.g. frank/backend

github how to delete repository Confirmation

The disabled button will turn enabled when you entered the correct name. Click it and you´re done.

This is how you delete a repository on GitHub.

Notes

  1. Deleting a repository can not be undone. Once it´s deleted it´s gone.

Under some circumstances this might not be true, to be safe expect that once you delete the repository, it´s gone, scrubbed, the file system space overwritten.

2. Deleting a private repository will delete all of it´s forks. Deleting a public repository will not delete it´s forks.

So if you have a private repository and others created a fork from your code, those forks will be deleted. But if your repository was public, the forks remain.

3. Attached releases and team permissions will be deleted.

I hope this helped you and answered your questions.

Let me know when it helped.

Best,

Frank

Sources:

https://docs.github.com/en/[email protected]/github/administering-a-repository/deleting-a-repository

Leave a Reply