The place to learn about your Mac. Tips and tutorials for novices and experts.

Make a Mac Web Server with MAMP and Wordpress

MAMP stands for Mac, Apache, PHP and MySQL, and installing it on your Mac creates a development environment for testing many of our favorite tools. You can do everything from browsing simple PHP files to testing complicated MySQL database driven applications right on your hard drive.

Installing MAMP takes just a few minutes. Macinstruct's Matthew Cone created a tutorial on installing MAMP and installing Drupal, so I won’t go into installing MAMP here. If you need help install MAMP, take a look Matt’s tutorial first.

Wordpress is another application that I like to configure on my machine and test before going live. Testing new themes, widgets, etc. is a lot easier directly on the development machine than it is to constantly upload new files and run them on the public site. With this little tutorial and MAMP, you’ll be testing in 10 minutes or less.

I’m using MAMP PRO, but the free version of MAMP works just the same. I have my MAMP settings running apache as users www/mysql. This is the recommended setting for a computer that is online, as it’s a bit more secure than using your user name.

Here's how to set everything up after you have installed MAMP:

  1. Navigate to the start page, http://localhost:8888/MAMP/?language=English or click open start page in MAMP PRO, and then click the link to launch phpMyAdmin to create a database for your wordpress install.

    To keep it simple, I called the database WordPress, but you can name it whatever you like.

  2. Download Wordpress.

  3. Put the unzipped contents of the install in:

    Applications > MAMP > htdocs directory

  4. Locate the wp-config-sample.php file in the Wordpress folder and open with a simple text editor. I use BBEdit, but you can use TextEdit if you prefer.
    You’ll need to change the variables in this file to be the same as your MySQL information. If you don’t remember what that is, open MAMP and look at the the general settings panel under MySQL.

  5. Enter the name of the database you created, the user name, password and host (for MAMP this is probably locahost:8889).

    Save your edited file as "wp-config.php".

  6. Now run the Wordpress installer from http://localhost:8888/wordpress/wp-admin/install.php. When you install, Wordpress will randomly generate a password. Make sure you save this and change it as soon as you log in, by going to the options menu in Wordpress.

  7. Go to http://localhost:8888/wordpress/. You should see a default installation of Wordpress, ready to start testing all those cool new themes or plug-ins!

Meet Your Macinstructor

Janet Fouts is a web developer and designer who provides tech support for a bevy of clients and friends who need a little help with their Macs.


Copyright © 2016 Macinstruct. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.