Beyond Posts and Pages
Every piece of content in WordPress — a post, a page, even a media attachment — is stored as a "post type" under the hood. Posts and Pages are just the two built-in types. A Custom Post Type (CPT) lets you define a brand-new content type with its own admin menu, its own icon, and its own fields, completely separate from your blog posts.
If you've ever wondered how a site lists "Portfolio Items" or "Testimonials" in its own sidebar menu instead of mixing them into regular posts, that's a Custom Post Type doing the work.
- ✓Posts and Pages are themselves post types — CPTs work the exact same way.
- ✓Each CPT gets its own entry in the WordPress admin sidebar.
- ✓CPTs keep unrelated content separate from your blog and page listings.
What's Already There
Before creating anything new, it helps to see what WordPress already ships with — so you don't rebuild something that already exists.
Time-based, chronological content — blog entries, news updates, articles.
Static, standalone content that isn't part of a chronological feed — About, Contact, Home.
Every file uploaded to the Media Library, stored internally as its own post type.
Anything you define yourself — Portfolio, Testimonial, Team Member, Recipe, and so on.
If content doesn't fit naturally as a blog post or a static page, it probably deserves its own custom post type.
Plugin UI vs Code
// The two common approaches CPT UI plugin // point-and-click form, no code required register_post_type() // a PHP function added to your theme or a plugin
Both approaches register the same thing behind the scenes — one just does it through a form.
Using the CPT UI Plugin
portfolio.Which Approach Should You Use?
register_post_type() in your theme keeps it working even if you switch plugins later — the CPT UI plugin can even export the code for you.
Common Custom Post Type Mistakes
Breaking Down What You Just Learned
Everything is a post typePosts, Pages, and attachments are all built-in post types under the hood.
CPTs get their own spaceA custom post type earns its own sidebar menu, separate from posts and pages.
Two creation pathsThe CPT UI plugin offers a form; register_post_type() offers code-level control.
Code survives plugin changesA post type defined in code keeps working even without the original plugin active.
Resave permalinksNew post types need a permalink flush before their pages will load correctly.
Try It Yourself
Use CPT UI to create a "Testimonials" post type with the slug testimonial. Enable the featured image and custom fields options, then add one sample testimonial entry.
Add a Custom Post Type to Your Capstone Site
Giving your capstone site its own content type
By the end of today, your capstone site should have a working custom post type with at least two published entries.
- Install the Custom Post Type UI plugin.
- Create a post type that fits your capstone site — Portfolio, Testimonial, or Team Member.
- Set clear singular and plural labels and a short, valid slug.
- Resave Settings → Permalinks so the new URLs work.
- Add two sample entries and confirm both display on the front end.
Recap
The underlying content category WordPress uses for posts, pages, and anything custom.
A form-based way to register a new post type without writing code.
The PHP function that defines a post type in code for long-term portability.
Resaving permalink settings so new post type URLs stop returning 404s.
Key Takeaways
- Posts and Pages are built-in post types — Custom Post Types work the same way but hold different kinds of content.
- Custom Post Types give content like Portfolios or Testimonials their own dedicated admin menu.
- The CPT UI plugin creates a post type through a form;
register_post_type()does it in code. - Code-based registration keeps working even if you later remove the plugin used to build it.
- Always resave permalinks after adding a new post type to avoid 404 errors.