Having issues with your custom post type (CPT) single page not working? Look no further, it may just need a quick permalink refresh in your WordPress website’s settings.
Understand WordPress hierarchy
You should first read up on WordPress’s template hierarchy to fully understand how the single post-types work.
Check your custom post type name
You need to check if you’re using the right custom post type name. You should var_dump() the PHP code below and debug your single page using this data.
var_dump( get_post_type() );
Refresh your permalink settings
Sometimes WordPress fails to read the correct URL. You should try to refresh your website’s permalinks.
- Open your WordPress website’s dashboard;
- Navigate to Settings > Permalinks;
- Click the Save Changes button;
- Refresh your singles page.