Skip to main content
Guides Menu

How to Install Git on Windows

Install Git on Windows so you can clone repositories, commit changes, use Git Bash, and run git from any terminal.

Priyanka Kasera
April 2026·5 min read

Supported Versions

2.53.0

Official Source

git-scm.com / GitHub (official)

Environment Setup

1 PATH entry

Verify Step

git --version

DevTools Installer is not affiliated with, endorsed by, or sponsored by the publisher of Git. All product names and logos are trademarks of their respective owners. Downloads are sourced directly from the official publisher.

Install With DevTools Installer

Use this path if you want DevTools Installer to download the official package and handle the Windows setup for you.

  1. 1Open DevTools Installer.
  2. 2In Version Control, select "Git".
  3. 3Click "Install Selected".
  4. 4Let the installer download the official package, run it silently, and add to PATH.
  5. 5Open a new terminal window after the install finishes.
  6. 6Run to confirm Git is available.

Download Source

DevTools Installer downloads from the official publisher:

https://github.com/git-for-windows/git/releases/download/v2.53.0.windows.1/Git-2.53.0-64-bit.exe

PATH & Environment Variables

DevTools Installer sets the following automatically:

PATH entries

C:\Program Files\Git\cmd

Verification

DevTools Installer verifies the install by running:

git --version

Expected output: git version 2.53.0.windows.1

Manual Installation Steps

Use these steps if you want to run the installer yourself and apply the Windows PATH or environment changes manually.

  1. 1Download the official installer from https://github.com/git-for-windows/git/releases/download/v2.53.0.windows.1/Git-2.53.0-64-bit.exe
  2. 2Run the installer and keep the default options unless your team requires different line-ending or SSH settings.
  3. 3Git for Windows adds to PATH automatically.
  4. 4Open a new terminal and run .
  5. 5Run the first-time setup commands in this guide to set your name, email, default branch, and line-ending behavior.

Need to upgrade, downgrade, or remove Git?

DevTools Installer can also upgrade Git to a newer version, roll back to an older one, or cleanly uninstall it — including PATH entries and environment variables. No manual cleanup required.

What Is Git Used For?

  • Tracking changes to source code across individual and team projects.
  • Collaborating on open-source or private repositories hosted on GitHub, GitLab, or Bitbucket.
  • Branching and merging workflows for feature development, hotfixes, and releases.
  • Integrating with CI/CD pipelines — Git is the trigger for nearly every modern build system.
  • Managing dotfiles, configuration repos, and infrastructure-as-code projects.

First-Time Setup

After installing, run these commands in a new terminal to configure Git for your identity and preferences:

Set your display name — appears on every commit and is visible on GitHub

git config --global user.name "Your Name"

Set the email that identifies your commits (use the same email as your GitHub account)

git config --global user.email "you@example.com"

Set "main" as the default branch name for all new repositories

git config --global init.defaultBranch main

Automatically convert Unix line endings (LF) to Windows (CRLF) on checkout, and back on commit

git config --global core.autocrlf true

Common Issues And Fixes

Check the problem and the exact fix before you reinstall anything. Some guides also include the reason the issue happens.

Problem

"git" is not recognized after installation

Exact fix

Git for Windows adds C:\Program Files\Git\cmd to PATH. Close and reopen your terminal or restart your IDE. Run "where git" to verify the binary is found.

Problem

Line ending warnings (LF vs CRLF) on every commit

Exact fix

Configure Git to handle line endings consistently: run "git config --global core.autocrlf true" on Windows. This converts LF to CRLF on checkout and back on commit.

Problem

SSH authentication fails when pushing to GitHub

Exact fix

Generate an SSH key with "ssh-keygen -t ed25519" and add the public key to your GitHub account under Settings → SSH Keys. Test with "ssh -T git@github.com".

Problem

Git Bash or Git GUI are missing from the context menu

Exact fix

Re-run the Git installer and ensure "Windows Explorer integration" is checked. Alternatively, add the registry entries manually for the context menu items.

Tips for Git

  • After installing Git, configure your identity immediately: "git config --global user.name Your Name" and "git config --global user.email you@example.com".
  • Git for Windows includes Git Bash (a UNIX-like terminal), Git GUI, and integration with Windows Credential Manager for HTTPS authentication.
  • If you prefer a visual interface, install GitHub Desktop alongside Git for a GUI-based workflow.
  • Use "git config --global init.defaultBranch main" to set "main" as the default branch name for new repositories.

Related Guides

Back to All Guides