I ran into a similar problem using smart buttons a few days ago( roughly January 25, 2021 ). I solved the problem by following some suggestions at php - PayPal Smart Payment Buttons error paypal.Buttons is not a function - Stack Overflow The two steps below are a more clean and concise description of the changes. I edited 2 parts of the autogenerated code. I set data-namespace="paypal_sdk" in the script tag so the tag looks like: <script src="https://www.paypal.com/sdk/js?client-id=your-id-goes-here" data-sdk-integration-source="button-factory" data-namespace="paypal_sdk"></script> I replaced paypal with paypal_sdk in: paypal_sdk.Buttons({
style: {
color: 'gold',
shape: 'rect',
label: 'pay',
layout: 'vertical'
} I hope paypal fixes this soon in a way that doesn't break the workaround above.
... View more