Invalid WXR version error

Sometimes when you are trying to import content using the WordPress importer (i.e. – demo content import), you may face an error like this:

 

This does not appear to be a WXR file, missing/invalid WXR version number.

There are several possible reasons for this error, but in most cases it’s missing php function on your server configuration.

Whenever you get this error, first thing to do would be contacting your hosting support and ask if the SimpleXML PHP module is active for your server.

Tip: Most probably the SimpleXML PHP module is not active

Other Possible Reasons and Solutions

There are other possible reasons for that error, but these are really rare cases.

The first would require to manualy check your XML file and, near the top part, add the line “<wp:wxr_version>1.1</wp:wxr_version>” (without quotes) right after the language declaration part. You can find more information in the WordPress Support Forums.

Another rare possibility is that PHP safe_mode might be turned on for your hosting server. The safe_mode options being “ON” does not necessarily mean that it is the cause of the issue, but it’s worth checking this too. Like in the first (and most probable) case, you will need to contact your hosting support and ask if safe_mode is turned on.

If you know for other possible reasons and solutions, we’d be happy to discuss in comments.

About the Author:

Dimitar Koev is a graphic and web designer, front-end developer and marketing expert. CEO & founder of the Althemist team (previously known as Koev) - an independent envato market author, focused on building WordPress themes with strong e-commerce accent.

4 thoughts on ““This does not appear to be a WXR file, missing/invalid WXR version number” error

  • Ajith kumarJuly 27, 2019 at 10:04 am

    Thank you bro, all the best for your more helps

    Reply
  • MatiasJuly 3, 2019 at 11:36 am

    Thanks guys. I have been searching the web for days and this finally solved my issue, even though I am not using one of your themes.

    BR
    Matias

    Reply
  • JanFebruary 15, 2018 at 4:55 am

    OK, I run my own apache server, can not get help from a host.
    I surfed the internet and found many different solutions on how to alter my php.ini file. None of them works.
    Since I have very little time to set up and go live with this theme I must ask if there is another way to activate your demo in to my script.
    I Really do not have time to experiment with this issue. Would be a shame if I have to buy another theme for such a small issue, but I REALLY need to get started. It is that important for me.

    /Jan

    Reply
    • AlthemistFebruary 15, 2018 at 10:51 am

      In this case you should just enable the SimpleXML PHP module on your server. No need to experiment. However, there is no other way to import the demo. Your server must meet the official WordPress requirements and SimpleXML is one of them.

      Reply

Leave a Reply

Your email address will not be published. Required fields are marked *