Are you an aspiring Developer? If so, then, you must be aware of the Git software used by developers working for the same company. One of the errors associated with this software is ‘git’ is not recognized as an internal or external command, operable program or batch file message. There are various reasons for which the error message pops up on your PC and you might be perplexed by this error message. This article provides the methods to fix the git is not recognized as an internal or external command error message on Windows 10 PC.
How to Fix ‘git’ is Not Recognized as an Internal or External Command
The Git software is created by Linus Torvalds, who is responsible for the development of the Linux kernel, in 2005.
Contents
How to Fix ‘git’ is Not Recognized as an Internal or External Command
What Causes ‘git’ is Not Recognized as an Internal or External Command Error?
Method 1: Restart Command Prompt
Method 2: Manually Add Variable Path
Method 3: Reinstall Git Software
The Git software is a DevOps tool that is used for source code management.
The software creates a copy of the code developed by the developers locally on the PCs.
This allows the developers to create backups of their code and also track the changes in the source code.
This way, regular communication between the developers is established, and the developers can work together on non-linear development.
The main advantage of this software is that it is free and open-source software.
This Control system allows the developers to handle small to very large projects efficiently.
What Causes ‘git’ is Not Recognized as an Internal or External Command Error?
The list of causes for the error message with the Git software are listed below as:
- Git Software is not installed on your PC– The Git software might have not been installed on your PC.
- Issues with Command Prompt app– The Command Prompt app might be either open during the installation process or might have not been reloaded after the installation. In this case, the Command Prompt app cannot access the Git software.
- Git Path is unavailable or not set on your PC– The Location path for the Git software might not be set or is missing from your PC.
Method 1: Restart Command Prompt
The basic troubleshooting method to fix the error is to restart the Command Prompt app on your PC.
Step I: Close Command Prompt App
The first step is to close all the instances of the Command Prompt app using the Task Manager app.
Press the Ctrl+ Shift+ Esc keys at the same time to open the Task Manager app.
Select the Windows Command Processor app in the Apps section and click on the End Task button.
Step II: Launch Command Prompt App
The next step is to launch the Command Prompt app on your PC and activate the git command on the app. Check if git is not recognized as an internal or external command error message is fixed.
- Press the Windows key, type Command Prompt and click on the Open option to launch the Command Prompt app.
Note: Alternatively, you can click on the Run as Administrator option if you cannot use the Command Prompt app.
- Type the git command and press the Enter key.
Also Read: How to Fix Git Merge Error
Method 2: Manually Add Variable Path
The next step to fix the error is to add the variable path of the Git software manually to your PC.
Step I: Copy Location Path of git.exe File
As a first step, you have to copy the location path of the executable file of the Git software from the download location in Windows Explorer.
- Open the Windows Explorer using the Windows+ E keys and navigate to the cmd folder using the location path as
This PC > Local Disk (C:) > Program Files (x86) > Git > cmd
Note: The above path is valid for the x86 architecture Windows PC. If you are using the x64 version, use the location path as
This PC > Local Disk (C:) > Program Files > Git > cmd
In the cmd folder, right-click on the git.exe file and click on the Properties option in the list.
In the General tab, copy the default location in the Location section using the Ctrl+ C keys.
Also Read: Fix Not Enough Storage is Available to Process this Command
Step II: Set Path in System Properties
The next step is to set the path of the Git software or add the variable path manually to your PC using the System Properties. This allows you to fix the git is not recognized as an internal or external command, operable program or batch file error message.
Press the Windows + R keys together to open the Run dialog box.
Type the sysdm.cpl in the Open bar, and click on the OK button.
In the System Properties, navigate to the Advanced tab and click on the Environment Variables… button.
Select the Path entry in the System variables section and click on the Edit… button.
Click on the New button on the Edit environment variables screen.
Press the Ctrl + V keys together to paste the copied location from the git Properties window and click on the OK button.
Click on the OK button on the Environmental Variables window.
Finally, click on the Apply and OK buttons on the System Properties window.
Method 3: Reinstall Git Software
The last method to fix git is not recognized as an internal or external command, operable program or batch file error is to reinstall the Git software on your PC.
Step I: Uninstall GIT Software
As a first step, you have to uninstall the Git software installed on your PC using the Control Panel app.
Hit the Windows key, type Control Panel and click on Open.
Set View by > Category, then in the Programs section, click on the Uninstall a Program option.
Select the GIT app and click on the Uninstall button at the top bar.
Follow the on-screen instructions to uninstall the GIT app and Restart your PC from the START menu.
Also Read: Fix Command Failed With Error Code 1 Python Egg Info
Step II: Reinstall GIT Software
The next step is to install the latest version of the Git software from your default web browser on your PC.
Press the Windows key, type Google Chrome, then click on Open.
Open the official website of the Git-Downloads and click on the Download for Windows button in the Downloads section.
Double-click on the executable file of Git to run the file.
Leave all the options to default in the on-screen instructions on the installation wizard and click on the Next button.
In the Adjusting your PATH environment window, select Git from the command line and also from the 3rd-party software option and click on the Next button.
Note: This option sets the variable path of the Git software manually on your PC.
Follow the instructions on further windows and click on the Install button on the Configuring experimental options window.
Finally, reboot your PC and now you will be able to run the command directly from the Command Prompt app.
Recommended:
- How to Put Out a Campfire in Minecraft
- How to Delete Upwork Account
- Fix Unable to Start Program Visual Studio Access is Denied
- How to Delete Github Account Permanently
The methods to fix git is not recognized as an internal or external command, operable program or batch file error message are given in this article. Please leave your suggestions are queries on the error message in the Comments.