My sites are so slow running on my local machine, with MAMP on Mac.

Any ideas of how to determine where the slow down is?

It's slower than making changes on my host!


  • Whats the overall database size for the site that is running slow? – Ravi Shinde Jan 24 '17 at 6:02
  • IPv6 settings have been a culprit for me in the past. Also, you may like something like "VVV" for spinning up local WP environments. – Nathan Powell Jan 24 '17 at 7:03
  • Database is 3 meg. – pcrx20 Jan 24 '17 at 10:28
  • It used to be fast - I don't want to have the hassle of setting up VVV. Rather work out why so slow to load on MAMP. – pcrx20 Jan 24 '17 at 10:29

Go to wp-config.php, find the line below:

define('DB_HOST', 'localhost:8889');

And change it to:

define('DB_HOST', '');

Works like a charm!

  • 1
    Works! Thanks. I can't believe I was so lazy all these year, to never look into this. So many wasted seconds do add up. – MarsAndBack Jan 5 '19 at 5:06
  • This is great, I never knew about this! – Nathaniel Flick Jan 25 '19 at 2:46
  • Didn't worked for me... – Mr. Jo Jan 16 '20 at 22:44
  • 1
    Worked well for me! Why does this fix work? – James Hamilton Feb 3 '20 at 10:15

Not the answer you're looking for? Browse other questions tagged or ask your own question.