How to Create and Import Custom Post Types in WordPress

Fenzik Joseph
Smack Thoughts
Published in
9 min readApr 25, 2023

In this blog post, we will explore the process of creating and importing custom post types in WordPress. Whether you are a seasoned WordPress developer or just starting, this guide will provide you with a step-by-step tutorial on how to create and import custom post types to your WordPress website. We will cover the basics of custom post types, including what they are, why you might need them, and how to create them using plugins. Also, we will discuss how to import custom post types from other sources, such as a CSV file. By the end of this tutorial, you will have a clear understanding of how to create and import custom post types in WordPress, and you will be able to take your website to the next level by offering unique content types to your users.

How to Create and Import Custom Post Types in WordPress

What is Custom Post Type in WordPress?

Let’s begin with understanding what a custom post is. In WordPress, custom post types are content types that you can create and customize to your specific needs. It can be created using custom code or a third-party add-on. In this article, we will see how to create custom posts using third-party plugins. By default, WordPress comes with five post types: Posts, Pages, Attachments, Revisions, and Menus. Custom post types allow you to add additional content types beyond defaults.

Why do we need Custom Post Types?

If you are planning to build a Real Estate website, the default Post/Page won’t be sufficient because we want a Post Type to have a Product Image, Custom Fields related to the Post we are building here are some sample fields we need — Number of bedrooms, bathrooms, Pools and Minimum Price, and Type of Property either an apartment or Building or Bangalow, etc., so definitely we need a custom post to achieve our needs.

Most Popular Third-party Plugin for Custom Post Types

There are several third-party plugins available to create custom Posts but here I’m listing the most popular ones,

  • Toolset
  • JetEngine
  • PODS
  • Metabox

As a whole, these are the most popular plugins. Each has several features and depending on your specific needs and preferences, you can select any for your website.

In this article let us see how to create Custom Post using the above addon and how to import it using the Ultimate CSV Importer Plugin.

How to create Custom Post Types using Toolset?

Toolset is a powerful plugin that allows you to create Custom Posts, Custom Fields, and Taxonomies without coding knowledge in simple steps. Toolset also includes other features, such as views, forms, and templates. These features enable you to create highly customized WordPress websites and applications.

  • Install and activate the Toolset Types plugin in your WordPress instance.
  • Go to the Toolset -> Post Types in your WordPress dashboard.
Visit Post types in Toolset
  • Click on the Add New button to create a new custom post
Add New Post Types
  • In Post Type Name enter the Custom Post name and in the description field, enter the short description of the post. Under “Options,” select the settings you want for your custom post type. This includes the post-type label, menu icon, and capabilities. And fill in all the necessary fields and click Save Post
  • Once you have created a custom post, your newly created custom post will appear in your WordPress instance.
  • Add new custom fields to your custom post in two ways. By clicking Dashboard under the Toolset menu, you will see a newly created custom post. Then click Add Custom Fields, and Add Custom Taxonomy, to create custom fields and taxonomies for the custom post. You can also click on Custom Fields under the Toolset menu to create custom fields and Taxonomies to create custom Taxonomy.
Add Custom Fields And Taxonomy Toolsets
Custom Posts with fields and taxonomies
  • Now you will be able to see Custom Post with fields and taxonomies in your WordPress instance.

How to create Custom Post Types using PODS?

PODS is a popular plugin that allows you to create custom Posts, Custom Fields, and Custom Taxonomies. Overall, PODS is a powerful plugin that offers a lot of flexibility for customizing WordPress sites.

We will see how to create Custom Post,

  • Install and activate the PODS plugin in your WordPress Instance.
  • In your WordPress dashboard, Click PODS Admin -> Add New -> Create New.
  • Select Custom Post Type in the dropdown menu to create Custom Post, Custom Taxonomy to create a custom category and tag.
Pods add new custom post type
  • Provide the CPT name in the Label field and click Save Pod, then new CPT will be created and it is displayed in your WordPress dashboard.
  • To create Custom Fields, Click on Edit Pods in the WordPress dashboard ->Select your Custom Post (To add custom fields) -> Fields ->Add field group name and fields for the post -> Save Pods.

That’s it! With PODS, you can easily create custom post types and custom fields for your WordPress site without writing any code.

How to create Custom Post Types using MetaBox?

Metabox is a powerful and flexible plugin that lets you easily create Custom Posts, Custom Fields, and Custom Taxonomies for your WordPress posts, pages, and custom post types. Whether you’re a developer building custom themes or plugins, or a content creator looking to add more information to your posts, MetaBox is worth checking out.

  • Install and Activate the MetaBox to create Custom Fields and MB Custom Post Types & Custom Taxonomies in your WordPress instance.
  • Once the plugin is activated you can see the new MetaBox menu in your WordPress dashboard.
  • In your WordPress dashboard, go to MetaBox > Custom Post Types and Click the “Add New” button to create a new custom post type.
Metabox Post types
  • Fill in all required fields such as name, and slug for your Custom Post. You can also select the post type’s capabilities, menu icon, and taxonomies and click Publish and now your Custom Post will be created.
  • Under MetaBox -> Custom Fields, you can add custom fields to your custom post type or existing post. You can choose from various field types such as text, textarea, select, checkbox, and more. Fill in all necessary details like field name and Field location etc and click Publish to see your Custom Fields displayed in the desired location.

That’s it! You have now created a custom post type and custom fields using the MetaBox plugin’s user interface, without writing a single line of code.

How to create Custom Post Types using JetEngine?

JetEngine is a powerful plugin that allows you to create custom post types, custom fields, and custom taxonomies without any coding. For storing additional information to your post you can create custom fields using the plugin. Now, we will walk you through the process of creating custom post types and fields with JetEngine.

  • Install and Activate the JetEngine plugin in your instance.
  • Once it is activated, JetEngine Menu will be displayed in your WordPress dashboard.
  • Click JetEngine ->Post Type -> Add New.
Jet Engine Post Types
  • Add your Post Name, Slug, and fill in all necessary details. Customize your Custom Post by adding Custom Fields and taxonomies by clicking the Add Meta Field button under Meta Fields. Choose the field type you want to add, such as “Text”, “Number”, “Checkbox”, or “Image”. Fill out the field settings, such as the field label, meta key, and default value.
  • And click “Add Post Type” to create Custom Post with Metadata.

Ultimate CSV Importer — To Import Custom Post Types

It’s always nice to be in trend, isn’t it? Not only for lifestyle but also for business. The Ultimate CSV Importer always keeps up with the latest market developments. Interesting right, then try our demo now. So let us see how to import data into a Custom Post using the plugin.

This involves a few steps,

  • Import File Preparation,
  • Upload File
  • Field Mapping
  • Media Handling Section
  • Import Configuration Section

File Preparation

Ultimate CSV Importer will import both CSV and XML file formats. Ensure your CSV file is formatted correctly, with each column representing a different field in your custom post type. Also, we have provided a Sample CSV/XML for your reference. If you are unclear, you can look for clarification.

Upload File

Install and Activate WP Ultimate CSV Importer in your WordPress instance. Click the Ultimate CSV Importer plugin and navigate to the Import tab and upload your CSV/XML and select the post type you want to import in the dropdown menu. Select New Items to import New data or Existing Items to update the old data.

Import File Upload Page CSV Importer

Field Mapping

Field mapping in the Ultimate CSV Importer plugin allows you to map the columns in your CSV file to specific fields in your WordPress database, such as post title, post content, post meta fields, custom fields, and taxonomy terms. Field mapping is essential because it tells the plugin where to place the data from each column in your CSV file. Once it is done you can save the mapping as a template so you can use the same mapping in future use.

Media Handling Section

Download external images to your media — You can decide whether the image (Inline Image/Featured Image/Gallery Image) imported with your Post should be in the Media Library or not in this section.

Image Handling — Ultimate CSV Importer will handle your images perfectly by not allowing duplicate images inside the Media library. If the images are already present inside the Media and you want to keep them, you can do it or delete the old ones by overwriting the existing images or always creating fresh ones during the import process. Select anyone based on your needs.

Post Content Image Option — Enable to download the Post content image to the Media Library

Image Sizes — The image can be imported in different sizes such as thumbnails, medium, medium large, and large. If you need any custom size you can do it by specifying the image width and height.

Media SEO & Advanced Options — You can import images along with the SEO fields like Image Name, Description, ALT text, and Caption. Map the desired CSV header to the fields. And click Continue to proceed with the import process.

Import Configuration Section

In this section, you can take a safe back backup before importing. Also, you can notify your visitors that the site is under Maintenance mode. Then Kickoff the duplicates while importing the data based on Title/name. Schedule your import at your own time in this section. Once it is done click Import to import all your data into the WordPress instance.

How to Export Custom Post Types using Ultimate CSV Importer?

Click on Ultimate CSV Importer and navigate to the Export Tab and Click Custom Posts. Now the created custom post will be listed in the dropdown, select the desired post and Click Continue.

Give the name of the file to be exported and download the file in the format you need like CSV/XLS/XML/JSON. And the advanced filters allow exporting the data you need. (Refer to Ultimate Exporter documentation for more details)

Update your data using Ultimate CSV Importer

Both import and update are the same processes and it only differs in two steps. In the first step select Existing Items and upload your CSV and map all the necessary fields and click continue.

Update Data using CSV Importer

And in the Final Step select Update based on Field to update the record based on the title/slug/ID.

--

--