How to Split Large XML Files Before Uploading to Your WordPress Website

How to Split Large XML Files Before Uploading to Your WordPress Website

Whenever you try to migrate the content of a website to another, you have your hands on an XML file. I hope you know the import and export process.

If you read in some WordPress forum, the most commonly asked question is about getting an error while importing the XML file.

I have an answer, you should know, the WordPress importer has an XML file upload limitation, it’s only 2MB. Some users might try to use plugins like WP Clone, which also has a file upload limit of 2MB.

Depending on the different circumstances, you require to find a better way to upload a file bigger than 2MB.

If you have a website with 500 blog posts, the XML file you export is more likely to be bigger than 10MB, and as I have mentioned, you can’t import a 10MB file in a 2MB space.

In such a situation, you need to split the XML file into small files and upload them one by one.

This tutorial is going to provide you with the easiest way to split a bigger XML file into smaller ones. You may be wondering about having an operating system, well, this tutorial is for Windows users.

If you have Mac, you can easily find a different tool.

Find a Convenient Tool to Split an XML File

It’s obvious that you require software to accomplish your goal. If you’re thinking about any plugin to split an XML file, don’t waste your time.

Follow these steps.

Step 1

Download WordPress WXR File Splitter from its official website. You may be thinking as if how can this old tool work, well, try it and you will thank me later.

How to Split Large XML Files Before Uploading to Your WordPress Website

You will have a ZIP file on your computer, open it to extract and you will see a WXRsplit.exe file, extract it to your computer.

Step 2

The beauty of this tools is that you don’t need to install it, you can use it directly. Click on the extracted file, and you can see the WXR File Splitter.

Step 3

As you can see, there are two steps, from step 1, you have to use the button to choose the XML file you have imported from your WordPress website.

How to Split Large XML Files Before Uploading to Your WordPress Website

In the second step, you can see the default file size of the file to split into parts, by default, it’s set to 2MB, you can change it less than 2MB.

I would say, 1.99MB is excellent so that you can import the smaller files easily.

Step 4

As you can see, the file size of the main XML file is 22MB, which has been split into 12 parts. As I have said before, you could change the size of the files to divide into many pieces.

How to Split Large XML Files Before Uploading to Your WordPress Website

You could have 22 parts by selecting 1MB for each file, and it’s the matter of choice.

NOTE: You need to make sure, you don’t choose the file size bigger than 2MB.

Step 5

Depending on your file download location, you can see all the smaller files on your computer.

How to Split Large XML Files Before Uploading to Your WordPress Website

As now, the size of each file is 1.99MB, which is smaller than the default file upload limit, you can easily import these to your another website.

Congrats, you have successfully split a bigger XML file into many smaller files.

If you’re using Mac, you can search for “WordPress WXR File Splitter for Mac,” it’s similar to the Windows file splitter.

Have You Ever Checked the XML File Size of Your Website

Most of the WordPress users don’t consider checking their websites, but when they try to clone it, migrate it, they face such a problem.

In the last couple of years, many people have migrated their website from WordPres.com to WordPress.org, or the other way around.

I remember when I was trying to merge the content of two different websites back in 2014, it was a disaster. I didn’t have any idea about splitting an XML file.

Well, at least you do now, give it a try on your local environment.

Conclusion

Once in a while, the issue like getting a warning while uploading an XML file occurs, and most of the people freak out.

Well, it’s pretty normal, you just need to know that WordPress doesn’t allow you upload a bigger XML file at once, so use the above method to split it into smaller files and enjoy.

I hope you can easily accomplish such a task.

Check out these top 3 WordPress hosting services:

A2 Hosting
$1.95 /mo
Starting price
Visit A2 Hosting
Rating based on expert review
  • User Friendly
    4.5
  • Support
    4.0
  • Features
    4.5
  • Reliability
    4.8
  • Pricing
    4.0
IONOS
$1.00 /mo
Starting price
Visit IONOS
Rating based on expert review
  • User Friendly
    4.5
  • Support
    4.0
  • Features
    4.5
  • Reliability
    4.5
  • Pricing
    4.3
Webdock
$0.95 /mo
Starting price
Visit Webdock
Rating based on expert review
  • User Friendly
    3.8
  • Support
    4.5
  • Features
    4.5
  • Reliability
    4.3
  • Pricing
    4.3

How to Configure WordPress Page Caching

A savvy website owner understand how important it is to have a website with a qu
less than a minute
Eliran Ouzan
Eliran Ouzan
Web Designer & Hosting Expert

How to Secure Your WordPress Website

Millions of websites get hacked every year and many people consider WordPres
less than a minute
Eliran Ouzan
Eliran Ouzan
Web Designer & Hosting Expert

How To Create a WordPress Child Theme

Customizing your WordPress theme but want to be extremely safe? Don’t worry. W
less than a minute
Michael Levanduski
Michael Levanduski
Expert Hosting Writer & Tester

How to Fix File and Folder Permissions Errors in WordPress

It's so frustrating when you receive an error while updating your website. File
less than a minute
Max Ostryzhko
Max Ostryzhko
Senior Web Developer, HostAdvice CTO
HostAdvice.com provides professional web hosting reviews fully independent of any other entity. Our reviews are unbiased, honest, and apply the same evaluation standards to all those reviewed. While monetary compensation is received from a few of the companies listed on this site, compensation of services and products have no influence on the direction or conclusions of our reviews. Nor does the compensation influence our rankings for certain host companies. This compensation covers account purchasing costs, testing costs and royalties paid to reviewers.
Click to go to the top of the page
Go To Top