How To Delete A File From GitHub?

Open the repository on GitHub

Navigate to the file you want to delete

Click the file to open it

Click the trash can icon or the Delete file button

Add a commit message

Choose whether to commit directly to the default branch or create a new branch

Click Commit changes

If the file is tracked locally, delete it from your local repository too

Run `git add -u`

Run `git commit -m “Delete file”`

Run `git push`

Suggested for You

Trending Today