Support » Plugin: WordPress Importer » "Failed to import" and "Invalid post type" errors

  • I have tried importing an entire site, and I have tried importing the pages, posts, and comments separately. Either way, I get nothing but Failed to import and Invalid post type error messages.

    I see from the support forum that a lot of people have been having problems with this plugin for many months. Importing content is crucial functionality. When is this going to be fixed?

    Thank you,

    Fred Chapman

Viewing 10 replies - 1 through 10 (of 10 total)
  • P.S. I found another way to migrate a site to a self-hosted site, and it worked perfectly the first time:



    This is a function I use many, many times over. I’m not sure why it doesn’t work any longer, but I’d really like it to get fixed! It’s possible that the error occurs on the export, since when I try to import files, the space that gives the (author) name ends up blank like (). VERY frustrating!

    Fred, can you export .org files to a .com site and then use the plugin you mentioned to move the content from .com to .org?

    Lisa, for some reason I never got an email notification. I’m just seeing your question now.

    I haven’t tried migrating from a .org site to another .org site via a .com site. To go from .org to .org, you’re probably much better off doing something with the WordPress database directly. For example, you can export the database to an SQL file using phpMyAdmin in your hosting account and then import the SQL file using phpMyAdmin on the new site. You may need to edit domain names and path names, though, which can can be difficult to do correctly if the database contains “serialized data.”

    There are plugins which automate the process of moving an entire WordPress site from one .org installation to another .org installation. The Duplicator plugin is especially good, because it also moves all the WordPress files and directories (the WordPress core, themes, plugins, and media library) as well as the database. It comes bundled with an installer that allows you to specify the domain and path names on the new site. If all else fails, there’s a special PHP script that can do a search and replace safely, even on serialized data. Plus, there’s always this general advice from the WordPress Codex.

    I hope this helps,


    After days of searching, I finally found a work-around.

    I’m using a Mac with 10.7.5, not sure if this has anything to do with it, but figured it might help. I ended up downloading a program called “TarPit” which does gzip on a mac.

    The work around is here – … workaround

    *** from that article
    If your .xml data import is failing try the following
    (this method resolved this issue for me):

    1) Download and Install 7zip.
    2) Right click on your .XML file -> 7zip -> Add to Archive
    3) Change the “Archive format” to gzip and hit “OK”. You’ll now see your file with a .gz extension on it.
    4) Try to import/upload the file again (selecting the .gz you just created not the .xml file) and it should work.

    The first 2 times I tried this method I actually hit another error. Step 2 of the import ended up going to a “404 not found” page on the front end. To get around this I had to bump up the following settings in my php.ini:

    default_socket_timeout = 600
    pfpro.defaulttimeout = 600
    *** end **

    burleyc1, your workaround sounds really useful! It shouldn’t matter whether you create the .gz archive on a Mac or a PC since the issue is actually with WordPress on the web server. I’ll try your workaround if I ever encounter this problem again.

    Thanks very much,


    Thank you burleyc1, your solution worked well.
    Also a tip for any Mac users try GUI tar to perform the gz compression:


    I tried your method and I am getting loads of Failed to import Media messages. I need a quick fix because I have now taken down a companies existing site and it’s not working.

    I am using a mac also I downloaded TarPit. I dragged the xml into TarPit and it made the .tgz extension. I tried importing and again lots of Failed Import Messages

    I also tried the Gui-tar as recommended by @yotikewebdesign. Again it is not working

    I really appreciate your help

    Hi All,

    I am sure you all know about this already, but I thought I will mention it here for people in my situation. I had the same problem and I searched the internet for the solutions and even changed my php.ini settings, did .gz import to no avail and then I stumbled upon the following link and guess what? I was importing the .XML without actually activating the theme for which the post types and data was related to, as soon as I activated the theme all the errors went away.

    Apparently WP can’t import posts of a non-existing type.

    Hope it helps someone 🙂

    Thanks for sharing @samraza

    THANK you so much, gzipping the xml file worked for same issue for me. And Yotike on the “GUI tar” haha

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘"Failed to import" and "Invalid post type" errors’ is closed to new replies.