How to Create a Private Repository¶
โ Back to Git
๐ Create a Private Repository¶
A private repository is only visible to you and people you explicitly invite.
1. Start New Repository¶
Click on the New button on your repository list or dashboard.

2. Configure Settings¶
- Enter a Repository name.
- Select Private (this creates a private repo).
- Check Add a README file (recommended to initialize the repo).
- Click Create repository.

The repository will be marked with a Private badge next to its name.

๐ Authentication¶
Since the repository is private, you need to authenticate to clone or push to it. There are two common methods:
- Personal Access Token (PAT) (Recommended for HTTPS)
- SSH Keys
Remote vs Local¶
Understanding the connection:

๐ฅ Watch on YouTube:¶
๐ง Quick Quiz โ Private Repos¶
#
Who can view a Private repository on GitHub?
๐ Want More Practice?¶
๐ Start Git Intermediate Quiz (20 Questions)
๐ฌ DevopsPilot Weekly โ Learn DevOps, Cloud & Gen AI the simple way.
๐ Subscribe here
