On this page
No Headings
Last updated: August 7, 2026
Estimated time: 5 minutes
The Buy Button is PayPal's low-code checkout experience. Set up your product and price in the PayPal dashboard, paste the generated embed code onto your page, and let customers pay on a secure PayPal-hosted checkout page. No backend, no SDK, no API required.
The Buy Button supports PayPal, Pay Later, Venmo, Apple Pay, and major debit and credit cards. It's available in more than 200 countries and regions, supports multiple languages, and accepts more than 23 currencies.
You need a PayPal Business account. The Buy Button feature isn't available on personal accounts.
Complete these steps to build your button in the PayPal dashboard, then copy the generated code onto your page.
Log into your PayPal Business account.
Choose one of these entry points:

From + Create, select Payment Link or Button.
Open the Build Your Payment Links and Buttons page and select Payment buttons.

Select Build it. Before saving, you can customize the button style and colors, and choose whether checkout opens in-context or in a new window.
Use the dashboard tabs to update the button text, style, colors, and checkout flow without writing CSS.

PayPal provides two embed formats. Choose the one that works best for your site.
This option loads the PayPal, Pay Later, Venmo, and card buttons from a hosted script. It is the recommended integration and requires two snippets.
Part 1. Paste into <head> once per page:
<!-- index.html (in <head>) -->
<script src="https://www.paypal.com/sdk/js?client-id=YOUR_CLIENT_ID&components=hosted-buttons¤cy=USD"></script>Part 2. Paste into <body>, near the product:
<!-- index.html (in <body>) -->
<div id="paypal-container-BUTTON_ID"></div>
<script>
paypal
.HostedButtons({
hostedButtonId: "BUTTON_ID",
})
.render("#paypal-container-BUTTON_ID");
</script>Replace BUTTON_ID with the ID from your PayPal dashboard. To display multiple products on one page, repeat Part 2 with each product's unique ID.
<head>, place Part 1 at the top of <body>, above Part 2. Both snippets must be on the same page for the button to render.
For more information, see the PayPal Payment Links and Buttons help article.
You can add multiple buttons to a single page, one per product. Use the following guidelines:
hostedButtonId. Reusing the same ID will cause only the first button to render.Find each button's ID in your PayPal dashboard under the button details.