Support » Localhost Installs » Setting up local development environment on Mac for existing site

  • I run a WordPress blog site that I’d like to redevelop using a StudioPress Genesis child theme. I don’t want to take the site down, so I’d like to do this with a local WordPress install on my iMac. I have used MAMP to get a clean local WP install. However, I don’t want to lose all my old content, comments, images, etc. when I go live. Is a clean local WP install the best approach, or should I be working on a local copy of my existing site? If I need a local copy, can someone help me set that up? I’ve seen Test Driving WordPress and Installing WordPress Locally on Your Mac With MAMP, but I could use a little help connecting all the dots. Thanks!

Viewing 1 replies (of 1 total)
  • I’m curious as to whether you’ve found a solution to your problem, as I’m in a very similar boat with a Multisite installation that I want to develop locally, but the issue I’m trying to resolve is with synchronizing the databases, after I’ve made changes locally and pushed the changes back to the live remote server. …anyway, don’t want to hijack your thread, but it’s been 2 months with no response.

    As far as your other questions, I’ve done some of those things and I’d suggest working with a local copy by copying down all of your site files (via FTP) to your local computer. Also, export your site database in phpMyAdmin. Clone both of these and archive them, as a fallback. Install MAMP and locate the /html folder in your Applications/MAMP folder and move your site files into this folder. I’d put the files into a parent directory, so you can manage multiple sites with MAMP, i.e. “”. Create your new database with MAMP and import the database file. Then, open your wp-config.php file for your WordPress site and edit the database name (the name you just created for your new database), username(root) and password(root)–you’ll need to change these back before going live, to reconnect with your live database. That should connect all the dots.

    <edit> I left out one important step. You’re going to need to update your permalinks in your database, so that they direct to your local install. Use a text editor to Find and Replace any instances of your remote site domain, i.e. or, with localhost/mylocalsite/. This will clean up the link paths in your site, so you can navigate properly and it will enable you to access your WP Admin Dashboard–otherwise, I believe you’ll get kicked out to your live site login.</edit>

    You will likely need to clear your browser cache and restart your browser before targeting your local site (MAMP/html/) directory. Just go to “local/” in your browser and you should see your list of available site directories.

Viewing 1 replies (of 1 total)
  • The topic ‘Setting up local development environment on Mac for existing site’ is closed to new replies.