---
title: "Discussion on \"How to delete all commit history in GitHub?\" | Hashnode"
description: "Discussion on \"How to delete all commit history in GitHub?\". Deleting the commit history\n1. Create Orphan Branch\nCreate a new orphan branch in git repository. The newly created branch will not show in ‘git branch’ command.\ngit checkout --orphan temp_branch\n2. Add Files to Branch\nNow add all files to the newly ..."
url: "https://hashnode.com/posts/how-to-delete-all-commit-history-in-github/62dff1788730728f62e8e7f7"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [How to delete all commit history in GitHub?](https://yacineayechi.hashnode.dev/how-to-delete-all-commit-history-in-github?utm_source=hashnode&utm_medium=feed)

Deleting the commit history 1. Create Orphan Branch Create a new orphan branch in git repository. The newly created branch will not show in ‘git branch’ command. git checkout --orphan temp\_branch 2. Add Files to Branch Now add all files to the newly ...

Jul 26, 2022 · 1 min read · yacineayechi.hashnode.dev  
Read the article

-   [#github](https://hashnode.com/tag/github)
-   [#commit](https://hashnode.com/tag/commit)
-   [#delete](https://hashnode.com/tag/delete)
-   [#history](https://hashnode.com/tag/history)
-   [#howtos](https://hashnode.com/tag/howtos)

## Written by

[Yacine Ayechi](https://hashnode.com/@YacineAyechi)

@YacineAyechi · Tunis, Tunisia

  
[View profile](https://hashnode.com/@YacineAyechi)

Front-End Web Developer

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
