Viewing 8 replies - 1 through 8 (of 8 total)
  • Hi @mattthomas-photography,

    Thanks for reaching out and for sharing those links. I understand you’d like to remove the “Stripe” title in the new Optimized Checkout experience and adjust the styling to match your preferred layout.

    In WooCommerce 9.8.0, the Optimized Checkout adds the payment gateway title (“Stripe”) by default. At present, there isn’t a built-in option or setting to hide or remove this in the checkout UI. Achieving this would require either a small custom PHP filter or a CSS rule targeting that element. While we can’t provide full custom code solutions here, your developer could use the checkout markup as a reference to make the change.

    Similarly, the Optimized Checkout payment form does not yet offer the same styling hooks as the UPE layout. Any adjustments to the layout or design would need to be applied via custom CSS or filters.

    You can review our documentation for more details:

    Since these changes involve modifying the checkout template or applying custom CSS, they fall outside the scope of our standard support. If you don’t have a developer, we recommend contacting one of our certified WooExperts, who are experienced in customizing WooCommerce checkout flows.

    • This reply was modified 8 months, 2 weeks ago by Sai (woo-hc).
    Thread Starter matt-thomas-photography

    (@mattthomas-photography)

    Sounds like a chat AI reply most of that to be fair! As you’ve linked back to the two articles I mentioned first of all and just repeating the message

    In fact the Optimized Checkout DOES use the styling taken from the UPE as if not all of them being classed the base styling is in fact the same from the link I sent over. So maybe over time more will be added and docs updated with higher detail of what can be changed. Font size, icon colour when selected

    Also the Stripe title that appears, actually flash displays the default “Credit / Debit Card” title before switching to now just saying Stripe, so looks like more code work from dev needing if the Optimized Checkout is going to be the normal going forward on the plugin

    Hi @mattthomas-photography,

    Thanks for taking the time to follow up and for sharing your additional observations. I can see how my earlier reply came across as generic, and I appreciate you pointing that out.

    You’re right, the Optimized Checkout currently inherits its base styling from the UPE setup, so some of the classes and styling options are the same, though not all of the UPE hooks are exposed yet. As you mentioned, more may be added over time as the feature matures, and the documentation should be updated accordingly to reflect these changes.

    Regarding the “Stripe” title: I was able to reproduce the brief flash of “Credit / Debit Card” before it switches to “Stripe.” This is part of the current UI logic in Optimized Checkout and isn’t something that can be toggled or removed via a setting at the moment. Removing or changing it would require custom development.

    I know this doesn’t immediately solve your request, but your feedback here helps us improve both the product and the documentation. I’ll keep an eye out for any changes in upcoming releases, and I recommend checking the changelog for updates to Optimized Checkout’s styling and display controls.

    Thanks again for sharing your findings. It’s valuable to have detailed real-world insights like this.

    Hello, @mattthomas-photography
    Here’s a snippet which work
    What it does
    – Waits for the payment page to load.
    – Observe the DOM changes (because Stripe dynamically reloads its elements).
    – As soon as it finds a label with “Stripe”, it replaces it with your custom text.

    add_action( ‘wp_footer’, function() {
        if ( is_checkout() ) : ?>
            <script type=”text/javascript”>
                document.addEventListener(‘DOMContentLoaded’, function() {
                    // Observe changes to the payment block
                    const observer = new MutationObserver(() => {
                        document.querySelectorAll(‘.wc_payment_method.payment_method_stripe label’).forEach(label => {
                            if (label.textContent.trim() === ‘Stripe’) {
                                label.textContent = ‘Credit & Debit Card / SEPA Direct Debit’;
                            }
                        });
                    });
                    observer.observe(document.body, { childList: true, subtree: true });
                });
            </script>
        <?php
        endif;
    });

    • This reply was modified 8 months, 2 weeks ago by Hergé. Reason: explanations
    • This reply was modified 8 months, 2 weeks ago by Hergé.
    Plugin Support LovingBro (woo-hc)

    (@lovingbro)

    Hi @rguilbert

    Thank you for sharing this snippet — it’s a helpful example for anyone looking to change the “Stripe” title in the Optimized Checkout. I’m sure other users following this thread will find it useful.

    Thread Starter matt-thomas-photography

    (@mattthomas-photography)

    I’d probably need to translate into English as that looks like it’s French currently? It can be fully hidden with CSS for a display none but I was just surprised to see the default change to display Stripe. Thanks for the suggestion @rguilbert

    They definitely need more details about the OC checkout option as saying that it doesn’t take styling but in fact it actually does, just not everything is live. Would definitely be worth creating a list of the properties that CAN be changed currently.

    Thread Starter matt-thomas-photography

    (@mattthomas-photography)

    Snippet wasn’t quite right @lovingbro as looks like @rguilbert had the wrong quotes in certain sections so wouldn’t read it right

    add_action( 'wp_footer', function() {
    if ( is_checkout() ) : ?>
    <script type="text/javascript">
    document.addEventListener('DOMContentLoaded', function() {
    const changeLabel = () => {
    document.querySelectorAll('.wc_payment_method.payment_method_stripe label').forEach(label => {
    if (label.textContent.trim().includes('Stripe')) {
    label.textContent = 'Credit / Debit Card';
    }
    });
    };

    // Run once on load
    changeLabel();

    // Observe changes for dynamically loaded content
    const observer = new MutationObserver(changeLabel);
    observer.observe(document.body, { childList: true, subtree: true });
    });
    </script>
    <?php
    endif;
    });

    However the fact needing to add this to change the message when there is already a “Card” title within the new OC form layout, makes sense when you have more payment options enabled but just having Credit/Debit Card – makes a doubled up title which isn’t needed. So looking like just hidding via CSS the label till the OC option has more back end function added

    Hi @mattthomas-photography,

    Thank you for sharing your updated findings and refining the snippet. I can see how having a full list of currently supported Optimized Checkout styling properties would be useful.

    For now, since your initial question on removing or changing the “Stripe” title has been addressed and you’ve found workable approaches, I’ll go ahead and close this thread. If you run into any other issues or have further questions, please don’t hesitate to start a new one.

    Thanks again for taking the time to test and share your insights; it helps improve both the product and resources for all users.

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘9.8.0 Checkout Experience – Title and Styling’ is closed to new replies.