%3C%21-- Google Tag Manager --%3E %3C%21-- End Google Tag Manager --%3E

How do I make Git remember my credentials?

If you’re accessing your Git repositories over HTTPS protocol you may have noticed that some Git clients keep asking your login and password on each operation. This can be very annoying, especially if you are pushing and pulling a lot of changes throughout the day. While some clients know how to remember your credentials, others need some additional tuning. Continue reading this article to find a solution for your client.

GUI Clients

Most GUI clients such as Tower for Mac and Gitbox know how to remember credentials, so you don’t have to do anything. Just enter your username and password once and you will be all set.

Command Line

Command line Git client will not remember your credentials out of the box. Make sure you are running Git version 1.7.12.1 or higher, then use the following command to enable password caching:

git config --global credential.helper cache

This will make git remember your credentials for 15 minutes after you entered them. To increase that limit use the following command and specify time in seconds:

git config --global credential.helper 'cache --timeout=3600'

For more information about the credential helper refer to the official Git documentation.

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us