Git is the version control system most frequently used. Git tracks your file modifications, so you have a record of what was done and if you have to return to some versions. Git also simplifies collaboration, such that modifications can be combined into one source by numerous people.
So Git is valuable for you regardless of whether you solely write code you're going to view or work in a team.
Git is locally running software. Your files are kept on your computer with their history. Also, a copy of the files and their revision history may be saved using the Online Hosts (such as GitHub and Bitbucket). With a central location, you can submit your changes and retrieve changes from others, so you can work with other developers more easily. Git can automatically combine the changes in order for two persons to work on various portions of the same file and then integrate those modifications without losing their jobs!
A Git repository (or short repository) includes all the project files and the whole revision history. You are going to take the usual file folder (e.g., the root folder of a website) and tell Git to make it a repository. This generates an a.git subfolder with all the Git metadata to track modifications.
In Unix-based operating systems like macOS, a period of files and folders (.) is hidden. Thus, you won't see the.git folder in the macOS Finder until you display hidden files. It's there! Perhaps with some coding editors, you can see it.