Convert/Change Post Type to Custom Post Type [WP]

Updated on September 24, 2017

By default, WordPress supports post types such as Posts, Pages, Attachments, Revisions and Menus. It also allows to create a custom post type. For example, an e-commerce website need a custom post type to create products, a movie website needs a custom post type to create a movie, a forum website might need a custom post type for forums, topics and replies. This website lists 12 awesome examples of custom post types in WordPress. Ok, custom post types are great, but what if you want to convert a post type to a custom post type? Well, once I was put in a situation to convert/change post type to custom post type say “Article” and here’s how I handled the situation.

Convert/Change Post Type to Custom Post Type

All you need to do is install a Post Type Switcher plugin and you are done! Seriously? Yes, there’s no need of complex coding or a rocket science, just this plugin will do what you need.

Step 1: Install Post Type Switcher plugin and activate it.

Step 2: The plugin will add a “Post Type” drop down in the post editor. It allows you to convert/switch a Page to Post, Post to Page, Post to Custom and Custom to Custom types.

Step 3: To change the post to a page or custom post, click on “Post Type” drop down and choose the type you wish to switch/change.

Convert/Change Post Type

Step 4: You can also click on “Quick Edit” link under each post in “All Posts” page and switch that particular post to a custom post type.

Convert/Change Post Type

Change all Posts to Custom Post Type

Step 5: Bulk Edit: As I told in the first paragraph, my requirement was to convert all WordPress Posts to Custom type. So Step 3 & 4 are not the ideal way of doing it. Interestingly, this plugin allows you to Bulk edit posts and its type. To do that, click Posts > All Posts. You know that this page will list all posts and the number of items displayed per page depends on the setting in “Screen Options”. You need to click on “Screen Options” located at the top right corner and adjust the value “Number of items per page:” and click “Apply” button. For example, setting “Number of items per page” to 100 will list hundred posts. Now you can select all the posts and select “Edit” under “Bulk Actions” pull down and click “Apply” button. In the Edit window, change the post type.

Note:

Setting higher number for “Number of items per page” will increase the load time of “All Posts” page. Also, bulk edit is a time consuming operation.

Similarly, you can also change/switch Taxonomies such as category & tag to custom category or a custom tag. But you cannot do that using “Post Type Switcher” plugin, so I will be writing a separate article on that.

Love it? Let me know your feedback.

Information:

At the time of writing this article, the plugin version was 3.0.0 and the same was tested on WordPress version 4.8.2. You might have to ensure compatibility for other WP versions before installing this plugin.

Was this article helpful?

Related Articles

Leave a Comment