Title: Adding CPT fields in Blocks theme template
Last modified: October 19, 2024

---

# Adding CPT fields in Blocks theme template

 *  [representativeself](https://wordpress.org/support/users/representativeself/)
 * (@representativeself)
 * [1 year, 7 months ago](https://wordpress.org/support/topic/adding-cpt-fields-in-blocks-theme-template/)
 * I’ve set up a custom post type and want to display the data on a single page 
   template. Within the Twenty Twenty-Four theme, I’m editing the single page template
   for my custom post type but where can I find the CPT fields when editing the 
   template? I can’t seem to find any blocks for my fields. Do I need to enable 
   these anywhere?

Viewing 1 replies (of 1 total)

 *  [S P Pramodh](https://wordpress.org/support/users/sppramodh/)
 * (@sppramodh)
 * [1 year, 7 months ago](https://wordpress.org/support/topic/adding-cpt-fields-in-blocks-theme-template/#post-18103764)
 * Hello [@representativeself](https://wordpress.org/support/users/representativeself/),
 * You can create templates for custom post types (CPTs) directly within the **Site
   Editor** by navigating to **Appearance > Editor**. In the left Navigation Sidebar,
   select **Templates**. To make your custom post type appear in this list and create
   custom templates for it, ensure it’s registered with `'show_in_rest' => true`.
   This setting allows the CPT and its fields to be accessible in the Block Editor.
   Steps to Create a Template for a Custom Post Type:
    1. **Add a New Template**:
    2.  - Click on the **plus icon** (+) to add a new template. You’ll see a scrollable
          modal window with available template types.
        - If a specific template already exists, it won’t appear in the list. In this
          case, you can edit or delete the existing template instead.
    3. **Choose from Template Options**:
    4.  - You can create templates for different purposes, including:
           * A **default template** for all items of the post type.
           * A **single item template** for individual posts of that type.
           * An **archive template** for listing all items of the custom post type.
           * A **taxonomy archive template** for displaying items under specific taxonomies.

Viewing 1 replies (of 1 total)

The topic ‘Adding CPT fields in Blocks theme template’ is closed to new replies.

 * ![](https://ps.w.org/advanced-custom-fields/assets/icon.svg?rev=3207824)
 * [Advanced Custom Fields (ACF®)](https://wordpress.org/plugins/advanced-custom-fields/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/advanced-custom-fields/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/advanced-custom-fields/)
 * [Active Topics](https://wordpress.org/support/plugin/advanced-custom-fields/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/advanced-custom-fields/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/advanced-custom-fields/reviews/)

## Tags

 * [custom post type](https://wordpress.org/support/topic-tag/custom-post-type/)
 * [Themes](https://wordpress.org/support/topic-tag/themes/)

 * 1 reply
 * 2 participants
 * Last reply from: [S P Pramodh](https://wordpress.org/support/users/sppramodh/)
 * Last activity: [1 year, 7 months ago](https://wordpress.org/support/topic/adding-cpt-fields-in-blocks-theme-template/#post-18103764)
 * Status: not resolved