Podcast Episode

325 – Tools to Sync Your WordPress Databases

Announcements

  • No announcements this week.

Is there a plugin for that?

With more than 50,000 plugins in the WordPress repository, it’s hard to find the perfect one. Each week, I will highlight an interesting plugin form the repository.

For more great plugins, download my 50 Most Useful Plugins eBook.

Cherry Search is a plugin that you will be able to add advanced search functionality to your WordPress site.

Your Website Engineer Updates

  • Fixed all optin form in each post
  • Tested out WP Site Sync and Mergebot

Tools to Sync Your WordPress Databases

WP Migrate DB Pro

WP Site Sync

MergeBot

Thank You!

Thank you to those who use my affiliate links. As you know I make a small commission when someone uses my link and I want to say thank you to the following people. For all my recommended resources, go to my Resources Page

Full Transcript

Business Transcription is provided by GMR Transcription.

On today’s episode, we’re going to talk about a couple different tools to sync your WordPress database, right here on Your Website Engineer podcast, episode number 325.

Hello everybody. Welcome back to another episode of Your Website Engineer podcast. My name is Dustin Hartzler and I am excited to be here this morning, or this afternoon, this evening. Whenever you may be listening to this. I hope that you have been finding value in the last couple episodes when we’ve been talking about tools and different debugging plugins, different essential plugins for your WordPress site, and how to build your sites, and all of these things that we’ve been talking about in the month of February. Today we want to continue that discussion.

I want to talk about a question that I get an awful lot. But before we do that, before we dive into the real episode or the full piece of the episode, let’s go ahead and look at the plugin of the week. There’s not a lot of news in the WordPress space this week. There’s not a lot happening. It’s not like we’re looking for a newly released version of WordPress because we’re in this kind of a new development cycle, so we’re not getting a new release every four months or so. So, there’s not really a lot of news that’s happening in the WordPress space. So, let’s dive right into the Is There a Plugin for That section.

There’s more than 48,000 plugins in the WordPress repository. All free plugins, mind you. And there’s thousands upon thousands of thousands of premium plugins as well. It just makes it really hard to try to figure out and narrow down what’s the best plugin for whatever you may be looking for. So, each week I try to highlight a plugin here that I find interesting, one that may become useful for someone that’s listening. So, I just want to go ahead and take a look today at a plugin called Cherry Search. This is a WordPress quick Ajax search, so it allows you to turn your search fields on your WordPress site into a – it kind of turns it into Google. You know how when you start typing in Google it automatically starts displaying results and displays those drop-downs? Like, if you want to say, “How to become a” and then it give you all kinds of suggestions, that’s exactly what this does.

This is one of the first plugins in a while that I’m like, “Huh. I wonder how this works.” I actually installed it on the development version of YourWebsiteEngineer.com, and I took a look at it and it need a little bit of formatting to work well with my theme, but it worked really well. It was really kinda neat. It was a plugin that turned my search boxes that were already on my website, it went ahead and it just started working, which was really cool.

There’s some features that you can use to set up, but basically when you start typing, it will show you the featured image of the post, it shows you the title of the post and the excerpt of the post, and the author of the post. All those settings can be turned on or off, so you can make that box exactly what you want. But it’s really kinda cool. It’s a neat plugin. It’s got just a few settings. It is a free plugin on the WordPress repository. It’s a new plugin. It’s only got 400 active installs.

One other thing you can do is you can enter this on any page, so if you wanted to add it on a 404 page or something, there’s a short code that you can use, or you can add it to a theme by they provide you a function that you can add, and it’ll all just automatically work on any type of template. So, if you have a hardcoded footer and you want it to always appear in the footer, you can go ahead and do that.

If you’re interested in something like this, definitely check out Cherry Search. You can just search for Cherry Search on the WordPress repository.

Aright. In the Your Website Engineer news update, I didn’t get a lot of work done again this week. There’s just been a lot going on. I taught a class on Monday of this week at Ohio University about WordPress, and it was focused on WooCommerce but I also talked about the way that we work at Automatic for these college students to just kind of highlight and show what it’s like to work for a tech company. So, I spent a lot of time last week just working through and trying to figure out what am I gonna talk about and putting that presentation together.

I did go through and I fixed some more Optin boxes that were broken on my website. Again the numbers of people that are signing up for an email newsletter has been constantly going up since that point. Obviously, if you want to collect newsletters or email addresses for a newsletter, you have to have boxes that are actually working. I found that out the hard way this week.

I also did a little bit of work on a couple projects for my wife. She’s got some websites that she’s up and running, so we worked on those some. And then I tested out two plugins that we’ll talk about here in just a second to get ready for the show.

Let’s dive into the main topic. This is a question that I get pretty much, I would say probably at least once per week, if not more, over at WooCommerce support. A lot of people want to know, “I’ve been working on my development site and I’ve got it all ready to push live, but the live site has been turned on the entire time, and we’ve been getting new orders. How do I merge those databases? How do I merge the content I’ve been working on without overriding all of the changes that have been made on the live site?”

This can happen on your blog if you’re just running a blog and you have all kinds of comments that are coming into your site. If you want to replace the database from your local environment to your live environment, you’re gonna lose all of those comments. So, it’s a really important piece of the puzzle. It’s just a little bit difficult to figure out, okay, how are we gonna do this? What tools are we gonna use to be able to push our data back and forth between the two versions of the site?

So, I’ve got two tools that you can go ahead and download and start using today. The third tool that I’m gonna talk about in just a little bit that is still in beta, that I’m on the beta team and beta testing it, and it’s mainly to see how this would work for a WooCommerce store. So, let’s go ahead and dive right in.

The first plugin that I want to talk about today is called WP Migrate DB Pro. I’ve been a loyal customer and subscriber for WP Migrate DB Pro ever since I had my own web design business, so that was like four years ago. This plugin just keeps getting better and better. Basically what this does, is it allows you to quickly and easily replace your database from your local to live, or live to local, depending on which way you want to go.

Typically, if you wanted to do this work, what you would have to do is you would have to go in and you would have to go into phpMyAdmin or whatever system you’re using to manage your database on your development site. Then you would to export the whole thing, and then you’d have to download that export file. Then you’d have to go to your live site, and then from your live site then you’d have to go to the same phpMyAdmin, and then you’d have to import and you’d have to overwrite all of the changes that are there, and then you could have two sites that are exactly in sync.

Before you did that, before you imported, then you had to do a find and replace, because the domains are gonna be different and so you’d have to do all of that. So, it was just very tedious and it was a lot of work. So, this tool came out, it’s called WP Migrate DB Pro, and basically it does all of that for you right from the WordPress dashboard. So, you install the plugin, you get it set up, and you connect the two sites. So there’s an area within the plugin when they’re both turned on that you add a secret URL from your live site. And you put the live site secret URL on your dev site, and you put the dev site one on your live site, and so they can talk to each other and they can sync back and forth. Then what it has, it’s got three options. It basically allows you to download your database, you can push your database to the live site, or you can pull your database from the live site. So, those are kind of the main features, if you will.

It also has built-in find and replace fields, so you can say, I want to take everything I’m pulling in from – I guess, let’s look at the use case scenario that I use regularly. I keep everything local. I run my website local, but I publish all my podcasts. All of those are published live, right on YourWebsiteEngineer.com. So, every time I have a new podcast, I go to YourWebsiteEngineer.com, I add the new post, upload the new image, add the podcast—all that stuff is done on the live site. And then I keep the local site, I keep that updated kind of regularly, I guess. Most of the things that I’m doing locally when I’m fixing or debugging, like I don’t need to have the latest episode, but probably, I don’t know, four, five, six times a year, maybe once every two months or so, I will pull all of the data from my live site onto my local site. So, then I can just make sure that everything’s in sync. It’s a great way to keep things backed up. That way I have a local copy that’s pretty close to accurate on my live site, and that’s just the way that I’ve been working for the last couple years.

So when I use this, I will, on my development site, so YWE.dev is running locally on my computer using Desktop Server. And then what I do is I click a button so I pull that from my live site. Then there’s a find and replace feature, so I have to replace all the URLs that say YourWebsiteEngineer.com, I have to replace those with YWE.dev because that’s my URL on my local site. And if you have multiple things in there that you need to be changing, you can add as many find and replace things as you want. That’s typically the only find and replace that I do.

Then I click a button and it starts this polling process, and it pulls all the fields from my live site. It pulls in all my posts, it pulls in all my custom post types, it pulls in all of my – anything that’s in the WordPress database, it just basically syncs it. It syncs which plugins are turned on and which ones are turned off. It syncs all that data. Everything just gets pulled down so then I’ve got an exact copy running locally on my computer. So, that’s the easy part. Super easy. You click the button and it automatically works.

I have a pretty unique use case where I’m the only one working on the site so I don’t have somebody else updating posts and then I’m trying to push things out. So, this isn’t the best tool for that. But what else you can do with Migrate DB Pro, is if you’re working on specific areas of your website, you can push and pull specific tables. So maybe you’re going in and you’re setting up, let’s say for example, the Yoast plugin. When you’re doing some things with your local site, you can push just the tables in your database for the Yoast plugin. You can push those rights to your live site. So, that would only affect the Yoast tables and you could push those.

Or, if you wanted to only update a certain custom post type, so if you wanted to only update posts and not pages, you could go ahead and do that. It works really, really well. It takes a little bit of practice, and I highly recommend if you want to check out using this, then you definitely want to set up a development site and a development live site and a dev practice site, make some changes and make sure that you’re not overwriting changes and you’re not breaking things. Because I’ve had that happen before. It’s like, ooh, that’s not exactly how I thought that was gonna happen, and then I have to do a restore and it’s just kind of a pain.

So, this is the first plugin that I want to talk about. WP Migrate DB Pro. I do have an affiliate link for WP Migrate DB Pro, and you can find out more just by going to YourWebsiteEngineer.com/migrate, and that will go ahead and just forward you to the right place and you can take a look at it. That’s kind of a standard package. They have three different licenses, I guess. They have the person, which allows up to 12 sites, and that counts like it’s basically 6 pairs of sites. So, YourWebsiteEngineer.com and YWE.dev, that counts as two sites. It comes with all the pro features, and you get updates and email support for a year per person. That’s the license that I have. I don’t have a lot of active installs, so that’s the one that works for me.

The developer is 100 installs. It works well with Multisite. It has pro features and it includes the two other extensions, the add-on extensions, and that is Media Files addon and WP CLI addon. So that’s $200. Then there’s the elite for 200 active installs, works with Multisite, it’s got all the pro features and all the extensions, and you get priority support. That’s for $450 per year.

What are these two addons or extensions? One is called Media Files, and it helps you sync media files between two websites. So, if you upload some sort of image to your live site, it will pull those down and put those in your local install. Then the WP CLI addon will allow you to run migrations right from the command line, where you can call functions and do things right from the command line. So, if you wanted to sync or do something, you can do it all from the command line if you are a command line junkie.

That is WP Migrate DB Pro. It works really well. I think it’s a really good case for if you’re trying to sync two pieces of content or two websites with not a lot of changes, or mostly if you’re trying to pull down the live version. This is probably a good example: if you are running a – if you’re just working on a client’s website, but your dev site gets outdated because they’re adding new content, they’re adding new blogposts, stuff like that, and you want to keep your local site updated, you can go ahead and use WP Migrate DB Pro, and that will sync all the data right down to your computer or your development site, wherever that is.

I really like WP Migrate DB Pro. It’s a total steal for $100 per year. If you think about how often you use it versus how much time it saves you, I think if you do the export and the import with the database and do all of that jazz, you’re talking ten minutes maybe to do that setup. So, if you do that ten times, you know if you’re doing this a few times per week, times 52 weeks per year, you’re gonna save a lot of time for the $90 that it costs for this plugin. So, go ahead and check that out at YourWebsiteEngineer.com/migrate.

The second tool that I want to talk about today is called WPSiteSync. This is a newer plugin. This is one that I just recently started testing, and it is one that is a pretty slick plugin. It can do some cool things. It isn’t nearly as feature-rich as WP Migrate DB Pro. There’s a few things that it can do really, really well, and that’s what I wanted to highlight today.

The first thing that I want to share with you is it allows you to synchronize content. That’s the big thing. It is allowing you to sync posts and pages between sites. This makes it really nice and really handy to, if you’re working on a post on a development site –let’s say you want to update your About page. You want to work on this, and you want to work on this but you don’t want your customers and your people coming to your website, your live viewers to see it. You can work on it locally, and then when you’re all done with it, you like it and you’re ready for all the changes, you can just click this button that says Push Data to Live Site, and then it will automatically take all the information and then push it out to your live site. It works pretty well. It’s pretty neat.

You can automatically update the taxonomy information. So, if you wanted to work on your website, you’re doing it locally, and you’re doing all kinds of things to change the categories and tags and things like that in your post, then you can push all those changes to your live site as well. You can do metadata as well, including advanced custom fields and things like that. It’s smart enough to know when comments are on the live site, so when you push your data from your dev site, it’s not going to overwrite comments. It’s only pushing the post data. I guess it’s pushing the post data, the featured image, and some of those other things, but it’s not overwriting the comments. This is really helpful if you wanted to do an update to a post, and you wanted to do that locally and then push it out later, you can go ahead and do that as well.

It synchronizes attachments, moving images between sites, and things like that like I did say. So, that’s some of the things that WPSiteSync does. They do have a limited free trial that allows you to sync blog posts and pages, featured images, PDF sync and taxonomy sync. So that’s limited. You can download it for free in the WordPress repository. They do have two different versions. They’ve got a starter kit for $99 per year, and then they’ve got the premium bundle for $249 per year. The premium gives all kinds of things that basically does bi-directional syncing, so you can sync from dev to live or live to dev. You can do custom post types, authors, menu syncs, bulk actions, comments, users, batches, BeaverBuilder, Genesis Settings, Gravity Forms, Ninja Forms, Divi, guaranteed updates. You got priority support, like you can do some really advanced things.

The thing is that I’ve seen about this plugin is like, you first install the free version of WPSiteSync, and then if you wanted to be able to do bi-directional syncing, so if you wanted to push to your live site or pull from your dev site, then you need to install an additional plugin. And then if you wanted to sync your menus from dev to live, you’ve got to add another plugin. And then if you wanted to use users, you’ve got to add another plugin. So it’s not all built in. You know, they all come together, but I think the developers are doing a good job of keeping things separate, so you don’t need to – if you’re never gonna sync menus back and forth, then you don’t need that plugin or extension to be turned on or polled.

A few notes that I did find when I was testing this plugin out. If the content isn’t on the dev site, there’s no way to pull it back in right now. For example, I was working on this site with my wife, and she was writing a blog post, and she had it saved as a draft, and I wanted to pull that into the development site, and there was no easy way to do that. There was absolutely no way to do that. I was expecting maybe a button at the top of the All Posts or All Pages so I could pull in all content from live, and there wasn’t anything along that line. So, the post has to be created on both places, and it has to have the same post ID to be able to sync back and forth. So, that’s one thing that I saw.

Then, you need the Pull module from the live site. So, you can’t just right out of the box pull, like you’re gonna need the starter bundle at $99 per year or the premium bundle to be able to pull back and forth. Overall, this is a great plugin. I think the best use case is if you wanted to update your About page or different pages but you don’t want those changes to go live, this is the plugin to do that. That is going to be the best thing that you can use because then you can just sync those one pages at a time versus trying to figure out, where is that in the database and syncing it back and forth. This is something that you definitely want to check out. It’s got a free trial, so you definitely want to check that out.

I guess WP Migrate DB has the non-pro version. There is a free version in the WordPress repository that you can try. It doesn’t have all the custom syncing back and forth. That’s the pro feature. But with the free version you can download the plugin from the WordPress repository, you can download your database to save it offline. It does the find and replace for you, and then you can import it with the tool. So, there’s no syncing, but you can start using that one for free.

The last tool that I want to talk about and just spend a couple minutes on because it is in beta, it’s like a private beta, it’s called Mergebot. Mergebot is this plugin that makes – they’re saying that it makes WordPress database merging made easy. This is also made by the same folks that make WP Migrate DB Pro, and that’s a company called Delicious Brains. This plugin is a really interesting plugin, and I think this will solve a lot of problems with a development site and a live site getting out of sync, and we want to make sure that we’re making changes on a development site but we want to push only those specific changes out to our live site.

How this one works, and this is just kind of an overarching this is how it works, is you install it, you get it set up, you gotta have it on both websites, and then there’s a little red record button. So when you start working on your development site, before you start working you click the red record button, and then you do your things, whether that’s updating pages or updating posts, or you’re changing settings within a widget, or you’re adding a new plugin and then you add all the setting and what not. And then when you’re done, you click the red button again to stop recording, and then Mergebot knows all of those changes that you just made and can go ahead and push those changes live.

It’s really, really smart, too, and it knows the different between, like, if you’ve updated a certain post on one page and it’s got a different post ID, it duplicates it. And it works really, really slick. I’m still trying to figure out the ins and outs of this, but you can sign up for a beta if you’re interested in this. It is a paid beta. It is a $9 per month beta, so just be aware of that. They want to get people that are really interested in helping the development team out, but they want a little skin in the game, if you will, and you have to pay to try this out.

But if this is a constant problem, if you are a developer and you’re working on a client’s website that’s getting WooCommerce orders or they’re getting a lot of blog comments and you just need to make some small tweaks or some changes, Mergebot can record all these. It kind of pushes it to a cloud, and then the cloud and the two sites sync together. It’s a really cool implementation. I think it’s mainly working for plugin settings and stuff, posts and pages. It’s not quite working all for custom post types and different things. They’re still working on a lot of pieces of the puzzle to get it working. But it’s definitely a really cool plugin. I highly recommend checking it out.

So, those are the three plugins that I wanted to talk about today. WP Migrate DB Pro, my favorite plugin. That’s one of the few premium plugins I still pay for and I still use.

WPSiteSync, that’s another one that I paid for so I could check it out and see. In my use case, for what I’m using, it doesn’t have that “oh I really need this” type of a feel. But I can definitely see some use cases where I will use this.

Then, Mergebot, that’s just another plugin that I look to do a little bit more testing on and send out as a recommendation for people that have WooCommerce sites, because that’s a really tricky thing because we don’t want to overwrite the orders. What you could do with that, is if you wanted to use WP Migrate DB Pro, you can actually sync all but the orders custom post type, and then those things won’t be overwritten when you push that out to your live site. But again, that’s something that you’d have to test and make sure is all working properly.

So, with that, let’s wrap up this episode. Thanks for tuning in this week and this month while we talk about tools. And next month I haven’t quite decided what we’ll talk about, but I’ll try to theme all five episodes of next month and get them out to you in the next month. Until then, we’ll talk again soon. Take care. Bye-bye.

Leave a Reply