Hey there, WordPress user!
If you‘re reading this, chances are you‘re in the middle of migrating your WordPress site to a new host or domain. It‘s an exciting process, but it can also be frustrating if you hit a snag.
One of the most common issues I see people struggle with is importing their WordPress content to the new site. You‘ve probably already tried exporting all your posts, pages, images and other data into an XML file. But when you go to upload it on the new site, you get an error message saying the file is too big. Ugh!
Don‘t worry though – there‘s a simple solution. In this guide, I‘ll show you how to split that giant XML file into smaller chunks that can be imported without any fuss. No technical expertise needed!
Why XML Files Cause Import Issues (And How to Fix Them)
When you export your WordPress content, it gets bundled into a special type of XML file called a WXR (WordPress eXtended RSS) file.
This file contains absolutely everything from your WordPress site, including:
- Posts
- Pages
- Media files
- Comments
- Custom fields
- Categories & tags
- Users
- Site settings
All of this data is organized into a standardized XML format that WordPress knows how to read when importing content.
The problem is that WXR files can get quite large, especially if your site has been around for a while and has a lot of content. I‘ve seen WXR files reach over 1GB in size!
Meanwhile, web hosts often set a cap on the maximum file size you can upload through the WordPress importer or your hosting control panel. Here‘s a quick comparison of the default upload limits for some popular hosts:
| Web Host | Max Upload Size |
|---|---|
| Bluehost | 128MB |
| SiteGround | 128MB |
| HostGator | 512MB |
| WP Engine | 40MB |
| Flywheel | 100MB |
As you can see, this limit is usually somewhere between 40-512MB. So if your WXR file is larger than that, you‘re out of luck…
Unless you split it up first!
By using a free online tool to break your big WXR file into a bunch of smaller XML files, you can sneak under that pesky upload limit and import your content without any problems.
How to Split Your WordPress WXR File (Step-by-Step)
Alright, let‘s walk through how to actually do this! The process is surprisingly easy and only takes a few minutes.
What you‘ll need:
- Your exported WXR file
- A web browser
- The free WXR File Splitter tool
Step 1: Export your WordPress content
Start by exporting all your WordPress data:
- Log in to your WordPress dashboard
- Go to Tools > Export
- Select "All Content" and click "Download Export File"
- Save the WXR file to your computer
Step 2: Upload your WXR file to the splitter tool
- Open the WXR File Splitter in your browser: https://wprssplit.appspot.com
- Click "Choose File" and locate the WXR file you just exported
- Once selected, click "Split File"
Step 3: Choose your preferred file size
- Use the slider to set a maximum size for each individual XML file piece
- This should be under your web host‘s upload limit (I recommend 5-10MB to be safe)
Step 4: Download the split files
- When the splitting process finishes, click the "Download Files" button
- This will give you a ZIP archive containing the split XML files
- Unzip the archive and make note of where you saved the XML files
Step 5: Import the XML files one-by-one
- On your new WordPress site, go to Tools > Import
- Click "Install Now" under WordPress (if needed) then "Run Importer"
- Choose one of the split XML files and click "Upload file and import"
- On the next screen, check the "Download and import file attachments" box
- Click "Submit" and wait for the import to finish (this may take a few minutes)
- Repeat steps 4-6 for the remaining XML files in sequential order
That‘s it! Once you‘ve imported all the XML pieces, your content should be completely migrated.
I know it might seem like a lot of steps, but trust me, it‘s a lot easier than trying to mess with your web server settings or opening up phpMyAdmin. I‘ve used this method to split and import WXR files up to 5GB with no issues.
Tips & Tricks for a Smooth WordPress Migration
Here are a few tips I‘ve learned from doing WordPress migrations for my clients:
- Always migrate to a staging site or temporary domain first to test for any issues before pointing your live domain to the new host
- Clear your browser cache between imports to avoid mixing old/new data
- Use the Better Search Replace plugin to update URLs after migrating
- Install and activate your plugins right away to avoid missing functionality
- Check for 404 errors with Screaming Frog and set up 301 redirects from old URLs
WordPress 6.0 Improves WXR Imports
Want some good news? The latest version of WordPress (6.0+) has increased the default WXR import size limit to 128MB. So if you‘re on the newest version, you may no longer need to split most WXR files.
However, many sites still require the old splitting method if they‘re on an older version of WordPress or have an extra large WXR file. So it‘s still good to know how to do it.
Frequently Asked Questions
What if I split my WXR file and import the pieces out of order?
Don‘t panic! The import will still work, but you may have some content that doesn‘t display correctly (like missing images or broken shortcodes). To fix it, try re-importing the affected XML pieces in the right order.
Can I use this method to migrate my WordPress site to a different domain?
Yes! The WXR export/import process works the same whether you‘re migrating to a new host, a new domain, or both. Just make sure to use a migration plugin like Better Search Replace or Velvet Blues to update all the URLs after importing.
Is it better to migrate WordPress via WXR or with a plugin?
It depends on your specific needs, but in general, I recommend migrating with the built-in WXR export/import whenever possible. Plugins can be great for simple migrations, but they often have issues with larger sites or more complex setups. WXR gives you the most flexibility and control.
Will the WXR file splitter work with other CMSs like Drupal or Joomla?
No, the WXR format is a WordPress-specific version of XML. However, you can look for similar "XML splitter" tools designed for your particular CMS.
Wrapping Up
File size limitations may throw a wrench in your WordPress migration plans, but they don‘t have to stop you in your tracks. With the WXR File Splitter method outlined above, you can break up massive XML files and import them piece-by-piece on your new WordPress site.
I know WordPress migrations can seem overwhelming, especially for beginners. But after doing hundreds of site moves over the years, I‘ve found that following a systematic process like this makes it so much easier. Hopefully this guide has given you the confidence to tackle your migration head-on!
If you have any other questions about splitting XML files or WordPress migrations in general, feel free to leave a comment below. I‘m happy to help however I can.
Good luck with your site move!
