Written by Admin on 2025-05-06
Downloading WordPress through Command Line: A Simplified Guide
WordPress powers over 40% of websites on the internet, making it one of the most popular Content Management Systems for new and established websites alike. While it is easy to download and install WordPress through its website, many web developers and enthusiasts choose to download it through a command-line interface to have more control over the process.
The dl
or 'downloader' command is a popular way to download the latest version of WordPress using the Terminal or Command Prompt. This article will guide you on how to use the dl
command to download WordPress.
Prerequisites
Before proceeding with the download process, you need to ensure that you have the following:
- A computer with an active internet connection
- Terminal for macOS or Command Prompt for Windows
- wget
or curl
command installed
Downloading WordPress
Step 1: Open the Terminal (macOS) or Command Prompt (Windows) on your computer.
Step 2: Navigate to the directory where you want to download WordPress. You can do this by using the cd
command followed by the directory path. For example, cd /users/username/downloads
.
Step 3: Type the following command to download WordPress using wget
:
bash
wget https://wordpress.org/latest.tar.gz
If you prefer to use curl
, type the following command instead:
bash
curl -O https://wordpress.org/latest.tar.gz
Step 4: Wait for the download to complete. This may take a few minutes depending on your internet speed.
Step 5: Once the download is complete, extract the files using the following command:
bash
tar -xzvf latest.tar.gz
Step 6: You can now move the extracted WordPress files to your desired directory using the mv
command.
bash
mv wordpress /var/www/html/
If you want to install WordPress in a subdirectory, type:
bash
mkdir /var/www/html/yoursubdirectory
mv wordpress /var/www/html/yoursubdirectory/
Conclusion
Using the dl
or downloader command to download WordPress is a simple and quick process. By following the steps outlined above, you can now download and install WordPress to your desired directory in just a few minutes. With this knowledge, you can now confidently start building your WordPress website or improve your existing one.