Locally Install WordPress

MAMP Installation and Settings

The application we will be using to setup a local server environment is called MAMP (Macintosh, Apache, MySQL, and PHP) You can download it here.

After downloading, double click the .pkg file and run through the installer. Once successfully installed, launch the MAMP.app, then navigate to Preferences…, and then to the Ports tab. Click Set Web & MySQL ports to 80 & 3306, which should trigger a password prompt.

Next thing that needs to be done is to set a document root. This is where all the files will be stored for the local web server. Example root: /Users/USERNAME/Sites/wordpress/. To do this Navigate to the Web Server tab and select a destination path.

Screen Shot 2015-11-18 at 3.03.53 PMMAMP App Home

Screen Shot 2015-11-19 at 11.22.57 AMMAMP Ports Tab

Screen Shot 2015-11-18 at 3.04.20 PMMAMP Web Server Tab


Database Creation

First, start the the MAMP servers by simply clicking the Start Servers button. The Start Servers icons should turn green indicating the servers are on, which should trigger the MAMP start page to open. If the start page fails to open click the Open WebStart page button.

Once open, select the phpMyAdmin link then navigate to the databases tab. Under Create database enter a database name and press create. “wordpress” will be used in this example. Ignore the “collation” select input, this will be automatically set by MySQL while the database tables are created during the installation of WordPress.

Screen Shot 2015-11-18 at 3.04.44 PMMAMP WebStart Page

Screen Shot 2015-11-18 at 3.12.48 PMphpMyAdmin

Screen Shot 2015-11-18 at 3.14.14 PMNew Database Creation


WordPress Installation

With localhost setup, WordPress can now be installed. First, download WordPress and drag all the files into the document root ( /Users/USERNAME/Sites/wordpress/ ).

Now with the files in place, it’s time to run the WordPress installer. Visit the local site by typing: localhost into the browsers address bar. Enter the following into the database setup form then run the install.

Database Name: wordpress (same as the root folder)
User Name: host
Password: host
Database Host: localhost
Table Prefix: wp_

Once that’s complete, enter a name for the blog and email, then you’re ready to use WordPress on your Mac!

References:
https://codex.wordpress.org/Installing_WordPress_Locally_on_Your_Mac_With_MAMP
http://www.wpbeginner.com/wp-tutorials/how-to-install-wordpress-locally-on-mac-using-mamp/