Upon installing WordPress, you'll encounter the root directory, which houses the essential files that initiate and control the entire system. This directory is usually named after your website or resides within the public_html or www folder of your web hosting account’s web server. Here's a breakdown of the key components:
Directory folder: wp-admin
This directory is the heart of the WordPress administration panel. It contains all the files necessary for the backend interface, including scripts for managing posts, pages, users, plugins, themes, and settings.
Within wp-admin, you'll find subdirectories like:
css/: Contains CSS files for the admin interface's styling.
images/: Stores images used in the admin panel.
includes/: Houses PHP files that provide core functionalities for the backend, such as user management, media handling, and update routines.
js/: Holds JavaScript files that power interactive elements within the admin panel.
Directory folder: wp-content
This is where you'll find the user-generated content and customizations that define your website's unique look and feel. It's the most frequently modified directory for developers and designers.
themes/: Stores all installed WordPress themes. Each theme resides in its own subdirectory. Inside a theme folder, you'll find files like style.css (the main stylesheet), functions.php (theme-specific functions), template files (example - index.php, single.php, page.php), and other assets.
plugins/: Holds all installed WordPress plugins. Each plugin is contained within its own subdirectory. Within a plugin folder, you'll find the main plugin file (example - my-plugin.php), along with other PHP files, CSS, JavaScript, and assets.
uploads/: Stores all media files uploaded through the WordPress media library, such as images, videos, and documents. WordPress organizes uploads by year and month, creating subdirectories like "2024/10/" to keep things tidy.
languages/: Contains language files (PO and MO files) for translating WordPress and plugins/themes into different languages.
upgrade/: This temporary directory is used during WordPress updates.
Directory folder: wp-includes
This directory houses the core WordPress files that are essential for the system to function. It contains libraries, functions, and classes that are used throughout WordPress. Modifying files within this directory is highly discouraged, as it can lead to instability and break your website.
It includes many folders, a few important ones are:
css/: Core WordPress CSS files.
js/: Core WordPress JavaScript files.
images/: Core WordPress images.
pomo/: Contains the gettext library used for internationalization.
Requests/: A robust HTTP request library.
Top level WordPress files
The following are files that sit at the same level as the wp-admin, wp-content, and wp-includes folders:
wp-config.php: This crucial file contains your WordPress database connection details, security keys, and other important settings. It's generated during the WordPress installation process. Handle this file with extreme care, as incorrect settings can prevent your website from working.
.htaccess: This file (if present) is used by Apache web servers to configure server behavior, such as URL rewriting (permalinks), security settings, and caching.
index.php: This is the main entry point for WordPress. It loads the WordPress environment and initiates the request processing.
wp-activate.php: Used for activating plugins.
wp-blog-header.php: Loads the WordPress blog header.
wp-comments-post.php: Handles comment submissions.
wp-cron.php: Manages scheduled tasks (cron jobs).
wp-links-opml.php: Used for exporting and importing blogroll links.
wp-load.php: Loads the WordPress core.
wp-login.php: Handles user login.
wp-mail.php: Used for sending emails.
wp-settings.php: Loads WordPress settings.
wp-signup.php: Handles user registration for multisite installations.
wp-trackback.php: Handles trackbacks.
xmlrpc.php: Enables XML-RPC functionality for remote publishing and other services.
robots.txt: A text file that provides instructions to search engine crawlers about which parts of your website to crawl and index.