How to Add Git Bash to Windows Terminal in 2026: Complete Setup Guide

Windows Terminal has become the go-to command-line tool for developers on Windows. If you’re using Git Bash for version control and want it integrated into Windows Terminal, you’re in the right place. This guide shows you exactly how to add Git Bash as a profile in Windows Terminal, customize it, and troubleshoot common issues.

Why Add Git Bash to Windows Terminal

Windows Terminal lets you run multiple command-line tools in one application. Instead of switching between separate windows for PowerShell, Command Prompt, and Git Bash, you can access everything through tabs in a single interface.

Git Bash gives you Linux-style commands on Windows. When you combine it with Windows Terminal, you get:

  • Tabs for different terminal sessions
  • Split panes to work in multiple directories
  • Custom color schemes and fonts
  • Keyboard shortcuts that speed up your workflow
  • GPU-accelerated text rendering

Prerequisites You Need

Before you start, make sure you have:

  • Windows 10 (version 1903 or later) or Windows 11
  • Windows Terminal installed from the Microsoft Store
  • Git for Windows installed on your system

If you don’t have Git installed yet, download it from the official Git website. The installer includes Git Bash by default.

Adding Git Bash Profile to Windows Terminal

Here’s the fastest way to add Git Bash:

  1. Open Windows Terminal
  2. Click the dropdown arrow next to the plus tab icon
  3. Select “Settings” or press Ctrl + ,
  4. Click “Add a new profile” under Profiles
  5. Choose “New empty profile”
  6. Name it “Git Bash”
  7. Set the command line path to your Git Bash executable
  8. Save your changes

Now let’s walk through each step in detail.

How to Add Git Bash to Windows Terminal

Step-by-Step Guide to Add Git Bash

Step 1: Locate Your Git Bash Executable

Git Bash is typically installed at one of these locations:

  • C:\Program Files\Git\bin\bash.exe
  • C:\Program Files (x86)\Git\bin\bash.exe
  • Custom installation path you selected
See also  How to Link Your Microsoft Account to a Digital License in Windows 2026

To verify the location:

  1. Open File Explorer
  2. Navigate to C:\Program Files\Git\bin\
  3. Look for bash.exe

If it’s not there, check C:\Program Files (x86)\Git\bin\. Write down the full path because you’ll need it.

Step 2: Open Windows Terminal Settings

Launch Windows Terminal and access settings using either method:

  • Press Ctrl + , (comma)
  • Click the dropdown arrow next to the tab button and select “Settings”

This opens the settings interface where you can modify profiles.

Step 3: Create a New Profile

In the settings menu:

  1. Look for “Profiles” in the left sidebar
  2. Click the “Add a new profile” button
  3. Select “New empty profile”

A blank profile configuration appears on the right side of the screen.

Step 4: Configure the Git Bash Profile

Fill in these essential fields:

Name: Git Bash

Command line: Enter the full path to bash.exe. Use one of these formats:

C:\Program Files\Git\bin\bash.exe --login -i

or

C:\Program Files (x86)\Git\bin\bash.exe --login -i

The --login -i flags make Git Bash run as an interactive login shell, which loads your bash configuration files.

Starting directory: Set where Git Bash opens by default. Options include:

  • %USERPROFILE% for your user folder
  • A specific project directory like C:\Projects
  • Leave blank to use the default

Icon: Point to the Git icon for visual identification:

C:\Program Files\Git\mingw64\share\git\git-for-windows.png

Step 5: Save and Test

Click the “Save” button at the bottom right. The settings automatically apply.

Test your new profile:

  1. Click the dropdown arrow next to the new tab button
  2. Select “Git Bash” from the list
  3. A new Git Bash tab should open

If you see the familiar bash prompt, you’ve successfully added Git Bash to Windows Terminal.

Advanced Configuration Options

Setting Git Bash as Default Profile

To make Git Bash your default terminal:

  1. Go to Settings > Startup
  2. Find “Default profile”
  3. Select “Git Bash” from the dropdown
  4. Save changes

Now Windows Terminal opens with Git Bash automatically.

Customizing Appearance

Make Git Bash visually distinct with these settings:

Color scheme:

  1. In your Git Bash profile settings, find “Appearance”
  2. Choose a color scheme like “Campbell”, “One Half Dark”, or “Solarized Dark”
  3. You can create custom color schemes in the “Color schemes” section

Font:

Select a font that supports programming ligatures:

  • Cascadia Code (included with Windows Terminal)
  • Fira Code
  • JetBrains Mono

Set font size to your preference, typically 10-12 points.

Background:

Add transparency or a background image:

  • Acrylic transparency: Toggle “Enable acrylic material” and adjust opacity
  • Background image: Enter path to an image file

Adding a Custom Tab Title

Prevent tabs from showing long directory paths:

  1. In Git Bash profile settings, go to “Appearance”
  2. Enable “Show tab title”
  3. Set “Tab title” to “Git Bash” or your preferred name

Keyboard Shortcuts

Create a keyboard shortcut to open Git Bash instantly:

  1. Go to Settings > Actions
  2. Click “Add new”
  3. Select “New tab”
  4. Choose “Git Bash” as the profile
  5. Assign a key binding like Ctrl + Shift + G

Now press your shortcut to open Git Bash in a new tab.

Configuration Table

Here’s a reference table for common Git Bash profile settings:

See also  Engineering Applications of Artificial Intelligence: How AI Transforms Modern Engineering
SettingRecommended ValuePurpose
NameGit BashProfile identifier
Command lineC:\Program Files\Git\bin\bash.exe --login -iExecutable path with login flags
Starting directory%USERPROFILE% or project pathWhere bash opens
IconC:\Program Files\Git\mingw64\share\git\git-for-windows.pngVisual identification
Color schemeOne Half DarkReadability
Font faceCascadia CodeClarity and ligatures
Font size11Comfortable reading
Acrylic opacity90%Subtle transparency

Editing the JSON Settings File Directly

Advanced users can edit the settings.json file for precise control.

Access the JSON File

In Windows Terminal settings:

  1. Click “Open JSON file” at the bottom left
  2. Your default text editor opens the configuration file

Add Git Bash Profile Manually

Locate the “profiles” section and add this object to the “list” array:

{
    "guid": "{00000000-0000-0000-0000-000000000001}",
    "name": "Git Bash",
    "commandline": "C:\\Program Files\\Git\\bin\\bash.exe --login -i",
    "icon": "C:\\Program Files\\Git\\mingw64\\share\\git\\git-for-windows.png",
    "startingDirectory": "%USERPROFILE%",
    "colorScheme": "One Half Dark",
    "fontFace": "Cascadia Code",
    "fontSize": 11
}

Important notes:

  • Generate a unique GUID or let Windows Terminal create one automatically
  • Use double backslashes in paths (\\) for JSON formatting
  • Add a comma after the previous profile object if needed
  • Save the file and Windows Terminal reloads automatically

Understanding the GUID

Each profile needs a unique identifier. Generate one at guidgenerator.com or let Windows Terminal assign one when you create profiles through the UI.

Troubleshooting Common Issues

Git Bash Profile Doesn’t Appear

If your profile doesn’t show in the dropdown:

  • Check the command line path is correct
  • Ensure bash.exe exists at that location
  • Look for syntax errors in the JSON file
  • Restart Windows Terminal completely

Terminal Opens Then Closes Immediately

This happens when the executable path is wrong or flags are invalid:

  • Verify the exact path to bash.exe
  • Confirm you used --login -i flags
  • Try removing the flags temporarily to test
  • Check file permissions on the Git installation directory

Icons Don’t Display

If the Git icon doesn’t appear:

  • Confirm the icon path points to an existing file
  • Use forward slashes or double backslashes in JSON
  • Try a different icon file or use a built-in icon
  • Leave the icon field blank to use the default

Starting Directory Ignored

When Git Bash doesn’t open in your specified directory:

  • Check the path exists and you have access permissions
  • Use environment variables like %USERPROFILE% correctly
  • Try an absolute path without variables
  • Ensure the path doesn’t contain special characters

Colors Look Wrong

If the color scheme appears incorrect:

  • Select a different color scheme from the dropdown
  • Check if your bash configuration files override colors
  • Try the default Campbell color scheme
  • Create a custom color scheme with specific hex values

Optimizing Git Bash Performance

Increase Buffer Size

Larger scrollback buffers let you review more command history:

  1. In Git Bash profile settings, find “Advanced”
  2. Set “History size” to 10000 or higher
  3. This uses more memory but improves usability

Disable Unnecessary Services

Git Bash runs faster with fewer startup processes:

Edit your .bashrc file in your home directory and comment out services you don’t need. Be careful not to disable essential git configuration.

Use Native Windows Paths

When possible, access files through Windows paths instead of emulated Unix paths. This reduces translation overhead.

See also  Personalized Learning with AI: How Artificial Intelligence Transforms Education for Every Student

Multiple Git Bash Profiles for Different Projects

Create separate Git Bash profiles for different projects:

  1. Add a new profile as described earlier
  2. Name it descriptively, like “Git Bash (Project Alpha)”
  3. Set the starting directory to your project folder
  4. Customize the color scheme to visually distinguish projects
  5. Add a custom icon if desired

This approach lets you open project-specific terminals instantly without navigating directories.

Integrating with Visual Studio Code

Windows Terminal works alongside VS Code’s integrated terminal:

  1. In VS Code, press Ctrl + Shift + P
  2. Type “Terminal: Select Default Profile”
  3. Choose “Git Bash”

Now VS Code uses Git Bash for integrated terminals, maintaining consistency across your development environment.

Updating Git Bash

When you update Git for Windows, the executable path typically stays the same. Your Windows Terminal profile continues working without changes.

If Git updates to a new location:

  1. Find the new bash.exe path
  2. Update the “Command line” field in your profile
  3. Update the icon path if it changed
  4. Save and test

Creating a Portable Configuration

Export your Windows Terminal settings to use on multiple machines:

  1. Locate your settings.json file at: %LOCALAPPDATA%\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState
  2. Copy settings.json to cloud storage or version control
  3. On another machine, replace the settings.json file
  4. Adjust paths if Git installs in different locations

This maintains consistent terminal configuration across your devices.

Security Considerations

Running Scripts Safely

Git Bash executes shell scripts with significant system access:

  • Only run scripts from trusted sources
  • Review script contents before execution
  • Use chmod to control script permissions
  • Be cautious with scripts that request elevated privileges

Protecting Credentials

Never store passwords or API keys in bash history or configuration files:

  • Use credential managers instead of plaintext
  • Enable Git’s credential helper for secure storage
  • Clear sensitive commands from bash history
  • Set appropriate file permissions on configuration files

Comparison with Other Terminals

FeatureWindows Terminal + Git BashGit Bash StandalonePowerShell
TabsYesNoThrough Windows Terminal
Split panesYesNoThrough Windows Terminal
GPU accelerationYesNoThrough Windows Terminal
Unix commandsYesYesLimited
Custom themesYesLimitedThrough Windows Terminal
Multiple profilesYesNoThrough Windows Terminal

Windows Terminal provides the interface benefits while Git Bash supplies Unix command compatibility.

Summary

Adding Git Bash to Windows Terminal gives you a powerful, unified command-line environment. The process involves locating your bash.exe file, creating a new profile in Windows Terminal settings, and configuring the command line path with appropriate flags.

Key points to remember:

  • Use the full path to bash.exe with --login -i flags
  • Customize appearance, starting directory, and icons for better workflow
  • Create multiple profiles for different projects
  • Edit JSON directly for advanced configurations
  • Troubleshoot by verifying paths and checking for syntax errors

Once configured, Git Bash integrates seamlessly into Windows Terminal alongside PowerShell, Command Prompt, and other shells. This setup streamlines development work and reduces window clutter.

Frequently Asked Questions

Can I use Git Bash and PowerShell in the same Windows Terminal window?

Yes. Windows Terminal supports multiple profiles simultaneously. Open Git Bash in one tab and PowerShell in another, or use split panes to view both side by side. This flexibility is one of Windows Terminal’s main advantages.

Do I need to reinstall Git to add it to Windows Terminal?

No. If Git for Windows is already installed, you just need to create a profile pointing to the existing bash.exe. Windows Terminal doesn’t require any changes to your Git installation.

How do I make Git Bash my default terminal in Windows Terminal?

Go to Settings, then Startup, and select Git Bash from the “Default profile” dropdown menu. Save your changes. Windows Terminal will now open with Git Bash automatically when launched.

Why does my Git Bash profile show a different icon than I configured?

The icon path might be incorrect or the file might not exist at that location. Verify the path points to a valid image file. If the path uses environment variables or relative paths, try using an absolute path instead. You can also leave the icon field blank to use Windows Terminal’s default icon.

Can I run Git Bash and WSL together in Windows Terminal?

Absolutely. Windows Terminal handles multiple Linux environments simultaneously. You can have Git Bash, Ubuntu WSL, Debian WSL, and other distributions each in their own profile. Switch between them using tabs or the profile dropdown menu for maximum flexibility in your development workflow.

MK Usmaan