Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just found out I can edit my PATH by editing /etc/paths or /private/etc/paths, or by putting export PATH=$PATH:/a/path in ~/.profile or one of my other startup scrips.

Is there a difference between these methods? If so, is one method preferable to another?

share|improve this question
up vote 3 down vote accepted

One is system wide while the other is user-specific. If you want other users on your system to have some entries in their PATH, put them in the system wide configuration file. That's the difference.

The private folder is mentioned here.

share|improve this answer
Additionally, .profile only affects commands invoked via the command shell; /etc/paths has the potential to affect many more applications, some of which may be system utilities which rely upon the specific versions of programs in /etc/paths. – rholmes May 16 '14 at 22:35

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.