I have a non-CMS website which is fully build with PHP with a lot of content in it. I don't want to add my posts manually in Wordpress, because that's a pain in the ass (I am talking about 5000 posts)...

So my question would be: how do I do this? Is it even possible to clone something like this?

  • This is a very broad question. How is your data stored? What have you tried so far? Have you examined how the import mechanism in WordPress works? What specific questions do you have? May 30, 2013 at 16:36
  • This is a question that is answered very well by Jouni Leader. I hate the fact that some people are thriving on criticizing people's questions, even if they are good enough to give an answer. Especially using the downvote button is pathetic. May 30, 2013 at 17:22
  • I'm sorry you feel that way, but if you had posted a specific question you would have received a much more targeted answer. Even something like, my data is stored in a mysql database and the content is in a single table, how do I convert that to a format that WordPress could understand? would have been a lot more helpful. May 30, 2013 at 18:06
  • 1
    I must disagree with Andrew a bit. It doesn't really matter in which format the data is stored as long it's stored in a database. The question was broad yes, but it wasn't impossible to answer to. Down vote was a little harsh thing to do. Comment with request for more specific question would have been much more constructive. May 31, 2013 at 8:35
  • Thanks Jouni, couldn't say that better! Once again, thank you very much, it has worked! Jun 1, 2013 at 12:12

1 Answer 1


If your data is inside database as I understand, it is possible to export your database to CSV file and import this to Wordpress. CSV file is basically a comma separated list of data from your database that makes it possible to transfer data from different database structure to another.

It does indeed take some effort to configure your export/import so that you get your data right, but it's a lot easier thing to achieve than re-posting 5000 posts.

Look for Wordpress plugins "csv importer" and/or "wp ultimate csv importer".

You can export your data using your SQL-client (these often have an option to export in csv) or using PHP (see http://www.coderelic.com/2012/01/export-data-from-a-database-to-csv-excel-with-php/)

If your data is NOT in database, you could consider web scraping techniques (see: wikipedia / Web_scraping) where you go through your site programatically and look for id's, classes and elements to create structured data out of your html files.

Hope this was helpful!

  • Thank you very much, Jouni! I tried using XML before, but did not try CSV. I think I can pull it off with this. It is indeed very dumb to re-post 5000 posts... Thanks again! May 30, 2013 at 17:23
  • You are welcome. I hope you get your transfer done. May 31, 2013 at 8:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.