Finding Custom Field Slugs for Mapping with Notion WP Sync
When working with custom fields in WordPress, especially those created by third-party plugins or themes, you might encounter cases where the field slugs (also known as meta keys) are not immediately available or visible. If you want to map fields from your Notion database to these custom fields in WordPress using Notion WP Sync, you’ll need to identify the exact slugs of these fields to ensure accurate mapping.
In this section, we’ll walk you through the process of identifying the slugs of custom fields and how to use them with Notion WP Sync.
Step 1: Install and use JSM Show Post Metadata to find custom field slugs
First, you need to identify the slugs (meta keys) of the custom fields that are already set up in your WordPress site.
- Install the plugin:
- Go to your WordPress Dashboard.
- Navigate to Plugins > Add New Plugin.
- Search for JSM Show Post Metadata.
- Click Install Now, then Activate.
- Locate the custom field slugs:
- After activating the plugin, go to the Posts, Pages, or any custom post type where these fields are used.
- Click on a post, page or CPT to edit it.
- Scroll down to the Post Metadata section. Here, you will see a list of all metadata associated with the post.
- Look for the specific custom field (meta key) you want to map. The Key is the slug used to store that field’s data.
Step 2: Use the custom field slugs in Notion WP Sync
Once you have the slugs of your custom fields, you can map your Notion data to these fields in WordPress using Notion WP Sync.
- Access Notion WP Sync mapping settings:
- Go to your WordPress Dashboard.
- Navigate to Notion WP Sync and select your connection.
- In the Field Mapping section, find the fields in your Notion database that correspond to the custom fields in WordPress.
- Map Notion fields to custom fields:
- Use the meta keys (custom field slugs) identified earlier with the JSM Show Post Metadata plugin.Select the relevant Notion field on the left side, and in the WordPress custom field dropdown, manually enter the meta key for the field you want to map.
If your custom field slug isauthor-event
, map the Notion “Event Speaker” field to the WordPressauthor-event
field by selecting “Custom Field” in the dropdown and add the slug.
- Save and Sync:
- After completing the mapping, click Publish or Update.
- Sync your Notion data with WordPress by clicking on Sync Now button. The data from your Notion database will now populate the custom fields on your WordPress site.
💡 Important Note
Even when using the JSM Show Post Metadata plugin, some slugs may not be displayed. This can happen if the data is not being stored as post meta. In such cases, it won’t be possible to map these fields with Notion WP Sync.
Notion WP Sync is not compatible with all kinds of Custom Post Types (CPTs), and that’s why we recommend using ACF (Advanced Custom Fields) to create your custom fields. We have full compatibility with ACF, ensuring seamless mapping and data synchronization.
Conclusion
Using JSM Show Post Metadata helps you uncover hidden custom field slugs, making it possible to map your Notion data accurately to these fields. Whether you’re dealing with complex custom post types or unknown meta keys, this workflow ensures that your WordPress content remains synced and organized. If you are working with complex CPTs, consider using ACF for better compatibility and a smoother experience.