Git: working tree vs working directory

Oct 25, 2022 · 1 min read · Post a comment

Starting from Git version 2.9.1 the working directory is referred to as working tree. Let me clear the baffling difference for once.


  • Git


Starting with the basics, a current directory or simply put a folder is a place where you store your files. You can find your current directory by simply running the command: pwd.

But, under the hood as part of the UNIX OSs, a directory is a file storing names of other files. They are all files in relation to the system.

Working tree also called working tree directory is purely the folder which consists of the .git folder together with all the subdirectories and files.

The confusing part comes from the fact that “directories” in both UNIX OSs and Git are seen as a hierarchical “tree” structure.

Working directory refer to both the current directory and the Git working tree. That’s it.


To find more neat Git commands and hacks, simply browse the Git category. Feel free to leave a comment below and if you find this tutorial useful, follow our official channel on Telegram.