A directory is a location for storing files on a computer. It’s a file system cataloging structure that contains references to other files or directories. Folders and files are organized into a hierarchical structure, meaning it’s organized in a way that resembles a tree. For example, a directory contained inside another directory is called a subdirectory. The terms parent and child are often used to refer to directories and subdirectories, respectively. The top-most directory in a file system is known as the root directory. Think of a directory as a filing cabinet that contains folders. Within these folders are files.

File systems use directories to organize files within a storage device such as a hard disk drive or solid state drive. System files may be located in one directory, while user files may be stored in another. Hierarchical file systems that include directories are Linux, MS-DOS, OS/2, and Unix. It’s worth noting that in a GUI such as Microsoft Windows, directories are known as folders.

By storing specific types of files in a folder, information can be easily accessed. Programs can be stored in a directory as well. When a program is installed, its files are stored in a directory that contains subdirectories with many files related to the program. Because of the directory, files are less likely to get overwritten, modified, or deleted by other programs.

Directory paths

To access a file within a directory, the names of all directories above it may need to be specified. To do this, a path will need to be specified. A path specifies a unique location by following the directory tree hierarchy expressed in a string of characters in which path components represent each directory. The delimiting character is most commonly a slash or a colon. With DOS and Windows the root directory is a backslash (). With Linux and Unix systems, the root directory is a forward slash (/).


Vangie Beal
Vangie Beal
Vangie Beal is a freelance business and technology writer covering Internet technologies and online business since the late '90s.

Top Articles

List of Windows Operating System Versions & History [In Order]

The Windows operating system (Windows OS) refers to a family of operating systems developed by Microsoft Corporation. We look at the history of Windows...

How to Create a Website Shortcut on Your Desktop

Website Shortcut on Your Desktop reviewed by Web Webster   This Webopedia guide will show you how to create a website shortcut on your desktop using...

What are the Five Generations of Computers? (1st to 5th)

Reviewed by Web Webster Each generation of computer has brought significant advances in speed and power to computing tasks. Learn about each of the...

Hotmail [Outlook] Email Accounts

Launched in 1996, Hotmail was one of the first public webmail services that could be accessed from any web browser. At its peak in...

XiaoBa Ransomware

XiaoBa is a type of file-encrypting ransomware that runs on Windows and encodes...

Team Management Software

Team management software is a type of organizational software that supports remote team...

Kaseya Ransomware Attack

The 2021 ransomware cyberattack on U.S.-based software solutions company, Kaseya, is known as...