How to find the path of a file on Mac

12 min read

Over time, your Mac likely accumulates heaps and heaps of files. As you create, download, and save documents, your entire filesystem can become cluttered and fussy.

Even those who carefully manicure a deep file tree system need help locating files from time to time. For files buried in sub-folders, knowing the file path can be a critical shortcut to finding the document you need quickly.

We’ll show you how to get path of a file in Mac, how to navigate a file directory Mac has built-in, and why a standalone app may be more useful than your Mac’s Finder.

Method 1: Info window

If you know which file you want to reference later, knowing how to find the path of a file in Mac is actually pretty simple. Here’s how:

  1. Locate the file you’re looking for on your Mac
  2. Right-click the file
  3. Choose “Get Info.”

 find the path of a file on Mac

The file path on Mac will be listed under “Where” in the “Get Info” window that appears. 

There’s an even simpler method —  an app that lets you find a file path without opening any windows. Path Finder is a dual-pane Finder replacement that has a series of modules you can drag onto its side menu to automate your file management. 

Path Finder’s “Info” module surfaces all the same data from the three steps above:

  1. Choose the file in Path Finder
  2. Check Info in the sidebar
  3. Check Path. 

path finder mac

What’s more, the file path changes dynamically but always stays visible as you’re navigating through file destinations. 

PathFinder comes with a range of other useful tools such as showing and hiding files, saving tab groups, uploading files to external servers, etc. Try using it as a Finder alternative and you’ll likely never go back!

How to copy the file path

Path Finder makes the job of copying a file path effortless: 

  1. Right-click any file in Path Finder
  2. Choose Copy Path 
  3. Choose the method of copying the file path. 

copy file path mac

Without Path Finder, the process of copying a file path is trickier but doable. One of the options is to get it via the context menu.

Method 2: How to get a file path from Mac context menu 

  Here’s how to surface and copy the file path for any file or folder in your Mac’s Finder app:

  1. Open Finder on your Mac
  2. In the menu, choose View
  3. Choose Show Path Bar (This surfaces the path for any file selected at the bottom of the Finder window. If you try to copy the text at the bottom of the window, nothing happens. So how can you actually copy the file path name?)
  4. While holding down the Control button, click on the file you want to copy the path of in Finder
  5. Press the Option key (In the menu that appears after step one, you’ll see Copy turn into Copy [file path name] as Pathname)
  6. Click Copy [file path name] as Pathname.

get a file path mac

Now you know how to get the path of a file in Mac via the context menu! This copies the file path of the selected file to your clipboard, which you can then paste anywhere you like. 

Method 3: Find file path via Terminal

Terminal (or Mac directory path) allows deep access to the inner workings of your computer, down to the root level. You can perform just about any function in Terminal, including finding, moving, and deleting files. It’s also great for finding file path names.

Here’s how to get directory path in Mac to show a file’s path name:

  1. Open Terminal on your Mac
  2. Type this command: sudo su
  3. Press the return key on your Mac
  4. Enter the password for you Mac
  5. Press return again
  6. Enter the following command: find / -name [filename] (Note: You must know the name of the file you’re looking for. In the step above, substitute the file name for [filename])
  7. Press enter (Note: It can take Terminal several minutes for Finder to complete this task. Be patient. Additionally, much of what Finder returns will say “operation not permitted”. You can safely ignore those lines)
  8. Find the file path of the file you’re searching for, then select its file path
  9. Right-click the selected text and copy it.

There’s a simpler way, though. If you have the file available on your Mac, simply drag and drop it onto your Terminal window, and the full file path will be displayed.

mac file path terminal

Method 4: Copy file path using Go to Folder

Another drag-and-drop method is to reveal a file path via Finder’s Go to Folder command: 

  1. Open Finder
  2. In the menu, choose Go > Go to Folder
  3. Drop your file onto the path field to reveal its path. 

copy file path using go to

Method 5: Create ‘Copy Path’ Service in Automator

Power users and shortcut aficionados will love this little hack! Your Mac’s Automator allows you to create a host of microservices to perform tons of functions, including getting the file path of any file with ease. Here’s how to create your own shortcut:

  1. Open Automator on your Mac
  2. Select Quick Action (Note: In macOS Catalina or earlier, this will be known as Service)
  3. At the top right of the Automator window, choose Files or Folders from the drop-down menu next to “Workflow receives current:”
  4. Next to “in,” select “Finder”
  5. From the Actions library, drag the “copy to clipboard” module onto the right side of the Automator window
  6. From the Mac menu bar, select File
  7. Choose Save from the drop down menu and name your new automation
  8. Click Save. 

copy path service automator

Now that you’ve created your fancy new automation, here’s how to use it:

  1. Open Finder on your Mac
  2. Right click on any file or folder
  3. Click Finder in the menu bar and choose Services 
  4. Select the Automator shortcut you just created (ours is saved as “FindFilePath”)
  5. Paste the copied file path anywhere you like. 

How to find large and old files

What if the specific file or folder you’re looking for is massive – but that’s all you really know about it? For this, CleanMyMac X is the perfect app!

While it focuses on keeping your Mac’s file system spotless and your computer operating at peak performance, CleanMyMac X also has a handy module named (appropriately) “Large & Old Files.” Its aim is to discover big, bulky documents or files, which it distills to lists. You can choose to view all of your big, bulky files, or check out CleanMyMac X’s “kind” and “size” lists to help you find exactly what you’re looking for. It even creates lists by size, so you don’t mistake that 11GB file for the 1.1GB file!

cmm old files

Make your Mac easy to navigate

Your Mac doesn’t think you need to know all the details of a file or folder; it would rather you hunt and peck around to discover what you need.

For many users, this is fine. Finding a file is relatively simple for many – but an increasing number of users want more from their Mac, including the Finder app. Those with tons of files and folders are looking for amsarter, better way to manage their digital footprint.

This is why PathFinder and CleanMyMac X are so useful. Each plays a unique role in keeping your Mac performant, helping you discover files with ease, and allowing more customization of your Mac than ever before. 

Best of all, both apps are available for free with a 7-day trial of Setapp, an app platform that powers up your workflow with handy apps for Mac and iOS — all under a single monthly subscription. When your 7-day trial period ends, continued access to Setapp starts at only $9.99/month!

240+ apps for $9.99
per month

Sign up to Setapp and try them for free.