Reserve Your Free Seat for Our Next WooCommerce Class! Search
Business Bloomer
  • Business Bloomer Club
  • WooCommerce Plugins
  • WooCommerce Tips
  • Log In
  • 0
  • Business Bloomer Club
  • WooCommerce Plugins
  • WooCommerce Tips
  • Log In
  • Search
  • Contact
  • Cart
WooCommerce Code Snippets My Account Shipping Thank You Page

WooCommerce: Hide “Shipping Via ___” @ Thank You Page, View Order Page

Last Revised: Nov 2022

STAY UPDATED

Especially when you do a lot of custom shipping, showing the shipping method title may not be a good idea. Honestly, the default “via ___” suffix beside the shipping cost doesn’t make much sense anyway.

So, let’s get rid of it. With a 1 liner. Enjoy!

Here on the Thank you page (also, on the View Order page under My Account), a suffix is added to the shipping amount with the name of the shipping method. This is what we’re trying to completely hide.

PHP Snippet: Remove “via ___” Shipping Amount Suffix @ WooCommerce Thank You & My Account > View Order Pages

/**
 * @snippet       Hide "via ___" @ WooCommerce Thank You Page
 * @how-to        businessbloomer.com/woocommerce-customization
 * @author        Rodolfo Melogli, Business Bloomer
 * @compatible    WooCommerce 7
 * @community     https://businessbloomer.com/club/
 */

add_filter( 'woocommerce_order_shipping_to_display_shipped_via', '__return_empty_string' );

Where to add custom code?

You should place custom PHP in functions.php and custom CSS in style.css of your child theme: where to place WooCommerce customization?

This code still works, unless you report otherwise. To exclude conflicts, temporarily switch to the Storefront theme, disable all plugins except WooCommerce, and test the snippet again: WooCommerce troubleshooting 101

Related content

  • WooCommerce: Separate Login, Registration, My Account Pages
    There are times when you need to send logged out customers to a Login page and unregistered customers to a standalone Register page. As you…
  • WooCommerce: Remaining $$$ to Get Free Shipping Notification @ Cart
    This is a very cool snippet that many of you should use to increase your average order value. Ecommerce customers who are near the “free…
  • WooCommerce: Add New Tab @ My Account Page
    One of the features of Business Bloomer Club is the provision of Premium WooCommerce Q&A Support to supporters who enroll. So, how to add an…
  • WooCommerce: Redirect to Custom Thank you Page
    How can you redirect customers to a beautifully looking, custom, thank you page? Thankfully you can add some PHP code to your functions.php or install…
  • WooCommerce: Weight-Based Shipping Methods
    With WooCommerce you get 3 default shipping methods: Flat Rate, Free Shipping, Local Pickup. For each one you can define a cost, however there is…

Rodolfo Melogli

Business Bloomer Founder

Author, WooCommerce expert and WordCamp speaker, Rodolfo has worked as an independent WooCommerce freelancer since 2011. His goal is to help entrepreneurs and developers overcome their WooCommerce nightmares. Rodolfo loves travelling, chasing tennis & soccer balls and, of course, wood fired oven pizza. Follow @rmelogli

4 thoughts on “WooCommerce: Hide “Shipping Via ___” @ Thank You Page, View Order Page”

  1. Judith
    March 2, 2023

    Thanks! Works perfectly. And I agree — this “via” never made any sense!

    Reply
    1. Rodolfo Melogli
      March 7, 2023

      Great!

      Reply
  2. Ilias Korkos
    November 23, 2022

    Hello Rodolfo, thank you very much once again (that default suffix doesn’t make sense to most of us I think).
    It works great with flat_rate but not with local_pickup.
    Although I have made heavy modifications to Shoptimizer and haven’t tested it with any default theme.

    Reply
    1. Rodolfo Melogli
      November 25, 2022

      Thank you. Yes, for $0 Local Pickup there is no “Shipping via ___” suffix anyway. In case Local Pickup is > $0, the “via Local pickup” is correctly removed

      Reply
Questions? Feedback? Customization? Leave your comment now!
_____

If you are writing code, please wrap it like so: [php]code_here[/php]. Failure to complying with this, as well as going off topic or not using the English language will result in comment disapproval. You should expect a reply in about 2 weeks - this is a popular blog but I need to get paid work done first. Please consider joining the Business Bloomer Club to get quick WooCommerce support. Thank you!

Cancel reply

Your email address will not be published. Required fields are marked *


Search WooCommerce Tips

Popular Searches: Visual Hook Guides - Checkout Page - Cart Page - Single Product Page - Add to Cart - Emails - Shipping - Prices - Hosting

Recent Articles

  • WooCommerce: Redirect Empty Paginated Category Pages (404)
  • WooCommerce: Complete Button @ Order Admin
  • WooCommerce: Allow Guest Checkout For Existing Customers
  • WooCommerce: Simplify Free Checkout
  • WooCommerce: Inject Ad After the nth Product @ Shop Page

Latest Comments

  1. Rodolfo Melogli on WooCommerce: Separate Login, Registration, My Account Pages
  2. Rodolfo Melogli on WooCommerce: Complete Button @ Order Admin
  3. Rodolfo Melogli on WooCommerce: Failed Orders Monitor & Temporary Lockdown

Find Out More

  • Become a WooCommerce Expert
  • Business Bloomer Club
  • WooCommerce Blog
  • WooCommerce Weekly
  • Contact

Contact Info

Ciao! I'm Rodolfo Melogli, an Italian Civil Engineer who has turned into an international WooCommerce expert. You can contact me here:

Twitter: @rmelogli

Get in touch: Contact Page

Business Bloomer © 2011-2025 - VAT IT02722220817 - Terms of Use - Privacy Policy

Cart reminder?

x