Good instructions. The only thing in my case is that I Duplicator (free version) doesn’t support Multisites. I believe you have to use the Pro version if you want to execute the above steps with Duplicator.
Instead of trying to work with MAMP and Duplicator, just use a backup plugin like Updraft Plus to backup your site, and then import it into Local. Here’s how that might go:
With your site running in MAMP, use Updraft Plus to make a backup to Google Drive or some other folder you can access later.
Create a site in Local with the same name
Install Updraft Plus in the Local site and then import the backup you made from the MAMP site as if you were simply restoring a backup.
I do this all the time when switching between Desktop and Laptop for development work. I make a backup from the Desktop and upload it to Google Drive, then import it into the Laptop.
Thanks so much for outlining this solution! It’s the simplest, most logical one I’ve found so far. Honestly, all I’m trying to do is test a restore using UpdraftPlus before making updates to a client site I’ve just taken over and wanted to do so on a Local version.
I think I screwed up somewhere and hope you’re checking this and can help!
I installed UpdraftPlus on my Local site and in my Settings, I selected the same Dropbox folder as my live site
This Dropbox folder for my live site had the backup in it
In my Local site, I went to Backup/Restore and selected the backup files from my live site folder
It did a restore, but went to my live site URL - I can’t access the wp-admin now on the Local version
@Lil625 When you restored the site from a backup, I assume it replaced your local database with one identical to the production database. That database will be peppered with the domain name and file paths of the live site. That’s probably why your local site is redirecting you to the live site.
When you migrate a database between sites with different domain names you need to find & replace the domain name and system file path wherever they appear in the database, so that they match the domain and file path you chose in Local. This shouldn’t be necessary, but WordPress was poorly designed in this respect.
You can’t just do a string based find & replace, however, since the database includes serialized data too. I recommend using a plugin to perform the find & replace for you. Perhaps Updraft Plus has this feature? I always use WP Migrate DB Pro, which handles serialized data gracefully.
Or, as @clay suggested in the original post, you can drag a zip file containing your site’s database and file system directly into Local and I believe it will change the domain name and files paths to match those you selected in Local.
@jnicol thank you for the quick reply. Makes sense for the most part, although I’m definitely not technically savvy in these areas. But I think I can make my way through, and appreciate your awesome explanation and additional supplemental/alternate approaches. Thanks again!