Solved

Disable Express Payment Options in the Checkout

nichharp
Shopify Partner
19 4 17

I'm looking into hiding the express payment buttons from the Checkout using Checkout Extensions. We had a solution to do this using Checkout.liquid but with that being deprecated we're looking into other solutions.

 

nichharp_0-1717654740481.png

 

So far we've tried:

  1. Adding `{{ content_for_additional_checkout_buttons }}` into the core site (this doesn't seem to affect the Checkout anymore)
  2. Using the Hide Operation function. This however did not work as we wanted because (for example) Paypal has the same ID as the Paypal Express option, meaning you could not turn off one without turning off the other. We had some ideas about toggling the on/off state when the user gets to a certain point in the checkout but this caused CLS and it wasn't a preferred option.

 

Shopify Support cannot support this directly and have no solution in their dev guides. We did find this app but it seems to do option #2 so this isn't ideal.

 

If anyone has any advice on this or any ideas I would be grateful!

Accepted Solution (1)

nichharp
Shopify Partner
19 4 17

This is an accepted solution.

Shortly after posting this we found the solution in the latest API version 2024_07.

Using the PaymentCustomizationPaymentMethod and the placements field. You are able to hide the "acceleration checkout" options with:

    return {
        operations: [
            {
                hide: {
                    placements: [PaymentCustomizationPaymentMethodPlacement.AcceleratedCheckout]
                }
            }
        ]
    }

No more need for 3rd party apps or hacky code. This will do it.

View solution in original post

Replies 3 (3)

nafeeur10
Shopify Partner
21 0 1

This app could help you.
https://apps.shopify.com/payrules-conditional-payment-methods 

Please let me know if it works by giving it a like or marking it as a solution!
Working as Technical Lead at Zepto Product Personalizer
If you need any help, mail me at inafeeur [at] gmail.com or Give me a text message on Skype nafeeur.rahman1

store-crafters
Shopify Partner
24 1 1

Hey,

To disable Paypal express checkout go to Settings -> Payments -> Deactivate Paypal

After deactivating paypal the express checkout gets removed from checkout automatically, 

P.S. if it helps you, do leave a like 🙂

nichharp
Shopify Partner
19 4 17

This is an accepted solution.

Shortly after posting this we found the solution in the latest API version 2024_07.

Using the PaymentCustomizationPaymentMethod and the placements field. You are able to hide the "acceleration checkout" options with:

    return {
        operations: [
            {
                hide: {
                    placements: [PaymentCustomizationPaymentMethodPlacement.AcceleratedCheckout]
                }
            }
        ]
    }

No more need for 3rd party apps or hacky code. This will do it.