Skip to main content

Git Config Generator

Stop memorizing Git config keys. Pick your settings visually, and download a ready-to-use .gitconfig file in seconds.

What is a Git Config Generator?

Your .gitconfig file controls how Git behaves on your machine — everything from how diffs are displayed to how conflicts are resolved and how you sign your commits. Most developers either copy a config from a blog post or spend years building one setting at a time.

This generator, built by the team behind Tower — the Git client trusted by over 100,000 developers — lets you browse every meaningful Git setting in organized categories, toggle options on and off, and see exactly what ends up in your file.

Whether you're setting up a fresh machine or auditing a config you've been carrying around for a decade, you'll have a production-ready .gitconfig in under a minute.

Frequently Asked Questions

How do I apply my .gitconfig file?

Place the downloaded file at ~/.gitconfig on macOS/Linux or C:\Users\YourName\.gitconfig on Windows. If you already have a config file, you can replace it entirely or copy just the sections you want.

Can I have different configs per repository?

Yes — and it's more common than you'd think. Any global setting can be overridden at the project level. The easiest way is to use this generator to create a project-specific config file, save it as .gitconfig inside your repo, and then tell Git to include it by adding this to your global config:

[includeIf "gitdir:/path/to/your/repo/"]
path = /path/to/your/repo/.gitconfig

Git will apply those settings automatically whenever you're inside that repository. This is especially useful for switching between a personal and a work email, or using different signing keys per project.

Will this overwrite my existing .gitconfig?

No. The generator only outputs the settings you explicitly configure. Anything you don't touch stays untouched in your current file. You're free to copy individual sections into an existing config instead of replacing the whole file.

Does .gitconfig support comments?

Yes. Lines starting with # or ; are treated as comments. The generator adds a header comment with the generation date so you know exactly when the file was created.

What are the most important settings to configure?

If you're unsure where to start, hit the "Recommended" preset — it enables battle-tested defaults like the histogram diff algorithm, zdiff3 conflict style, auto-stash before rebase, and a handful of aliases that most developers end up configuring eventually. You can always fine-tune from there.

Who built this tool?

This generator is built and maintained by the team at Tower, the Git client used by over 100,000 developers and designers. We've spent over a decade making Git easier to use — this tool is part of that mission.

Here's a message from our users...

When it comes to Git, Tower does all the heavy lifting for you... and our users appreciate it!