Git For Windows should be installed on your machine, and make sure you have information about installation path of Git. By default selected paths are (C:\Program Files\Git or C:\Program Files (x86)\Git)
Now you need to register Git in the windows environment variable ecosystem.
Using My Computer or Windows Explorer(explorer.exe), right click on My Computer and select Properties.
From the left pane, select Advanced System Settings option.
In Advanced Tab, Select Environment Variables button from the bottom of the window.
From System Variables, try to find Path variable and then click on edit to add Git to it.
For Windows 10:
Add reference of Git CMD and Binary to Path Variable as two separate values
For Win 7/8:
Add reference of Git CMD and Binary to Path Variable at the end of the string like this:
Now Restart CMD/PowerShell after Path variable update
git in CMD/Powershell and now make sure that it recognize the command.