Setting Git Bash As VS Code Terminal | Generated by AI

Home 2026.01

Question: How to set VS Code terminal profile to use Git Bash in Windows?

Answer:

Here are the most reliable and up-to-date ways (2025) to set Git Bash as your default terminal in Visual Studio Code on Windows:

  1. Press Ctrl + , → open Settings
  2. Search for: terminal.integrated.profiles.windows
  3. Click “Edit in settings.json” (or click the {} icon on the right)
  4. Add or modify the following content:
"terminal.integrated.profiles.windows": {
  "Git Bash": {
    "source": "Git Bash",
    "icon": "terminal-bash"
  },
  "PowerShell": {
    "source": "PowerShell",
    "icon": "terminal-powershell"
  },
  "Command Prompt": {
    "path": [
      "${env:windir}\\Sysnative\\cmd.exe",
      "${env:windir}\\System32\\cmd.exe"
    ],
    "args": []
  }
},
"terminal.integrated.defaultProfile.windows": "Git Bash"
  1. Save the file → new terminals should open with Git Bash

Method 2: Quick one-liner (if Git Bash is already detected)

Many recent VS Code versions auto-detect Git Bash. You can just do:

  1. Open Command Palette (Ctrl+Shift+P)
  2. Type → Terminal: Select Default Profile
  3. Choose Git Bash

If you don’t see Git Bash in the list → use Method 1 or Method 3.

Method 3: Explicit path (most reliable when auto-detection fails)

"terminal.integrated.profiles.windows": {
  "Git Bash": {
    "path": "C:\\Program Files\\Git\\bin\\bash.exe",
    "icon": "terminal-bash",
    "args": [
      "--login",
      "-i"
    ]
  }
},
"terminal.integrated.defaultProfile.windows": "Git Bash"

Common alternative paths (choose the one that exists on your system):

C:\Program Files\Git\bin\bash.exe
C:\Program Files\Git\git-bash.exe
C:\Program Files (x86)\Git\bin\bash.exe
C:\tools\Git\bin\bash.exe               ← common in Scoop / manual install

Bonus: Make Git Bash feel more like a modern terminal

Add these optional but very popular settings:

"terminal.integrated.shellArgs.windows": ["--login", "-i"],
"terminal.integrated.fontFamily": "Cascadia Code, Consolas, 'Courier New', monospace",
"terminal.integrated.cursorStyle": "line",
"terminal.integrated.cursorBlinking": true,
"terminal.integrated.scrollback": 10000,

Quick Troubleshooting Checklist

Most common winning combination in 2025:

"terminal.integrated.defaultProfile.windows": "Git Bash",
"terminal.integrated.profiles.windows": {
  "Git Bash": {
    "path": "C:\\Program Files\\Git\\bin\\bash.exe",
    "icon": "terminal-bash"
  }
}

Good luck!

References:


Back

x-ai/grok-4.1-fast

Donate