Absolute path

Alternatively referred to as the file path and full path, the absolute path is a path that contains the root directory and all other sub directories that contain a file or folder. Below are some examples of absolute and relative paths.

Windows absolute path

C:\Windows\calc.exe

Windows non absolute path (relative path)

calc.exe

In the above example, the absolute path contains the full path to the file and not just the file as seen in the non absolute path.

Linux absolute path

/home/users/c/computerhope/public_html/cgi-bin

Linux non absolute path (relative path)

public_html/cgi-bin

In this example, the absolute path contains the full path to the users cgi-bin directory on that computer. Most users do not want to see the absolute path to their personal directory, so when a user logs in they only see the non absolute path. Using the pwd command a user can view the absolute path of the directory.

Internet URL absolute path

http://www.computerhope.com/oh.htm

Internet URL non absolute path (relative path)

oh.htm

Finally, in this last example the Internet absolute path is the domain and the web page on that domain. Web developers creating links to other pages can use a relative path if the file their linking from is in the same directory.

Also see: Path, Relative path