Title: registered_post_type_{$post_type}
Published: May 25, 2022
Last modified: August 20, 2026

---

# do_action( “registered_post_type_{$post_type}”, string $post_type, WP_Post_Type $post_type_object )

## In this article

 * [Description](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#description)
 * [Parameters](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#changelog)

Fires after a specific post type is registered.

## 󠀁[Description](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#description)󠁿

The dynamic portion of the filter name, `$post_type`, refers to the post type key.

Possible hook names include:

 * `registered_post_type_post`
 * `registered_post_type_page`

## 󠀁[Parameters](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#parameters)󠁿

 `$post_type`string

Post type.

`$post_type_object`[WP_Post_Type](https://developer.wordpress.org/reference/classes/wp_post_type/)

Arguments used to register the post type.

## 󠀁[Source](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#source)󠁿

    ```php
    do_action( "registered_post_type_{$post_type}", $post_type, $post_type_object );
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-includes/post.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/7.1/src/wp-includes/post.php#L1908)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/7.1/src/wp-includes/post.php#L1908-L1908)

## 󠀁[Related](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#related)󠁿

| Used by | Description | 
| [register_post_type()](https://developer.wordpress.org/reference/functions/register_post_type/)`wp-includes/post.php` |

Registers a post type.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/hooks/registered_post_type_post_type/?output_format=md#changelog)󠁿

| Version | Description | 
| [6.0.0](https://developer.wordpress.org/reference/since/6.0.0/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fregistered_post_type_post_type%2F)
before being able to contribute a note or feedback.