We are trying to integrate paypal checkout into our web app. I can hide the pay later ( credit) and the card option from showing up easily using the query parameter disable-funding=credit,card as indicated here However I still see the options for Pay-later on my Paypal authorize page (https://www.sandbox.paypal.com/webapps/hermes...) (screenshot attached ). How can I disable them from showing up on the authorize page? Thanks in advance.
2 Answers
You have to set the option disableFunding to 'credit'.
If you are using a script tag
<script src="https://www.paypal.com/sdk/js?client-id=YOUR_ID&disable-funding=credit"></script>
If a package set the prop named disableFunding of options in to credit .
eg. Using react
<PayPalButton
amount="1.00"
currency={currency}
catchError={(err: Error) => console.log(err)}
options={{ currency:"USD", clientId:"xxxxx", disableFunding: 'credit' }}
onError={(err: Error) => console.log(err)}
/>
-
This controls the display of a Pay Later or PayPal Credit button on your own site -- but it does NOT change what will be available once the buyer reaches a PayPal checkout page, as in this question's screenshot. Nov 26, 2021 at 22:06
-
1
'disable-funding': 'credit'
(written as if it was a url parameter) worked for me!– RilDevSep 12, 2022 at 13:49
You can't. You only control the buttons displayed on your own site.
Once on a PayPal page, the buyer can always use any funding source they might be eligible for. It's between them and PayPal, and it's all kept private by design.
(The receiver of a PayPal payment won't ever know whether the payer used one of the above funding sources, or something else like a bank or card or PayPal balance. It's none of their business.)