Setting up a WordPress local development environment

Nov 20, 2012 by

This entry was written by , one of the OxonDigital members. The author's views below are entirely their own and may not reflect the views of OxonDigital.
Setting up a WordPress local development environment

Setting up a WordPress local development environment

As a web designers, developers and SEO specialists we are continually learning new skills. If you have decided to use WordPress for the design and dev of your next site, one of your first tasks will be to set yourself up a local development environ. I chose MAMP Pro as I am working on a mac and wanted to commit to a solid working environment (there is a free version available if you want to try before you buy).  To help anyone along that is heading down the local dev route here are six easy steps to get things up and running, and have you logging in to your local WordPress site.


Step 1 – Setup MAMP Pro

Download MAMP Pro

Mount the disk image and install MAMP Pro in your Applications directory

Turn on the MySql database and Apache servers by clicking the MAMP application

Click the Webstart Button in MAMP Pro to open the Welcome screen, where you will see this important info (you’ll need this later for your config.php settings)

Server Details

Step 2 – Install WordPress

Download WordPress

Uncompress your zipped ‘wordpress’ file and place in your htdocs folder of your MAMP Install (you can rename the file at this stage if you like but I have left it as wordpress)

Step 3 – Setup WordPress Database

Open phpMyAdmin by clicking on the phpMyAdmin tab on your MAMP welcome screen

Create a new database called ‘wordpress’ (or similar) by filling in the text field and clicking create

Step 4 – Point WordPress to the Database

In your local ‘wordpress’ folder you will find a file called wp-config-sample.php

Open this file in a text editor and resave as wp-config.php

Important Step. You will need to edit the settings in this file to match your database settings.

define(‘DB_NAME’, ‘wordpress’); – The name of the database
define(‘DB_USER’, ‘root’); – Your MySQL username (see Step 1)
define(‘DB_PASSWORD’, ‘root’); – and password (see Step 1)
define(‘DB_HOST’, ‘localhost:8889’); – local directory (see Step 1)

Step 5 – Initialise WordPress

Point your browser to your localhost – http://localhost:8888/wordpress

And follow the prompts to finish the your WordPress local install.

Wordpress Initialise

Step 6 – Login to Admin

Congratulations you now have a local install of WordPress

To access your login area go to http://localhost:8888/wordpress/admin and enter username and password setup in the previous step

Adding Themes

WordPress has a default theme installed Called TwentyEleven. Or you can go ahead and and install a theme, or themes of your choice under Appearance / Themes / Search themes and experiment with adding content and developing locally.

I hope this has been helpful to anyone setting up their first install, any comments, additional tips  or improved ways of doing things please feel free to add. Have fun.

Define Media - Creative web and graphic design services. Follow Maria on Google Plus.

Related Posts

Share This



  1. Nice guide Maria, can MAMP publish the site to a server (including the MySQL databases)?

    An alternative for Windows users is WebMatrix from Microsoft, a free solution which allows you to setup local environments for a huge number of CMS’s and platforms.

  2. Hi Colin,

    I don’t think you can publish files directly from within MAMP, as far as my knowledge extends at this current point in time. I have used Dreamweaver or Filezilla to publish the WordPress files to a server, exported my MySQL database from MAMP, re-imported it into a live database, and search and replaced incorrect directory paths using

    Thank you very much for the Windows option, I am aware that I am being a bit mac-centric here.

    Cheers, Maria

  3. Wordpress Developers UK

    Thank you for putting this together i will use this to setup wordpress on my local network


  1. Moving a Wordpress site from local to live | OxonDigital - [...] a follow up to my previous post on Setting up a WordPress local development environment, the next step is Moving…
  2. Setting up Additional Local Wordpress Sites - [...] a follow on from my previous posts Setting up a local WordPress Development Environment and Moving a WordPress site…

Leave a Reply

Your email address will not be published. Required fields are marked *

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.