

We will need to make some changes to Apache's settings so that it works well with this setup. If you need to create the sites folder manually run the following command mkdir ~/Sites or create the folder in finder under your user directory. OSX Lion and later versions do not come with a default Sites folder, the Sites folder disappeared (along with the web sharing toggle in the System Preferences pane) beginning with OS X 10.8 Mountain Lion. Ideally we want to store our websites in the 'Sites' folder under the user account. This step is not required if you would rather, just prefix some of the commands below with sudo and enter your password when prompted.Īpache by default runs out of the /Library/WebServer/Documents/ directory. You will be prompted to enter your user account password, after typing your password, submit by hitting enter. Note: $ sudo su - will allow commands to be run in the root environment so you will not have to type your password after every command. As of OS X Sierra, the php build included is PHP 5.6.x El Capitan ships with PHP 5.5.x and OSX 10.8 Mountain Lion ships with PHP version 5.3.
#Mysql download for mac sierra install
After Homebrew is complete, we're going to install the latest version of PHP and Apache.

The installation process will take a few minutes to finish. Open terminal and run the following command to install Homebrew: $ sudo launchctl unload -w /System/Library/LaunchDaemons/ 2>/dev/null Let's make sure the default version of Apache is off and will not start automatically at startup.
#Mysql download for mac sierra mac os
Once installed open terminal and run the following command to install the Xcode command line tools:Īpache and PHP have both been included with Mac OS but we will be using the Homebrew package manager so that we don't overwrite any system packages that will be lost upon operating system upgrade. TLDR: If you are impatient or would like a quicker solution without touching the command line, a MAMP GUI installer program can be found here: įirst Xcode and it's command line tools will need to be installed, it can be found on the App Store here: Follow along and you’ll have a MAMP local server environment running on your Mac in no time! MacOS however does not ship preinstalled with MySQL but setup is easy. MAMP refers to a Mac, Apache, MySQL & PHP stack that is typically used for local web development.Īpache and PHP are both bundled with macOS and can easily be enabled by editing a few files. Setup a MAMP local development environment on the latest macOS Install Apache, PHP & MySQL on macOS Sierra
