Restrict Content Pro

rcp_get_paid_posts()

Coming soon: Restrict Content Pro is becoming Kadence Memberships. You may see both names used while we update the product, documentation, and customer experience.

Note: This content is provided as a resource within our developer documentation. Because custom code requires highly specific implementation, we encourage you to work with a qualified developer if you need guidance. You can find our recommended consultants here: https://codeable.io/developers/restrict-content-pro

Returns published post IDs that have the Paid only metabox flag (_is_paid post meta set to 1). It does not include posts that are paid-only because of post-type-wide rules; use rcp_is_paid_content() per post when you need the full check.

Parameters

None.

Return values

(array) – Post IDs. Empty array if none match.

Examples

$paid_post_ids = rcp_get_paid_posts();

foreach ( $paid_post_ids as $post_id ) {
	// Each post has _is_paid meta on a published post.
}

Related: paid_posts shortcode, rcp_is_paid_content().

Last updated: October 15, 2026
Was this page helpful?
Thanks for the feedback!