Do you want to install WordPress locally on Mac using MAMP?
Installing WordPress on your computer gives you the chance to try out WordPress before starting your blog or website. It’s also a great way to experiment with themes and plugins before publishing your site online.
In this article, we will show you how to install WordPress locally on Mac using MAMP.

Tip: Not using Mac? We also have a tutorial on how to install WordPress locally on Windows.
Why Install WordPress Locally on Mac using MAMP?
MAMP is a popular program that creates a local server environment on your computer. This allows you to run WordPress on your computer, which many people find easier than working with a live, public WordPress website.
It’s also a free way to test out WordPress.
The core WordPress software is free to download and use. However, you’ll still need to buy a domain name and web hosting in order to publish your site online.
By running WordPress locally, you can get some hands-on experience without having to buy a domain and hosting first. If you want a complete cost breakdown, please see our guide on how much it costs to build a WordPress website.
Your computer is also a private place. This makes it perfect for developing, experimenting, and learning the WordPress software. This includes installing any themes or plugins that you want to try out.
How to Install MAMP on Mac
To install and run WordPress locally, the first thing you need to do is visit the MAMP website.
Here you should see the latest version of MAMP & MAMP Pro.

MAMP has separate downloads for different versions of the macOS operating system.
Not sure which version of macOS is installed on your computer? To find out simply click on the Apple icon in your computer’s toolbar.

You can then click on About This Mac.
This will open a popup that shows lots of information about your computer. This includes your version of macOS.

You can now download the correct version of MAMP for your operating system.
Once your download is finished, double-click on the MAMP .pkg file. This will launch the MAMP installer.

Now simply follow the onscreen instructions to install MAMP.
After installing this program, you can go ahead and launch MAMP by opening your computer’s Applications folder.
Here you’ll find two versions of MAMP. MAMP Pro is the paid version, so make sure you select the free version.

Inside this MAMP folder you’ll find various files, plus a MAMP application.
Double-click to launch the MAMP app.

Before you get started, we recommend configuring a few settings to make your MAMP experience better.
To make these changes, just click on ‘MAMP’ in your toolbar. You can then select ‘Preferences…’

In the popup, select the Ports tab.
You can now check which Apache Port MAMP is using. We recommend switching to Apache Port 8888 if MAMP isn’t already using this port.

The next step is setting your document root folder. This is the folder where you will create and store all of your local WordPress websites.
By default MAMP uses the /Applications/MAMP/htdocs/ folder, but you can change this to any other location.
In the ‘Preferences…’ dialog box, click on the Server tab. You should now see your document root.

To store your sites in any other folder, click on the ‘Choose…’ button.
This will open a popup where you can choose a new location. You may also want to create a new folder where you’ll store all your WordPress websites.

You can name this folder anything you want.
For the sake of this article, we will be storing our websites in a folder called ‘allwebsites.’

Installing WordPress on Mac
Now you’ve set up MAMP, let’s go ahead and install WordPress on your Mac computer.
First you need to visit the WordPress.org website and download the latest version of WordPress core.

NOTE: There are two versions of WordPress. For more details, see our comparison between WordPress.com vs WordPress.org.
After downloading the file from WordPress.org, you just need to unzip it. This will create an unzipped ‘wordpress’ folder.
Now simply copy this folder into your MAMP document root folder.
Since we changed the document root folder, we need to copy ‘wordpress’ into applications/MAMP/htdocs/allwebsites.

WordPress needs a database to store all of its content and data. You’ll need to create this database before you can create a local website.
Don’t worry, it’s not as hard as it sounds!
In the MAMP ‘Preferences…’ window, simply click on the OK button. This should launch the MAMP application in a new browser tab.

Our next task is launching phpMyAdmin. This is a web-based application that you can use to manage your website’s MySQL database.
In the toolbar, click on Tools » phpMyAdmin.

This will open phpMyAdmin in a new tab. In the phpMyAdmin dashboard, click on the Databases tab.
You can now type a name for your database into the ‘Database name’ field. You can name your database anything you want. Just be sure make a note of the name, as we’ll be using it in the next step.
For this tutorial, we will call our database test_db.

After typing your database name, click on the Create button.
PhpMyAdmin will now go ahead and create your database.

Now it’s time to install WordPress.
In a new browser tab, simply go to http://localhost:8888/ If you’re using any port other than 8888, don’t forget to change this URL to mention your port.
You should now see a link to the ‘wordpress’ folder you copied into your root document folder.
You can now go ahead and click this link. This will open the WordPress installation wizard.

The WordPress installation wizard starts by asking you to choose a language. Go ahead and make your choice, and then click on the Continue button.
On the next screen, WordPress lists all of the information it needs to complete the installation.
After reading this screen, click on the ‘Let’s go’ button to move forward.

The setup wizard will now ask for your WordPress database information. For database name, simply type the name you created in the previous step.
For Username and Password, type ‘root.’ You can then type ‘localhost’ into the ‘Database Host’ field.

Localhost just means that the database and website are hosted on the same server. In this case, the server is your Mac computer.
After typing all this information, just click on the Submit button.
WordPress will now connect to your database and create a configuration file for you. Once it’s finished, you’ll see a success message.
To move onto the next step, click on the ‘Run the installation’ button.

On the next screen, WordPress will ask you to add a site title.
Most WordPress themes show this title at the very top of your website. This means the site title is often the visitor’s first introduction to your site.
That being said, it’s smart to type a descriptive and informative title into the ‘Site Title’ field. For example, you might use your business name.
The site is important, but you can also change the title in your WordPress dashboard at any point. If you can’t think of anything right now, just leave the ‘Site Title’ field blank.

You’ll also need to create a username and password. This is the login information you’ll use to access your WordPress dashboard.
You can also type your email address into the Your Email field. This is the address where WordPress will send all of its admin emails.
After completing this form, click on the Install WordPress button.

WordPress will now run the installation.
After a few moments, you should see a ‘Success!’ message.

To jump straight to your WordPress login screen, click on the ‘Log In’ button.
You can also log into your local WordPress website using the following URL: http://localhost:8888/wordpress/wp-login.php
NOTE: If you’re using a different Apache Port, you’ll need to change the ‘8888’ part of this URL.
You can now go ahead and log into your WordPress site by entering the username and password you created in the previous step.
This will take you to the WordPress dashboard.

Trying WordPress Locally on Mac
A local install is perfect for testing out WordPress or developing websites on your computer. Now you have WordPress running locally on your Mac, here are a few things you may want to try.
- Experiment with the best WordPress themes.
- Try to find your perfect WordPress theme.
- Test out essential WordPress plugins locally.
- Learn WordPress programming by creating your own plugins and custom themes.
Moving Your Local WordPress Install to Live Website
Once you’ve played with WordPress locally, you may want to move your WordPress install to a live website. This is the only way others will be able to see your website.
To do that you’ll need to buy a domain name and web hosting. A domain name is your website’s address on the internet, and web hosting is where your website files are stored. You can think of web hosting as your website’s home on the internet.
For web hosting we recommend using Bluehost. They are one of the biggest hosting companies in the world. They’re also officially recommended by WordPress.org.
Luckily, Bluehost are offering WPBeginner users a discount on hosting and a free domain name. Basically, you can turn your local WordPress installation into a live website for $2.75 per month.
Once you have purchased hosting, see our article on how to make a website with WordPress.
Have you already built a complete website on your local computer? Then you may want to check out guide on how to move WordPress from a local server to a live website.
We hope this article helped you learn how to install WordPress locally on Mac using MAMP. You may also want to see types of websites you can create with WordPress or how to get a free SSL certificate for your new WordPress website.
If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.
Mari says
Hi there,
First, thank you for creating this guide, it was quite helpful. In fact, Ive been using my local site since march. But a few days ago when I went to log in to work on it I received this message on blank white screen,
“There has been a critical error on this website. Please check your site admin email inbox for instructions.
Learn more about troubleshooting WordPress.”
Im not quite sure what this means or where to actually go to rectify the error. Any instruction or an arrow on which way to turn would be humbly accepted. Thank you.
WPBeginner Support says
For troubleshooting errors in general you would want to take a look at our guide below:
https://www.wpbeginner.com/beginners-guide/beginners-guide-to-troubleshooting-wordpress-errors-step-by-step/
Admin
RG says
I’ve tried to install the wp locally.
But I’m stuck when I have to go to localhost/mywebsite
When I type this in the browser, I get an empty white page and when I click on the MAMP webstart / my website I get ‘forbidden you don’t have permission to access this ressource…
WPBeginner Support says
You would want to ensure you are an admin on your mac and for the mywebsite URL you would want to ensure that is the name of the folder your WordPress site is installed in.
Admin