This guide will show you how to quickly and easily install MAMP, so you can use Apache (and Nginx), PHP and MySQL on your Mac.
Although this guide was initially published in 2008, it has been updated to be current in 2021.
Before you go any farther, there is an alternative to installing MAMP that may accomplish the same thing (local access to AMP) but with more features. You can run LAMP (Linux, Apache, MySQL and PHP) in as a virtual machine via a Bitnami stack for VirtualBox (or VMware Player) and accomplish almost the exact same thing. Depending on exactly what you want to do with AMP there may even be a specific Bitnami stack already completely configured – for example, WordPress. You may want to review the documentation for Bitnami and the documentation for MAMP to decide which one best suits your specific needs.
If you decide to go the MAMP route instead of a virtual machine running LAMP – here’s how to install, setup and use MAMP on your Mac. MAMP works in versions macOS 10.12 and later (including macOS 11 “Big Sur”).
- First things first, download MAMP. Run the .pkg file to start the installation. For the most part you’ll click Continue a bunch of times.
- Once the installation has completed, open a Finder window and navigate to your Applications folder, select MAMP and then double-click MAMP.app to start MAMP.
- The first time you launch MAMP a window with info on MAMP Pro will appear. For now, close this window. If you want you can check out the MAMP Pro features later.
- Before you jump in, click the Preferences button found in the upper-left corner of the MAMP panel.
- Take a look at each of the preferences and settings and make any changes you see fit. When you’re done, click the OK button.
- Back in the main MAME window, click the Start button found in the upper-right corner of the panel.
- It will take a moment or two for each of the services to start up.
- When everything has completely started up, the Start button will become green. Click the WebStart button.
- A browser window will open and display info about your Apache, MySQL and PHP settings. From here you can launch tools like phpMyAdmin – which you can also do by entering the URL:
- If you click the My Website link you’ll be taken to the placeholder page for where you can put all of your web files. You can also access the My Website link by entering the URL:
- Open a Finder window and navigate to your Applications and then select the MAMP folder. In here you’ll see a folder named htdocs – this is where you can put your web/php files and then access via http://localhost:8888
- That’s it – now you’ve got a working Apache, MySQL and PHP setup on your Mac.
If you ever find yourself in need of Apache, MySQL and PHP in Windows, check out our guide for installing and setting up WAMP.