In this tutorial you will learn how to quickly transfer an exact copy of your existing WordPress website to your WordPress website running on Google Cloud. This is quick-start tutorial is designed for websites running on Google Cloud’s Compute Engine.
Using the All-in-One WP Migration plugin is a great time saver when transfering your WordPress website between hosting providers.
To get started, follow along with the video above. If you get stuck, check below to see the steps listed individually with images.
Before starting this tutorial, you should have already created a Google Cloud Platform account and launched a WordPress website on Google Cloud Platform.
There are 4 steps in this tutorial:
1. Download WP Migration Plugin
2. Export Website File
3. Import Website File
NOTE: By default, the All-in-One WP Migration plugin only allows a maximum file upload size of 512MB. If you need to increase the maximum file upload size to 10GB+, check out this tutorial.
4. Change Permalink Structure
That’s it!
Your WordPress website is now set up on Google Cloud platform!
Please leave your comments and questions below!
Andromeda says
Can’t download the backup archive from my web Google Cloud ( i want to duplicate my old web into new one ). Always failed to download.
Try with All In One WP Migration and Duplicator.
Can’t use All in One WP Migration and Duplicator if we host our web in Google Cloud ??? Thanks for the answer.
Leron Amin says
Hi Andromeda,
How big is the export file? Files over 1GB can sometimes cause problems.
Try downloading the unlimited plugin from here then try exporting using the unlimited plugin. If you have lots of media files in your WordPress install, you may have to migrate your media folder manually.
Let me know if you have other questions,
Joe
Vikash Goyal says
I was able to move my site from shared hosting to GCP using the All in One WP Migration tool. Now the issue when I am trying to export latest backup of the site from GCP, the download does not work. Though the backup is created in wp-content folder and I can download the same via SFTP but unable to download it via wp-admin. Any help.
Leron Amin says
Hi Vikash,
You will need to connect to your instance (either via SSH or FTP) and move the file into the All-in-One WP Migration Backups directory.
Once it’s added, you’ll have the option to restore your site from a backup. Check out the instructions here for additional information.
Let me know if you have questions,
Joe
Ben says
Hello!
Many thanks for your previous assistance, I trust you can find time to assist us again, perhaps with a video tutorial.
The PHP version of my website running on GCP (Click-to-deploy) is out-of-date and WordPress is prompting me to update to a newer version of PHP.
I do not know how to go about this.
Please can you kindly assist us again with your wealth of knowledge?
If we can get a video tutorial, we will be more grateful.
Many thanks and warm regards.
Leron Amin says
Hi Ben,
I’d recommend migrating WordPress to an updated stack. You can use the unlimited version of the All-in-One WP Migration plugin, which is available here.
Let me know if you have questions,
Joe
Andrew says
I am a novice. I transferred my website using All-in-One WP Migration from one Google Cloud account to another Google Cloud account. Reason is to update the Click-to-deploy softwares. I tried to reset the permalinks. The permalinks were originally set using “Post name” https://home-tuition.sg/sample-post/.
After the migration, the permalinks only work when I choose “Plain” https://home-tuition.sg/?p=123.
The permalinks do not work when I select back “Post name” https://home-tuition.sg/sample-post/ or any of the other permalink structures. The webpage will display a blank white page with the words
“Not Found
The requested URL was not found on this server.”
I tried to press “Update” after editing the permalink in a Page in WordPress’ admin area, thinking that I can update the permalink. I got an error message “Updating failed. The response is not a valid JSON response.”
How do I fix this?
I read in the comments a suggestion to use FileZilla to delete “.htaccess”. Then let WordPress re-create a new .htaccess file. This suggestion had no effect.
I do not quite understand what is happening, and how to fix this?
Please give me some guidance.
Thank you.
Leron Amin says
Hi Andrew,
Occasionally after import, you’ll have to switch the permalink settings to “Post name”, save the settings, then repeat. Once you’ve done this, try reloading the pages with broken links.
Typically in these situations there’s no need to delete your htaccess file; in fact, this could have contributed to the problem.
Let me know if you have questions and/or if you were able to get it working.
Thanks,
Joe
soso says
Hi !
I’ve exported my website in GCloud, but … When I want access to my home page (http://34.65.246.33, no dns, I prefer test if all work fine), I’ve an error of google chrome (This site is inaccessible).
I’ve modify my wp-config.php and add the new db, user db an password but nothing …
I’ve use WordPress Clic and Deploy and now test with wordops.net, I’m confused … 😔
Have you a solution ?
Leron Amin says
Hi Soso,
Did you check your server logs? Also try running the following commands:
These commands will display issues which may be preventing your system from functioning properly.
Let me know if you have questions,
Joe
alphatech says
i have a backup of my existing website on my local pc….pls how can i upload it to gcloud..since no access to cpanel
Leron Amin says
Hi Alphatech,
You can use the gcloud command line tool to upload your backup to a cloud storage bucket. From there, you can upload it to your virtual machine instance.
Let me know if you have questions,
Joe
David says
Thank you for the great tutorial!! I followed the steps and copied my site from the old hosting to GCP, and pointed the server name in the domain setting…but at this time, i cannot see my site, do I need to work on wp-config.php file as well? can you please explain how to work on that if possible? thank you so much!
Leron Amin says
Hi David,
You need to define WP_HOME and WP_SITEURL in your wp-config.php file. Check out this resource for additional information.
Please let me know if you have any questions,
Joe
David says
Hi, I have exported the file but when I am importing the file It says the file is corrupt. I am sick of it. Plz Help….
Leron Amin says
Hi David,
Try importing the file using FTP. Importing large websites using the web interface has a high likelihood of failure.
Hope this is helpful, and let me know if you have questions!
Joe
Alex says
Hi, I have been stuck on restoring database 0% for a long time.
The upload file is is quite large (5GB with media), shall I abort the migration and start it all over?
Is it better the migrate everything other than media first, then use other plugin like UpdraftPlus to restore the media?
Leron Amin says
Hi Alex,
I wouldn’t recommend storing your static assets such as images and videos on your virtual machine instance, it’s best to serve those from a cloud storage solution such as Google Cloud Storage or Amazon S3. There’s also a WordPress plugin for the Google Cloud storage integration, which makes the process much simpler.
Anyways – were you able to get migration/database restore working properly?
Talk to you soon,
Joe
Alex says
Yes, the migration is done.
Will check on Google Cloud Storage later, thank you so much for your advice.
Leron Amin says
Sounds good Alex – glad I could help!
Ali Dindar says
I don’t know why but i think just i lived this problem 🙂
Unable to import
Unable to open file for reading. File: /opt/bitnami/wordpress/wp-content/plugins/all-in-one-wp-migration/storage/uxplxrowqq73/www.sitename.com-20190718-202711-127.wpress
How can i fix that problem.. I changed of the CHMOD Settings as 777 but still problem with me :/
Waldemar Figueiredo says
I followed the steps. I exported and imported the file. Everything happened correctly, with one small exception: the plugins and theme did not come.
Leron Amin says
Hi Waldemar,
Were you able to resolve the issue?
Let me know and I will see how I can help.
Joe
Mike M. says
Hi,
Thank you for this very informative article.
I copied my website using winhttrack , is ftp or sftp the only way to upload the site to google cloud
or is there a plugin that makes it easier to deploy?
Thanks
Mike
Leron Amin says
Hey Mike,
You can use the Gcloud command-line tool to quickly transfer files from your local machine to the cloud. All of this is done through the terminal, and there is no GUI like there is with a typical FTP client such as FileZilla. That being said, it’s also much faster.
I will likely do a tutorial on this process eventually.
Hope this helps and let me know if you have questions,
Joe
Mike says
Thank you Joe, appreciated.
Mike
N says
So I export the file from the OLD website……then go to ‘Login to admin panel’ from GCP but of course it takes me to the same WP site (the old one) as everything is pointing in that direction now. No idea how to get to new WP site to import the file……..
Leron Amin says
Hi N,
These changes take a while to take effect (learn more about DNS propagation). Additionally, try viewing your website through a free proxy service in order to bypass your browser’s cache.
Let me know if you have questions,
Joe
N says
Thank you for the response.
We got around this OK. However, we had the problem that we no longer could receive email after changing the nameservers.
We only wanted to move our website host and keep the email hosting separate….
Are we doing something wrong such that our mail host is being affected by changing our website host?
Leron Amin says
Hi N,
I understand your situation, and I’m not sure the best way to go about hosting your email and website on separate servers. This is something you should contact your existing web host about. Check out this Stackoverflow thread for more information.
I hope you’re able to get it worked out, and let me know if I can be of assistance!
Joe
N says
Thank you.
Its strange, as when we moved the website to GCP we didnt touch the MX records and only the DNS as instructed…..and yet it interfered with the ability to receive email.
TJ Crawford says
Hi. Thanks for this. Running into an issue. After I migrate all internal pages result in an error. Home page is fine. Internal pages don’t work. Any ideas?
Leron Amin says
I’m not sure what the issue is – can you describe it in more detail? Are your permalinks returning 404 errors?
TJ Crawford says
Yes. But the 404 page is not my site’s 404 page. It the basic Google Cloud error page when nothing resides there.
I’m going to try it again today. I’ll let you know the IP so you can see what I’m talking about.
Leron Amin says
It sounds like a different issue – definitely not what I was thinking of. Let me know how it goes!
Subash Krishnan says
Hi Luis,
After importing the website I an unable to login to WP, showing errors as password doesnt match, and when I try resetting the password, shows email is not registered.
Dave Young says
Upon importing into GCP instance I receive an error which says that my site exceeds the maximum allowable file size (100mb); which is odd because this is a very simple and sparse website with just a few blog posts. So how can I either reduce the size of the file, or overcome this error in some other way?
Leron Amin says
Hi Dave,
How are you importing it? Via the All-in-one WP Migration plugin?
Please provide more details and I will see how I can help!
Thanks,
Joe
Mitch Service says
Right now my new Worpress Instance resides at an IP# address on GCP until i make sure it all works fine, then I will point the DNS to the new IP. But, none of the links are working, even after saving the permalinks part. I have even installed a permalinks finder app that doesn’t seem to be working. Please advise if there is a way for me to fix this. or if pointing the correct domain will fix the issue. Old website was http://kendrew.ca, the new website is http://104.155.185.136/ for now.
Leron Amin says
Were you able to get the issue resolved?
John says
Follow this guide is the problem I guess? The blogger here also has no solution to this?
Leron Amin says
If your IP is showing instead of the domain name, it’s because either your site URL’s are not configured properly in your wp-config.php file or your DNS settings are not configured properly.
Regarding links not working, I go over the solution here.
John says
Perfect that link worked! Ignore the previous comment
Leron Amin says
Glad to hear it worked – thanks for letting me know!
John says
Link 404 is fixed, but when clicked on the home item in the menu. It reloads with the ip address.
I connected via FileZilla following your other guide. Connected by can’t find the wp-config file under wp-content folder.
Leron Amin says
Hi John,
Make sure your URLs are pointing to your website’s URL, and not your VM’s public IP address.
Also, the wp-config file is located in the following location:
Let me know if you have any questions,
Joe
Subrata Ghatak says
Great Tutorial and Post ever I have seen. Many many thanks for sharing such great Tutorial keep it up, god bless you.
Leron Amin says
Thank you Subrata! Glad to hear the tutorial was helpful to you! 🙂
Asif Hussain says
How can I migrate my WordPress multisite almost 13GB data easily. I am too much confuse about proper migration. If you have any way please share with me complete start to end details.
Like WordPress install and copy
Configuration with old file and also PHP MySQL
Domain Pointing to GCP
SSL
Clouflare
I have also seen that wordpress multisite URL configration in wp-config.php is something different from single site on Bitnami
Leron Amin says
Hi Asif,
First check out this guide and follow steps 1-4.
To migrate a website of that size (13GB), you will need to unlock the unlimited plugin, as instructed in this comment here.
Next, configure Cloudflare CDN and SSL. In step 3 of the tutorial, use the “Full SSL” setting, not the “Full SSL (Strict)” setting. This will allow you to use Cloudflare’s SSL on your website.
Let me know if you have any questions,
Joe
Asif Hussain says
What about bitnami Multisite url configuration in wp-config. It looking something different from your instruction. You can also check my website: https://timespakistan.com
Leron Amin says
Hi Asif,
WordPress Multisite is an entirely different application. Unfortunately I don’t have any Multisite tutorials available at this time.
That being said, I would recommend checking out the Bitnami WordPress Multisite docs here.
Hope this answers your question,
Joe
Bobby says
Followed all the steps, however, after importing, it only imports home page and cannot access wp-admin any longer.
Bobby says
I followed the steps and I can get to the site, but the WP-Admin does not show up anymore…
Leron Amin says
Hi Bobby,
Please provide additional details regarding any error messages/notifications that you are seeing that pertain to the error. This will help me to guide you to a solution.
Thanks and talk to you soon,
Joe
Bobby says
The export seems to work, the import seems to work on GCP, but when I go to access the newly imported WP-Admin, says page not found. It seems to have only copied the home page and nothing else.
Bobby says
I should clarify it’s website hosted at Blue Host and I am trying to transfer to GCP. Google gave an IP address so I can point the domain (hosted at Google) to the new IP address.
Leron Amin says
Hi Bobby,
I’m not sure what the issue is – worse case, you will have to migrate the website manually.
If your website has lots of plugins and/or uses a ‘drag-and-drop’ builder, this could be a contributing factor.
I would deactivate as many plugins as possible and try again. Also, make sure your domain name is configure properly with Google Cloud, as it appears to me that it could also be a networking issue caused by an incorrect DNS configuration.
Hope this helps and talk to you soon,
Joe
Bobby says
There are really no plug-ins. I am trying to now manually move over…under GCP where can I manually move over the website files? FTP?
Leron Amin says
Hi Bobby,
Do it with SFTP through FileZilla. Also, search Google for a tutorial on manual WordPress migration – there are a lot of them out there.
Hope this helps,
Joe
H says
How change the configuration of the instance after I deploy WordPress?
(Increase disk size, RAM etc)
Leron Amin says
Hello H,
You have to first stop your VM instance, then click on the VM instance and click the “edit” button at the top of the page.
Remember to reserve a static IP address for your VM instance before stopping it, or your website’s IP will change after the restart.
I hope this information helps,
Joe
H says
Is this tutorial on transferring a WordPress site?(You make it sound to easy to be true) Could you please go in more detail on ‘Permalink’ section? Specifically will I be able to keep the same url after this process is done? ?
Leron Amin says
Hi H,
It’s a tutorial on how to quickly transfer a WordPress site to a new WordPress installation on Google Cloud.
I don’t know the reasoning behind having to reset permalinks, but it’s a recommended preventive step in order to avoid issues with incorrect permalinks down the road. And yes – this tutorial is meant for users who are using the same URL, as the process is slightly different if the URL is different at the old/new location.
Hope this helps and let me know if you have questions,
Joe
ritika Dhir says
hey
This was a great video. just a silly question, why is URL not same as that of my existing word press site?
Leron Amin says
Hi Ritika,
I don’t quite understand your question – did you URL change after you uploaded the site?
Talk to you soon,
Joe
Gouse says
Sir How to reduce server response time and improve WordPress website speed, still am using shared hosting in Namecheap and I have migrated in google cloud platform even though not improvement please help me. m
Leron Amin says
Hi Gouse,
I ran your page in GT Metrix and didnt’t see any major issues. The first thing I would do is configure a CDN; CloudFlare has a free one that you can use in conjunction with W3 total cache, which, when used effectively , can greatly reduce your website’s load times.
If you’re an experienced developer and have funds to pay for premium services, I would skip CloudFlare and use Google’s own CDN and cross-region load balancing service. This is where Google Cloud Platform really shines, and you will find the biggest performance boost to your website – much greater than Cloudflare’s free service. Check out this video for an introduction to GCP’s CDN and load balancing services.
Hope this helps 🙂
Joe
Jan says
Dear onepagezen,
Is there a way/tutorial for ftp/database transfer?
We have install simple wordpress on Google instance.
We can’t access to the orig page we are tranfering to Google cloud… We only have it all files and database.
We successfully uploaded/rewrote the files to the GC… and install the database but the website doesn’t work.
Everything should be fine.. so, the question is… Is there any special GC setup/file of wordpress that we need to include/add to it to make it work?
Maybe commands to fix the permissions?
Thank you very much
Jan says
Ps: In another words… We can’t run ‘All-in-One WP Migration plugin’ – but we have all files and database 🙂
Leron Amin says
Hi Jan,
Why can’t you run the All-in-One WP Migration plugin?
You can manually migrate your database, but there’s a lot of effort and troubleshooting involved.
Like you said, the main issues you will encounter will be permissions related, but there might also be issues with directory structure and file/plugin dependencies.
Let me know more about your situation and why you can’t use the All-in-One WP Migration plugin and I will try and help you troubleshoot.
Talk to you soon,
Joe
Jan says
Thank you for your reply.
The reason we can’t use the All-in-One WP Migration plugin is that we pointed the website to the new server and the old server (plesk) preview of the website doesn’t work – so, we can’t create the All-in-One WP file :((
Jan says
Just an update if someone else has the same problem with Preview in Plesk…
Plesk can be confused, so, I changes the following in wp-config.php and now I can see the preview.
define(‘WP_SITEURL’, ‘http://’ . $_SERVER[‘SERVER_NAME’]);
define(‘WP_HOME’, ‘http://’ . $_SERVER[‘SERVER_NAME’]);
define(‘WP_CONTENT_URL’, ‘/wp-content’);
(I’ll update on the rest too)
Thank you 🙂
Leron Amin says
Sounds good Jan,
I’m glad you’re making progress – I wish I could be of more help but unfortunately it’s not a simple process.
Some resources that I’ve used that you might find helpful include WordPress Codex and this BlueHost article.
It seems like you have experience with this stuff, so I will leave you to it.
Let me know if you have any questions or run into any conflicts and I will try my best to help!
Cynthia says
After importing, I was sent back to the WordPress login page, where neither the admin username/password nor my email address are recognized. Help!
Leron Amin says
Cynthia,
You have to use the WordPress username and password of the site that you imported.
So if you imported website A to website B, you would use website A credentials to login to website B.
Let me know if you have any additional questions,
Joe
Baldwin Jackson says
Excellent resource for newbie developer but I was curious about what if the website size is more than 2 GB? I have hosted my site on shared hosing account and now I am planning to move it on managed cloud hosting platform like Cloudways or may be Siteground. Infact Cloudways have their WordPrss Migration plugin as well. Which plugin do you suggest should I use? Duplicator, All in One WP Migration or Cloudways Migrator.
Leron Amin says
Hi Baldwin Jackson,
Thanks for the feedback!
All-in-One is the easiest and quickest to use – in my opinion. Check out this tutorial on how to increase the upload limit to over 2GB.
Let me know if you have any questions!
Joe
Mudasir says
Hi Luis,
After importing the website I an unable to login to WP, showing errors as password doesnt match, and when I try resetting the password, shows email is not registered.
Cynthia says
I have the same issue. Did you solve it?
Subash Krishnan says
Since we are restoring the contents (data base level) from site A to B, you will have to use password of site A.
Luis says
Leron, you’re right as usual! 🙂
On my bitnami multisite install I’m not allowed to use this plugin.
Actually, the already comes with the install when we setup multisite over bitnami. But they prompt us to buy the package. Fu…
Leron Amin says
Hey Luis,
Do you get an error message when you try to use the plugin?
I am curious to know – this will affect a lot of users if the plugin isn’t working.
Talk to you soon,
Joe
Luis says
I’m not getting any error message.
Simply, I’m not able to import anything.
The plugin is there activated on my network but I can’t manage it.
No links, no field created under site panel nothing nothing nothing.
This is the message on top off plugins page:
“WordPress Multisite is supported via our All in One WP Migration Multisite Extension. You can get a copy of it here GET MULTISITE”
Leron Amin says
Hey Luis,
I didn’t realize that the plugin doesn’t work for multi-site installations.
Thank you for bringing this to my attention – I will be sure to make a note of this in order to inform other multisite users.
Luis says
This plugin isn’t available on Bitnami version
Leron Amin says
Hi Luis,
Bitnami and Click-to-Deploy are simply the ‘packages’ of software that are supporting your WordPress installation.
The plugin in this tutorial is available for any website running WordPress. If you can’t get the plugin through your WordPress plugin page, you can download it from the WordPress website then upload it manually to your WordPress plugin dashboard.
Let me know if you have any other questions!
Thanks,
Joe