Change where new Finder windows open on Mac
By default, new Finder windows open to Recents — a smart view, but not always what you want. If you spend most of your time in Downloads, your Home folder, or a specific project directory, you can make new windows start there instead. It takes about thirty seconds.
Change it in Finder Settings
This is the quickest route and doesn't require Terminal at all.
- Click anywhere in Finder to make it the active app, then press ⌘, to open Finder Settings.
- Click the General tab.
- Click the "New Finder windows show:" dropdown.
- Choose any location from the list: Recents, Desktop, Documents, Home, Downloads, iCloud Drive, or "Other…" to pick any folder on your Mac.
- Close Settings. The next window you open with ⌘N will open there.
Change it via Terminal
If you prefer a command or want to script this across multiple Macs, Finder stores the preference as a short code string. Open Terminal (Applications › Utilities) and run one of these:
# Desktop
defaults write com.apple.finder NewWindowTarget -string "PfDe"
# Documents
defaults write com.apple.finder NewWindowTarget -string "PfDo"
# Downloads
defaults write com.apple.finder NewWindowTarget -string "PfDl"
# Home folder (~)
defaults write com.apple.finder NewWindowTarget -string "PfHm"
# Recents (the macOS default)
defaults write com.apple.finder NewWindowTarget -string "PfRe"
# All Files
defaults write com.apple.finder NewWindowTarget -string "PfAF"
killall Finder
The killall Finder at the end restarts Finder so the change takes effect immediately. Any open windows will close and reopen — don't worry, your actual files are fine.
Set a custom folder as the default
If you want new windows to open to a folder that isn't in the standard list — say, ~/Projects or a client folder — use the PfLo code and pair it with a second key that holds the path:
# set target type to "custom location"
defaults write com.apple.finder NewWindowTarget -string "PfLo"
# set the actual path (must be a file:// URL)
defaults write com.apple.finder NewWindowTargetPath -string "file:///Users/yourname/Projects/"
killall Finder
Replace yourname with your actual macOS username and adjust the path to whatever folder you want. The trailing slash is important — include it.
You can find your username quickly by running whoami in Terminal.
The full list of location codes
For reference, here are all the codes macOS recognises for NewWindowTarget:
PfRe — Recents
PfDe — Desktop
PfDo — Documents
PfDl — Downloads
PfHm — Home folder
PfAF — All Files
PfLo — Custom location (requires NewWindowTargetPath)
Mainspring turns dozens of these buried macOS settings into one-click, reversible toggles — so you spend less time in Terminal and more time actually using your Mac. Every change is labelled and can be undone in the same interface.
Try Mainspring free →Signed & notarized by Apple · 1-day free trial · $29 once
How to undo it
To restore the macOS default (Recents), either open Finder Settings › General and change the dropdown back, or run:
defaults write com.apple.finder NewWindowTarget -string "PfRe"
killall Finder
If you set a custom path, you can also remove that key:
defaults delete com.apple.finder NewWindowTargetPath