Everything in its place

Freshly installed OS X has clear ideas about what should go where. Does it really matter, or can you change it to your own taste?

With a fairly average startup drive containing more than two million files and folders, OS X, apps, and users all need structure and standards in the filing system in order to locate files. Although you have a lot of flexibility in how you arrange your own documents within your Home Folder, and can take advantage of Yosemite’s tags to assist, software can only look in predefined places when it needs resources such as code libraries and fonts. Furthermore folder structure is a key part of the system of permissions, which control access to sensitive files such as system components and applications.

The visible top-level folders used to separate these are the system library (at /System/Library), main library (at /Library), Applications (at /Applications), and user folders (at /Users). Hidden folders such as /bin, /net, and /etc provide a background Unix fabric that most users will never encounter unless they explore Terminal’s command line.

As each named user’s Home Folder (inside /Users) also has its own user-specific Library (given using standard shorthand at ~/Library, where the tilde symbol indicates your Home folder, such as /Users/howardoakley), at any time there are three different library folders.

Three Library folders to rule them all.
Three Library folders to rule them all.

/System/Library

True to name, the system library contains components essential to OS X, hardware, and everything that works at low level. A typical example is /System/Library/Extensions, which contains code that extends the OS X kernel to address hardware such as graphics cards and Thunderbolt ports.

Third party products used to install their own kernel extensions (.kext files) there, but an errant .kext can readily cause kernel panics and other serious issues; now they should use the equivalent folder in the main library instead. The system Fonts folder must contain those fonts required by OS X, currently around 52 files, but should not contain others.

/Library and ~/Library

The main library houses those support files that are common to all users. In its sub-folders you will find the great bulk of the fonts that you have installed, third-party System Preferences panes and extensions, and in Application Support all manner of files required to make Apple and other apps work properly.

In contrast to the system library, it is tailored by apps and other tools to make your Mac what it is. The Library in your Home Folder is more personal still, containing your personal preference settings, and all other support material that is specific to you. Although normally hidden from the Finder, it is easily revealed by holding the Option key down when opening the Finder’s Go menu.

Other standard folders

You do not have to install apps in the top-level Applications folder, and can run them temporarily from within most other folders, including the Documents folder in your Home Folder (~/Documents) if you wish. However most users find it best to segregate apps into the Applications folder; you can use the folder of the same name in your Home Folder if you want to limit use of that app to just yourself, but updaters may not notice them there.

Indeed, nesting apps inside custom folders inside your Applications folder can sometimes confuddle updaters, so you are best installing each in the default location in /Applications. A few tools are still tucked away in /Applications/Utilities, but you should leave those that are there where they are, and not add to them unless you really want to.

If your Mac is sharing files or more over a network, then you should see a top-level Network folder offering you those shared facilities. Sometimes routers and other devices appear there even if they are not offering any shared resources, though.

Sticking to this standard form of folder layout ensures that OS X can find the right files at the right time, and you are never upset by reports of missing fonts or other resources. But you can be more creative within your Home folder, which is what it is intended for.

Recent complications

The App Store ensures anything you purchase through it keeps its support files in the Containers folder in ~/Library
The App Store ensures anything you purchase through it keeps its support files in the Containers folder in ~/Library

App Store products have stringent ‘sandbox’ requirements which are reflected in locations used for their support and preference files. The main point of entry is through ~/Library/Containers; each installed app there has its own folder, containing a miniature Home folder constructed largely of links to your own folders, and traditional items such as Application Support and Preferences.

Your Home Folder also includes sub-folders intended for specific types of media, including Movies, Music, and Pictures. These are the default locations for iMovie, iTunes, and Photos (or iPhoto) libraries, but each app lets you change library or content location, helpful if you want to keep large libraries on a separate or networked drive. For example, you can relocate the iTunes Media folder to a location outside your Music folder, using the Advanced tool in its Preferences.

If you want to, you can set iTunes to keep its library in a different location.
If you want to, you can set iTunes to keep its library in a different location.

Unless you have good reason to be different, it is simplest to use these as Apple intends, to keep some order within your Home Folder.

Curiously some find it harder to move or share files between different users on the same Mac, than between different Macs. The simplest solution is to place documents in the /Users/Shared folder, which all user accounts can access. This can have its own Library folder, useful for sharing fonts between some but not all users. An AirDrop virtual drive appears in Finder windows when activated.

Updated from the original, which was first published in MacUser volume 30, issue 01, 2014.