If you’re running a WooCommerce store and want to stand out with a unique touch, customizing your currency symbol is a fantastic way to do it. In this comprehensive guide, we’ll explore the process of adding a custom currency symbol in WooCommerce store using the filter hook method. Let’s dive into the details and enhance your web programming skills.
Table of Contents
Introduction
Sometimes you need your currency symbol in your store. For example, if your currency is Singapore Dollar, the WooCommerce shows it as “$”. Your site visitors will be confused about whether it is a US Dollar or currency. In this article, we will see how to add a custom currency symbol in WooCommerce for products, carts, and checkout using the filter hook method.
Implementation: custom currency symbol in WooCommerce
To make your currency symbol precise and more informative you can introduce your symbol which helps users to understand the currency.
You need to add the following snippet in functions.php
of your child theme:
<?php // add custom currency in WooCommerce settings add_filter( 'woocommerce_currencies', 'add_c_currency' ); function add_c_currency( $c_currency ) { $c_currency['SING_DOLLAR'] = __( 'Singaporian Dollar ', 'woocommerce' ); return $c_currency; } // define custom currency symbol add_filter('woocommerce_currency_symbol', 'add_c_currency_symbol', 10, 2); function add_c_currency_symbol( $custom_currency_symbol, $custom_currency ) { switch( $custom_currency ) { case 'SING_DOLLAR': $custom_currency_symbol = 'SG'; break; } return $custom_currency_symbol; } ?>
This snippet will add a custom currency symbol in WooCommerce.
Please note that you can add your currency symbol here. I have added a new currency with the name “Singaporian Dollar” and the symbol I like is “SG$”.
The “SG” is a country code of Singapore so instead of showing “$” it is more informative to show “SG$”.
How to select the currency in WooCommerce
Navigate to WooCommerce > Settings > General and scroll down to “Currency Options”.
Under currency, you will see your currency name (Singaporian Dollar in my case)

Click “Save Changes” and open the products page of your store and your new currency symbol will be reflected.
Examples
Once the snippet is added, this is how the currency will look like:
Products
The products grid:

Cart Table
The cart table with totals:

Testing and Optimization: Ensuring a Seamless Shopping Experience
Before implementing the custom currency symbol in WooCommerce, thoroughly test its functionality. Ensure it works seamlessly across different products and scenarios. Optimize the code for performance, addressing any potential issues.
Conclusion
Congratulations! You’ve successfully personalized your store by adding a custom currency symbol in WooCommerce store. This not only sets your store apart but also showcases your attention to detail. By incorporating such customizations, you’re not just managing a store; you’re creating a unique shopping experience.
Enjoy the process of making your WooCommerce store more user-friendly.