Requiring members to agree to terms or provide consent can be a requirement for many membership sites. Paid Memberships Pro allows you to add a single Terms of Service (TOS) agreement by default. When members agree, the “Terms of Service” tab records their consent as TOS Consent History. But you’ll need more flexibility if you have multiple terms or policies.
This recipe allows you to add additional required consent checkboxes at checkout and records each agreement in the Terms of Service tab in the Edit Member area. Use it to ensure members acknowledge all necessary terms before completing their purchase.

Understanding the Code Recipe
Using the pmpro_checkout_before_submit_button
filter, the code dynamically adds checkboxes for each page that requires consent.
These checkboxes appear at checkout, requiring members to agree to all terms before proceeding. The agreements are validated before checkout and logged after completion, capturing details like the document version and timestamp.

Your additional pages will appear as links with a checkbox near the end of your checkout page. Users must agree to all checkboxes to complete the checkout process.


How to Use and Customize This Code Recipe
- In your WordPress admin, navigate to Pages > Add New. Create the additional page or pages with the information needed for the extra Terms of Service.
- Once the page(s) are published, make note of the page ID #.
- Enable your first page with the built-in TOS settings.
Memberships > Settings > Advanced – Other: “Require Terms of Service on signups?” - Add the code recipe to your site.
The Code Recipe
Adding the Recipe to Your Website
You can add this recipe to your site by creating a custom plugin or using the Code Snippets plugin available for free in the WordPress repository. Read this companion article for step-by-step directions on either method.
Customizations
Post IDs
Change the numbers on line 21 to the post IDs of your additional pages.
Example return array( 34, 45 );
Wording
Modify line 54 to change the wording that appears at checkout.
Error Message
Modify line 79 to change the error message that appears when a checkbox was not checked before submitting.