- Before you start
- Get the embed code
- Choose between an inline checkout and a popup button
- Paste the inline checkout code
- Paste the popup button code
- Add the code to your website
- Check that it works
- See what the buyer sees after the order
- Check which payment methods stay on your page
- Work around the limits of an embedded checkout
The Embed feature shows the checkout form of a PublishPress Cart product on a website that does not run on WordPress. You paste a short code into a Showit, Squarespace or Webflow site, or into a plain HTML page. The buyer pays on that page, and the order goes to your Cart store like any other order.
This feature requires PublishPress Cart Pro. To show a checkout on a page of your own WordPress site, use the Checkout block instead.
Before you start #
You need:
- PublishPress Cart Pro installed and active on your WordPress site.
- A published product. The Embed tab shows the code only for a published product.
- A website where you can add custom HTML code.
Get the embed code #
- Go to Cart → Products and open the product.
- In the product settings, click the Embed tab. It is in the Grow sales group.
- Under Choose how the checkout shows, select Inline checkout or Popup button.
- Under Copy the code into your website, click Copy.
- Paste the code into your website.
This is the Embed tab with Inline checkout selected:

The Open the embedded checkout in a new tab link shows the checkout alone. Use it to check the form before you paste the code.
The checkout keeps the settings of the product, such as the payment plans, the fields, the Primary color and the Submit button text. When you change the product, the embedded checkout changes too. You do not need to copy the code again.
Choose between an inline checkout and a popup button #
The Embed tab gives two codes:
- Inline checkout: The form shows in your page. The form area grows and shrinks with its content. Use it when you have room for the form on the page.
- Popup button: A button shows in your page. A click opens the form in a popup over the page. Use it when you want a buy button in a sales section.
Paste the inline checkout code #
Paste the Inline checkout code where the checkout form must show. The form takes the width of the area that holds it.
This is an inline checkout on a website outside WordPress:

Paste the popup button code #
Paste the Popup button code where the button must show. The label of the button is the Submit button text of the product. If that setting is empty, the label is “Buy now”.
This is the Embed tab with Popup button selected:

The button has no style of its own. Your website gives the button its look, so it matches your other buttons:

A click on the button opens the checkout over the page. The buyer closes the popup with the close button, the Esc key, or a click outside the popup. On a phone, the popup fills the screen:

Add the code to your website #
Paste the code into an element that accepts custom HTML:
- Showit: Add an Embed Code element and paste the code. For the inline checkout, set the type of the section to Grow with Content. Make the element as wide as the section, on desktop and on mobile.
- Squarespace: Use a Code block.
- Webflow: Use a Code Embed element.
- Plain HTML page: Paste the code where the checkout or the button must show.
Each code ends with a <script> tag. This tag loads the embed script from your WordPress site. One script runs every inline checkout and popup button on the page. If you paste two codes into one page, you can leave both scripts in place.
The inline checkout code looks like this. Your code has the address of your own site and product.
<div data-ppcart-checkout="https://yourstore.com/products/photography-masterclass/"></div>
<script src="https://yourstore.com/wp-content/plugins/publishpress-cart-pro/modules/embed/js/ppcart-embed.js" async></script>Check that it works #
- On the Embed tab, click Open the embedded checkout in a new tab and check the form.
- Paste the code into a page of your website and publish the page.
- Open the page and complete a test order.
- In WordPress, go to Cart → Orders and find the new order.
See what the buyer sees after the order #
After the payment, the receipt shows in the same place as the form. The buyer stays on your page:

If the product sends the buyer to a thank-you page on another website, that page opens in the whole browser window.
Check which payment methods stay on your page #
Some payment methods keep the buyer on your page. Other payment methods have their own payment page.
- With Stripe Checkout, PayPal with Redirect to PayPal, and Mollie, the payment page opens in the whole browser window. The receipt then shows on your WordPress site, not on the other website.
- Razorpay is not supported. Do not use Razorpay as the only payment method of a product that you embed.
Work around the limits of an embedded checkout #
The embedded checkout has these limits:
- Offers after checkout do not show. A product with an offer after checkout sends the buyer to the receipt after the payment. The same product on your WordPress site still shows its offers.
- A logged-in buyer is usually not logged in inside the embedded checkout. Browsers block the login cookie of your WordPress site on another website. The buyer can still complete the order.
- A site-wide framing block stops the checkout. If your web server or CDN sends an X-Frame-Options header or a frame-ancestors policy for all pages, the checkout cannot show on another website. Ask your host to allow framing for your product pages. A security plugin that sets these headers through WordPress does not cause this problem.
- The popup opens only from the Popup button code. A site builder button that accepts only a link cannot open the popup. Link such a button to the normal checkout page of the product.
- Some site builders put custom code in a box of a fixed height. Wix is one example. There, the inline checkout scrolls inside the box, and the popup stays inside the box. Make the box tall enough for the form, or link a button to the normal checkout page of the product.
