Technical
WordPress Custom Post Types: The Content-Shaping Superpower
A client wanted a simple site. Services, case studies, team bios. The WordPress default is posts and pages and nothing else. Reaching for a custom post type solved the problem in an hour and has kept solving it every time the content model evolves. This is the WordPress feature I wish more agency sites used.
What a Custom Post Type Is
A custom post type is a new kind of content object. WordPress gives you posts and pages by default. You can register case_study, service, team_member, each with its own admin UI, fields, and templates.
add_action('init', function() {
register_post_type('case_study', [
'label' => 'Case Studies',
'public' => true,
'supports' => ['title', 'editor', 'thumbnail', 'custom-fields'],
'show_in_rest' => true,
]);
});Ten lines in a plugin or theme's functions.php, and the client now has a dedicated Case Studies section in admin.
Why This Beats Shoving Everything in Posts
The alternative is using the default Posts type for everything and filtering by category. That approach falls apart within months. Categories leak, search returns mixed types, and templating has to guess.
With a custom post type, each type has its own query, its own archive page, its own template. The CMS matches the mental model instead of fighting it.
What AI Agents Get Right Here
Claude Code is great at generating the register_post_type call and the matching template file. I describe the content shape, it writes both pieces. The agent treats custom post types as boilerplate, which is exactly what they should be.
See the WordPress post types docs.
RELATED READING
The Consulting Shift I Am Making In Year Two
After a year of writing and building, my consulting practice is changing shape. Shorter engagements. Sharper outcomes.
ReadThe Frontend Shift: Shipping Less JavaScript In Year Two
A year ago I reached for Next.js for everything. This year I often reach for nothing.
ReadThe Serverless Lesson I Would Write On A Sticky Note
After a year of shipping serverless projects, one rule explains most of the wins and all of the losses.
Read