How to fix git: 'credential-manager' is not a git command in Git

GitBEGINNERLOWUpdated Dec 6, 2025ยท 329 views

The 'credential-manager is not a git command' error occurs when Git cannot find the credential helper executable. This typically happens when Git Credential Manager is not installed, has been renamed, or the configuration points to an outdated helper name.

Quick fix

Fixes git: 'credential-manager' is not a git command

# Show all credential.helper settings with their source files
git config --list --show-origin | grep credential

# Check specifically what credential helper is set
git config --get-all credential.helper
  1. Check your current credential helper configuration
  2. Update credential helper to use correct name
  3. Remove the invalid credential helper configuration
  4. Install Git Credential Manager
git โ€” error
# Show all credential.helper settings with their source files
git config --list --show-origin | grep credential
# Check specifically what credential helper is set
git config --get-all credential.helper
git: 'credential-manager' is not a git command

What this error means

This error indicates that Git is trying to use a credential helper called "credential-manager" but cannot find it as a valid Git command or executable. When you interact with remote repositories over HTTPS, Git uses credential helpers to store and retrieve your authentication credentials (like Personal Access Tokens). The credential helper is configured in your Git config via `credential.helper`. If this setting points to a helper that doesn't exist or uses an outdated name, Git reports this error. The most common scenario is having leftover configuration from an older version of Git Credential Manager. In Git 2.39 and later, the credential helper was renamed from `manager-core` to simply `manager`. Additionally, some systems may have configuration referencing `credential-manager` (with a hyphen) which was the legacy helper name from Git Credential Manager for Windows.

Typical symptoms

  • Error message appears when running git push, pull, fetch, or clone
  • Warning shows: git: 'credential-manager' is not a git command. See 'git --help'
  • Git operations complete but show the error message first
  • Error occurs after upgrading Git or Git Credential Manager
  • Error appears after installing a new version of Git for Windows
  • Multiple credential helper warnings appear sequentially
  • Authentication prompts appear unexpectedly despite having stored credentials
  • Error message mentions 'credential-manager-core' instead of 'credential-manager'

Common causes

  1. Git Credential Manager is not installed on your system
  2. Git configuration references outdated helper name (credential-manager instead of manager)
  3. Configuration left over from uninstalled Git Credential Manager
  4. Git was installed without the credential manager component
  5. System and global git configs have conflicting credential.helper values
  6. Git Credential Manager was renamed in a recent update (manager-core to manager)
  7. Path to the credential helper executable is not in system PATH
  8. Corrupted Git installation missing credential helper binaries

How to fix "git: 'credential-manager' is not a git command"

1Check your current credential helper configuration

First, identify which credential helper(s) are configured and where they're defined:

bash
# Show all credential.helper settings with their source files
git config --list --show-origin | grep credential

# Check specifically what credential helper is set
git config --get-all credential.helper

This will show you output like:

bash
file:/home/user/.gitconfig    credential.helper=manager
file:/etc/gitconfig    credential.helper=credential-manager

The source file path tells you where each setting comes from (global vs system vs local config).

2Update credential helper to use correct name

The credential helper name has changed over time. Update your configuration to use the modern name:

For Git 2.39 and later (recommended):

bash
# Set the credential helper to 'manager' (current name)
git config --global credential.helper manager

If you're on an older Git version:

bash
# Use 'manager-core' for older GCM versions
git config --global credential.helper manager-core

If you have multiple conflicting settings:

bash
# Replace all credential.helper values with the correct one
git config --global credential.helper manager --replace-all

After setting this, try your Git operation again.

3Remove the invalid credential helper configuration

If you don't need the credential helper or want to reconfigure from scratch, remove the problematic setting:

bash
# Remove from global config
git config --global --unset credential.helper

# If there are multiple values, unset all of them
git config --global --unset-all credential.helper

For system-level configuration (requires admin/root):

bash
# On Linux/macOS
sudo git config --system --unset credential.helper

# On Windows (run as Administrator)
git config --system --unset credential.helper

Edit the config file directly if needed:

bash
# Open global config in editor
git config --global --edit

# Look for and remove the [credential] section:
# [credential]
#     helper = credential-manager  <- remove this line

On Windows, check these locations:
- User config: %USERPROFILE%\.gitconfig
- System config: C:\Program Files\Git\etc\gitconfig

4Install Git Credential Manager

If Git Credential Manager is not installed, install it:

On Windows:
Git Credential Manager comes bundled with Git for Windows. Reinstall Git for Windows from [git-scm.com](https://git-scm.com/download/win) and make sure to select the Git Credential Manager option during installation.

On macOS:

bash
# Install via Homebrew
brew install git-credential-manager

# Configure Git to use it
git-credential-manager configure

On Linux (Debian/Ubuntu):

bash
# Download the latest .deb package from GitHub releases
# https://github.com/git-ecosystem/git-credential-manager/releases

# Install the package
sudo dpkg -i gcm-linux_amd64.X.X.X.deb

# Configure Git to use it
git-credential-manager configure

Using .NET tool (cross-platform):

bash
# Requires .NET SDK 8.0+
dotnet tool install -g git-credential-manager

# Configure Git to use it
git-credential-manager configure
5Use an alternative credential storage method

If you don't want to use Git Credential Manager, configure an alternative:

Cache credentials in memory temporarily:

bash
# Cache for 1 hour (3600 seconds)
git config --global credential.helper 'cache --timeout=3600'

Store credentials in a plain text file (less secure):

bash
git config --global credential.helper store
# Credentials saved to ~/.git-credentials

On macOS, use the built-in Keychain:

bash
git config --global credential.helper osxkeychain

On Linux with GNOME Keyring:

bash
git config --global credential.helper /usr/share/doc/git/contrib/credential/gnome-keyring/git-credential-gnome-keyring

Or simply use SSH instead of HTTPS (no credential helper needed):

bash
# Change remote from HTTPS to SSH
git remote set-url origin git@github.com:username/repo.git
6Create an alias as a workaround

If you're getting the error because configuration references credential-manager but you have credential-manager-core installed (or vice versa), you can create a Git alias as a quick workaround:

bash
# If error is about 'credential-manager' but you have 'manager-core'
git config --global alias.credential-manager "credential-manager-core"

# If error is about 'credential-manager-core' but you have 'manager'
git config --global alias.credential-manager-core "credential-manager"

Note: This is a temporary workaround. The proper solution is to update your credential.helper configuration to match your installed version (Step 2).

7Verify the fix

After applying the fix, verify that the error is resolved:

bash
# Check the current credential helper
git config credential.helper

# Test by fetching from a remote repository
git fetch origin

# Or test the credential helper directly
git credential-manager --version
# Or for older versions:
git credential-manager-core --version

If the command succeeds without the "not a git command" error, the issue is resolved.

If you're still seeing issues:

bash
# Check if there are multiple credential helpers configured
git config --get-all credential.helper

# Look for all credential-related settings
git config --list | grep credential

Advanced notes

### Understanding Git Credential Helper Names

The Git Credential Manager project has gone through several iterations with different names:

| Era | Helper Name | Notes |
|-----|-------------|-------|
| Legacy | credential-manager | Original GCM for Windows |
| GCM Core | manager-core | Cross-platform rewrite (2020-2023) |
| Current | manager | Renamed in Git 2.39+ (2023+) |

When upgrading Git or GCM, your configuration may reference an older name that no longer exists.

### Checking for Multiple Credential Helpers

Git processes credential helpers in order. If you have multiple configured:

bash
git config --get-all credential.helper

Git tries each one sequentially. If the first fails with "not found", it continues to the next. This is why you might see the error but Git operations still complete.

### Windows-Specific Locations

On Windows, credential helper configuration can exist in multiple places:

1. System config: C:\Program Files\Git\etc\gitconfig
2. Global config: %USERPROFILE%\.gitconfig
3. Local config: .git/config in each repository

Check all locations if the error persists after changing global config.

### Git for Windows Installation Options

When installing Git for Windows, you're asked to choose a credential helper:
- Git Credential Manager - Recommended, handles OAuth, 2FA
- None - No credential storage

If you selected "None" during installation, you'll need to either reinstall or manually install GCM.

### WSL (Windows Subsystem for Linux)

When using Git in WSL, you can share the Windows credential manager:

bash
# In WSL, configure Git to use Windows GCM
git config --global credential.helper "/mnt/c/Program\ Files/Git/mingw64/bin/git-credential-manager.exe"

### Debugging Credential Helper Issues

bash
# Enable Git tracing to see credential helper execution
GIT_TRACE=1 git fetch origin 2>&1 | grep credential

# Test credential helper directly
echo "protocol=https
host=github.com" | git credential-manager get

### Corporate/Enterprise Environments

In corporate environments, system administrators may set credential helpers via system config. If you can't modify system config:

bash
# Override system config with local config
cd /path/to/repo
git config --local credential.helper manager

Frequently asked questions

What does "git: 'credential-manager' is not a git command" mean?
This error indicates that Git is trying to use a credential helper called "credential-manager" but cannot find it as a valid Git command or executable. When you interact with remote repositories over HTTPS, Git uses credential helpers to store and retrieve your authentication credentials (like Personal Access Tokens). helper.
How do I fix "git: 'credential-manager' is not a git command"?
The 'credential-manager is not a git command' error occurs when Git cannot find the credential helper executable. This typically happens when Git Credential Manager is not installed, has been renamed, or the configuration points to an outdated helper name.
What causes "git: 'credential-manager' is not a git command"?
Git Credential Manager is not installed on your system Git configuration references outdated helper name (credential-manager instead of manager) Configuration left over from uninstalled Git Credential Manager
Is the "git: 'credential-manager' is not a git command" error serious?
It is a low-severity error โ€” more of a blocker than a risk. The steps above resolve it.

Official resources & further reading