If you’re running a fresh Ubuntu 22.04 server and want to install WordPress, follow this simple step-by-step guide. This method uses Apache, MySQL, and PHP (a LAMP stack) to get your WordPress site up and running.
Step 1: Update the System
Step 2: Install Apache Web Server
Step 3: Install MySQL Database Server
This will secure your MySQL installation with recommended settings.
Step 4: Install PHP and Required Extensions
Step 5: Create a MySQL Database for WordPress
Then run these SQL commands inside the MySQL shell:
You can change 'password'
to something more secure.
Step 6: Download and Extract WordPress
Step 7: Configure WordPress
Update the following lines with your database details:
Step 8: Move WordPress Files to Web Directory
Set proper permissions:
(Optional) Remove the default Apache page:
Final Step: Finish Installation in Browser
Open your server’s IP in a browser, for example:
http://your_server_ip/
Follow the WordPress setup wizard to complete the installation.
That’s it! You’ve successfully installed WordPress on Ubuntu 22.04.
If you found this helpful, don’t forget to share and subscribe to my YouTube channel for more tutorials.