In this article we are going to cover How to Delete GitHub Repository/ How to Remove Repository GitHub, How to Delete GitHub Repository Command Line.
Things to understand before deleting a repository in GitHub:
- Once a repository is deleted, we cannot restore it again. So we have to think twice make sure about deleting the repository in GitHub.
- If your repository is private repository then all forks will get deleted with the repository in GitHub.
- If your repository is a public repository then the forks will not be deleted in GitHub.
- We can delete the repository if we have admin permission.
Table of Contents
Step #1: Go to your GitHub account and Sign in
Login to GitHub with your GitHub username and password, once logged in As we can see a icon at right top corner, we have click on that icon and has to select on “Your repositories”.
![How to Delete GitHub Repository [5 Steps] 1](https://www.fosstechnix.com/wp-content/uploads/2021/04/go-to-github-profile_1.jpg)
Step #2: Select GitHub Repository to Delete
Here you will see list of all repositories in your current GitHub account, Click on the particular repository which you have to delete.
In this case we have only one repository i.e. intern2021, Click on “intern2021”.
![How to Delete GitHub Repository [5 Steps] 2](https://www.fosstechnix.com/wp-content/uploads/2021/04/select-repo-in-github_2-1024x336.png)
Step #3: Go to GitHub Repo settings
After clicking on repository (intern2021) we can see a code tab issues tab, etc and at last there is a settings tab. Click on “settings”.
![How to Delete GitHub Repository [5 Steps] 3](https://www.fosstechnix.com/wp-content/uploads/2021/04/go-to-github-repo-settings_3-1024x269.png)
Step #4: Delete GitHub Repository
After clicking on settings, go at the bottom on that page, After going at bottom we see a section named Danger Zone, In that section there is last option – Delete this repository, Click on “ Delete this repository”.
![How to Delete GitHub Repository [5 Steps] 4](https://www.fosstechnix.com/wp-content/uploads/2021/04/click-on-delete-this-repository_4-1024x408.png)
After clicking on Delete this repository, GitHub will ask you- Are you absolutely sure?
![How to Delete GitHub Repository [5 Steps] 5](https://www.fosstechnix.com/wp-content/uploads/2021/04/Are-you-absolutely-sure_5.png)
Type the github repo name to delete in textbox to confirm, and click on “I understand the consequences, delete this repository”
![How to Delete GitHub Repository [5 Steps] 6](https://www.fosstechnix.com/wp-content/uploads/2021/04/enter-repo-name-to-delete_6.png)
Step #5: To delete the GitHub repository, GitHub will ask for password for authentication
To delete the GitHub repository, GitHub will ask for password for authentication.
![How to Delete GitHub Repository [5 Steps] 7](https://www.fosstechnix.com/wp-content/uploads/2021/04/github-will-ask-password_7.png)
Enter your password and click on “Confirm password”.
![How to Delete GitHub Repository [5 Steps] 8](https://www.fosstechnix.com/wp-content/uploads/2021/04/enter-github-password_8.png)
GitHub Repository “intern2021” is deleted successfully.
![How to Delete GitHub Repository [5 Steps] 9](https://www.fosstechnix.com/wp-content/uploads/2021/04/github-repo-deleted_9-1024x373.png)
How to Delete GitHub Repository Command Line
To Delete GitHub Repository Command Line, run below command.
rm -rf .git
Conclusion:
We have covered How to Delete GitHub Repository/ How to Remove Repository GitHub, How to Delete GitHub Repository Command Line.
Related Articles: