# How to Copy the Folder Structure as a Tree on Mac

Updated: November 24, 2026

- [Supercharge](https://sindresorhus.com/supercharge.md): Elevate your Mac experience. Price: $20, one-time purchase, plus tax where applicable. Platforms: macOS. Get it from: [Gumroad](https://sindresorhus.gumroad.com/l/supercharge?wanted=true), [Setapp](https://go.setapp.com/stp181?refAppID=742&utm_medium=vendor_program&utm_content=button). Free trial: [download](https://sindresorhus.com/supercharge#trial). Requires macOS 27 or later. Size: 10 MB. Free older versions for macOS 26 and 15: [download](https://sindresorhus.com/supercharge#older-versions). Gumroad rating: 5.0/5 (288 ratings).

URL: https://sindresorhus.com/guides/copy-folder-tree-mac

Right-click a folder in Finder, and choose “Copy Folder Tree” from [Supercharge](https://sindresorhus.com/supercharge.md). You get the folders and files as a text tree, which you can paste in a document, an issue, or a message to an AI chat. [Without an app](https://sindresorhus.com/guides/copy-folder-tree-mac#without-an-app), the `find` command in Terminal lists the paths, but not as a tree.

## With Supercharge

1. Open the settings of [Supercharge](https://sindresorhus.com/supercharge.md), click “Tweaks”, and click “Configure…” next to “Context menu items”.
1. In the “Main Menu” tab, turn on “Copy Folder Tree”.
1. Right-click a folder in Finder, and choose “Copy Folder Tree”. For the open folder, right-click an empty area of the window.
1. Paste the tree.

The result is like this:

```
Project/
├── src/
│   └── main.swift
└── README.md
```

Folders come first. Hidden files are not included, and an app or another package is one line. A tree with more than 1000 items stops with a line that tells you so.

The right-click items cannot show in synced folders, like iCloud Drive and Dropbox. There, right-click the folder, and choose “Services › Copy Folder Tree”.

## Without an app

In Terminal, [go to the folder](https://sindresorhus.com/guides/open-terminal-in-folder-mac.md), and copy its paths without hidden files:

```console
cd ~/Projects/site
find . -not -path '*/.*' | sort | pbcopy
```

The result is one path on each line, like `./src/main.swift`, not a tree. The `tree` command prints a tree, but macOS does not have it. You can install it with [Homebrew](https://brew.sh):

```console
brew install tree
```

The `find` command is fine for a short list. Supercharge gives the tree in one click, without Terminal.
