stand for ukrainian independence image
Stand for Ukrainian Independence. Contribute.
stand for ukrainian independence image

Help Center

WordPress Custom Post Types Explained
ivanova
Helena Ivanova
Technical content writer
Show all articles
Updated on
Useful Resources

WordPress Custom Post Types Explained

Modern WordPress is all about customization because everything can be adjusted to serve the project’s needs. Some say that the idea of customizing as much as possible was the first step towards turning WordPress into a CMS. Plugins, data structuring, and post grouping were the next logical steps.

The term Custom Post Type (or CPT) goes hand-in-hand with the words “taxonomy” and “meta fields.”  These words may sound a bit scary for beginners, but it’s actually not because it’s simply about the content structure. 

In this article, I will give you all the explanations and examples to help you understand this concept.

Table of Contents

The Concept of WordPress Post Types

Let’s start by asking what WordPress post types are.

Post types (default and custom) are content types used to structure content on your website. Just like in the kitchen, you have cups in the kitchen cupboard, milk – in the fridge, and shoes somewhere in the wardrobe, and thanks to this order, you can always find what you need. Imagine if there were only one big shelf in your apartment, with cutlery, shoes, groceries, clothes, detergents, and wrenches all in one place. What a mess, right? And every time, you would have to spend a good half an hour to find something in this huge pile. That’s why we have closets, cabinets, and drawers and distribute them in different rooms: kitchen, laundry, and wardrobe. 

WordPress, as a CMS, also needs this kind of order for the content. That’s why post types exist. 

Default Post Types

Before talking about custom post types, let’s first define default WordPress post types. Using the previous apartment analogy, imagine that you buy a semi-furnished apartment, where you already have some basic furniture for daily life, so you will have a place to sleep, eat, and store your things right after moving in. WordPress has a similar thing,  the default post types, so you can use them right after WordPress installation and add some content. 

But if you want to add something specific that will fit your lifestyle, routine, and tastes, you buy your own custom furniture. The same story applies to WordPress custom post types: if the default post type functionality is not enough for your goals, you can add custom post types to match your content and site structure. 

So, let’s get back to default WordPress post types. There are seven:

  • Posts – they can be organized in categories and by tags, displayed in reverse sequence (the newest first);
  • Pages – not organized in categories and by tags and can be hierarchical (have child pages);
  • Attachments – used to store media and their meta information;
  • Revisions – to store a history of edits for other post types, so you can rollback changes;
  • Navigation Menus – all kinds of navigation menus to be displayed on the site;
  • Custom CSS custom CSS code edited via Customizer;
  • Changesets – history of edits for Customizer.

NOTE

Don’t mix up the concept of a WordPress post as a single item of content and post as one of the seven post types. Unfortunately, they have the same name, and it can cause confusion.

What Are Custom Post Types?

Most tutorials on this topic use the same example: you have a bookselling site, so you will create a custom post type (CPT) named “Books” to publish these books as posts. Such a WordPress custom post type will have a layout, options, and meta fields. It’s a pretty vague explanation, isn’t it?

First, let’s look at the advantages you get when creating a custom content type:

  • A separate menu item in the dashboard is needed to have a clearer menu structure. In the example below, Tickets, Properties, Cars, and Team Members are custom post types:
cpt dashboard menu
  • Custom meta fields can be created and assigned to the particular CPT to fill in and store specific data separately (to fetch in on the front end later in the correct order). This is an example of how the Property CPT may look for the vacation directory site:
custom meta fields
  • Custom templates for that particular CPT are needed to display the post content and all the meta fields properly, including the title, the content, and the featured image (like in most standard templates). 
  • Custom taxonomies (categories and tags for a specific post type) can be created to organize those CPTs and create custom archives for them.

The most frequently used custom post type is the WooCommerce Product post type. It has a lot of custom meta fields, such as Price, Short/Long Description, etc., and a template. All of the above are added to the site when the WooCommerce plugin is installed. But you can create as many custom post types as you need. 

So far, I see only benefits in using CPTs:

  • CPTs provide easy input and update of grouped data;
  • CPTs categorize data and make it more consistent;
  • CPTs make the website more SEO-friendly.

5 Custom Post Types Usage Examples

Traditionally, users create WordPress custom post types for content like film catalogs, music, recipes, poems, products, calendars, testimonials, etc. Let’s look at some real WordPress sites with custom posts. I hope these examples will help you to understand them better.

The design studio Studio Koch uses WordPress custom post types to demonstrate its portfolio of completed projects. This portfolio includes different projects (brochures, a radio website, a business card, CD covers), but all these posts have the same fields and a similar layout. 

Here, you can see the Portfolio of this studio’s website.

portfolio wordpress custom post

If you click on one of the posts in the grid, you’ll see the CPT layout.

Hi-Speed Simuladores uses WordPress custom post types as a showcase for their products. CPT components include texts and photos. Sometimes, carousels can be spotted too.

portfolio wordpress custom post-product

The Watermark Collection uses WordPress custom post types for its product page layout, including photos, links, texts, and attachments. 

product wordpress custom post type

Floraria Azalee has photos, texts, videos, testimonials, and carousels. As you can see, WordPress’s custom post types can include dynamic content to add glitz and glamor to your site.

e-shop custom post

Emerald Guitars beautifully highlights the goods on the website and offers a choice of building your own piece or buying the existing model.

carousel wordpress custom post

I’d like to say that website development is close to real estate 一 you build a structure first. There are no types of widgets that cannot be included in CPTs because there is a place for everything. So, the next section of this article explains how to build custom post types.

How to Add Custom Post Types to WordPress Website

There are two ways to add custom post types to your website: manually with code and using a plugin

Manual method

If just a couple of extra post types are required, with a couple of meta fields and no special manipulations with them afterward, the manual method might be an option. Instead of writing dozens of lines of code, just use one of the generators like this, which makes your life easier. Add the code to the functions.php file, and the new post type will appear in the dashboard.

Adding CPT using a plugin

If you need many custom post types and fields and want to manipulate them somehow afterward (such as adding relations, populating them using data from front-end forms, displaying them in various listings, grids, calendars, etc.), you will definitely need a CPT plugin. 

JetEngine is the plugin with a huge list of tools that can replace 10+ different plugins made for creating and working with custom post types. 

Here are just a few very powerful features it offers, except for creating CPT:

After adding CPT, you will need to create a template for it. Check this link to learn how to do it. 

FAQ

Is the WordPress page a custom post type?

No, the WordPress “page” post type, together with the other six, is a default post type. 

How to create a custom post type?

The best way to do it is by using a plugin like JetEngine to not only register CPTs but also have full freedom in working with them. 

How to display custom post types? 

You should create a custom template, either by hardcoding it or by using a template plugin, such as JetThemeCore, Elementor Pro, or full site editing feature. Using JetEngine, you can display their grids (listings, etc.).

Is WooCommerce “product” type a CPT? 

Yes. But it’s generated using the WooCommerce plugin, with all the custom fields and templates. 

Bottom Line

It’s hard to imagine any more or less complex WordPress website without using custom post types. They are the basis of highly dynamic projects and play a crucial role in organizing and presenting content in a structured manner. Mastering custom post types is essential for anyone looking to unlock the full potential of WordPress as a content management system. Still, it’s not really possible without using powerful instruments like JetEngine.

Discover the power of JetEngine for CPTs
Discover now