Tree view of a directory/folder in Windows?

Pietro picture Pietro · Mar 1, 2012 · Viewed 207.3k times · Source

In Linux/KDE, I can see a directory as a tree. How can I do it in Windows 7?

Consider I do NOT mean "Windows Explorer". This just shows the directories, I also want the files.

Answer

Janek picture Janek · Mar 1, 2012

In the Windows command prompt you can use "tree /F" to view a tree of the current folder and all descending files & folders.

In File Explorer under Windows 8.1:

  • Select folder
  • Press Shift, right-click mouse, and select "Open command window here"
  • Type tree /f > tree.txt and press Enter
  • Use MS Word to open "tree.txt"
  • The dialog box "File Conversion - tree.txt" will open
  • For "Text encoding" tick the "MS-DOS" option

You now have an editable tree structure file.

This works for versions of Windows from Windows XP to Windows 8.1.