This is a simple PGP snippet that I successfully used on a bunch of websites in order to set the default Billing country or state. This is a great way to save the user some time during checkout (and therefore increase your conversion rate) in case you almost exclusively sell to customers located in a given country or state. Nothing else to say, just… enjoy! Continue reading WooCommerce: Set Default Billing State / Country @ Checkout
Let’s say you require to make the “address” field at checkout bigger. Instead of an “input type = text”, we’d require an “input type = textarea” in HTML. This was my WooCommerce client’s challenge: how can I edit a checkout field input type programmatically? Here’s the snippet! Continue reading WooCommerce: Change Input Field to Textarea @ Checkout
On a recent job, a client asked me to get the logged in username in WooCommerce. Interesting task! He needed to show that on the checkout form page and also on the order email. Actually, this is quite simple to do and can be used for several applications. Continue reading WooCommerce: Get/Edit Logged in Username @ Checkout
When you apply a coupon code programmatically, or when you really need it anyway, you may want to hide the coupon code on the cart page.
This is simply because you want to avoid that certain customers will know the coupon code and try to give it to someone else. Continue reading WooCommerce: Hide Coupon Code @ Cart & Checkout Page
A client needed to add her SSL Logo Seal to the checkout page. The problem is that the code she was given had also a JS part, together with a bunch of HTML.
A simple function for a very common issue: “I can’t find where to change the PayPal icon?”. If you have the same problem, here’s a quick PHP fix.Continue reading WooCommerce: Change the PayPal Icon @ Checkout Page
A client, clearly from a European English-speaking country (not many, uh?), wanted to change the cart page when it says “Shipping” or “Shipping and Handling” in the totals table. The same string appears on the checkout page. As it’s only 1 string, my favourite method is by implementing a very simple PHP function, that needs to be placed in your functions.php file. Continue reading WooCommerce: edit or translate “Shipping and Handling” on the Cart & Checkout page
In some countries there is no Postcode/ZIP (such as Ireland!). How do we make the Postcode/ZIP field not required, or how do we completely remove it? The answer is very simple. Continue reading WooCommerce: Disable PostCode/Zip Field on the Checkout Page
Interesting issue. A client found out that if you push the “enter” on your keyboard while on the WooCommerce Checkout page, the form will be automatically submitted. Ouch! What if the customer wanted to use a different shipping method? What if “enter” is pushed by mistake? So, here’s how you disable it. Continue reading WooCommerce: Disable Keyboard “Enter” on Checkout Page
A WooCommerce client wanted to show some text in the checkout page, and specifically “Please allow 5-10 business days for delivery after order processing.” so that customers are aware of how shipping works. This is a vital information you should disclose on every page of your ecommerce website, and of course on the checkout page too. Continue reading WooCommerce: Add Shipping Notices on Checkout Page
Some plugins such as “deposit” and “subscription” payments send customers to the “Pay for Order” page in order to complete a pending WooCommerce order. In certain cases, also, customer is forced to log in and this really affect sales conversion rate – instead of the checkout form customers see this notice: “Please log in to your account below to continue to the payment form“.
Here’s a quick snippet to make sure customers do not have to log in when on the “Pay for Order” page, so that they can immediately go ahead with the payment. The WooCommerce function in question is wc_customer_has_capability, and thankfully we can override this with the user_has_cap filter. Enjoy!Continue reading WooCommerce: Allow to “Pay for Order” Without Login
I had the pleasure to speak at WordCamp Prague 2019. I spoke about “10 PHP Snippets to Increase WooCommerce Sales” and managed to show some simple coding to the audience. Trust me – increasing your WooCommerce sales can also be done with a free, short, easy PHP snippet.
So, given that I want to share all the snippets I talked about, this is a quick recap. Copy them, test them (a must!) and then use them. And let me know if your conversion rate and/or AOV (average order value) increased!
At the bottom of the page you also find my talk slides. Enjoy:) Continue reading WooCommerce: 10 Easy Snippets to Increase Your Sales
Setting up a recurring revenue stream is one of the hottest ecommerce money-making strategies. And there is no doubt that, no matter whether you sell cakes, audio books, services, rentals, there is always room for a “subscription” product.
Think about selling a product once, and then seeing automatic renewal orders come through. And where the customers’ credit card is automatically charged. Yes, this can be done with a “WooCommerce Subscriptions” plugin.
Though, it comes at a cost (besides, it’s a subscription you have to purchase from a WooCommerce plugin developer to guarantee on-going bug fixing, support and maintenance!), with the reason being you can’t really code such a delicate functionality on your own (with a snippet for example). Subscription plugins are about money, revenue, automatic charge operations, tokens, error handling, retrials and other complex things – at this stage you have no other choice than purchasing an out-of-the-box solution: a reliable WooCommerce Subscriptions plugin.
The hard part here is deciding which subscription plugin is the best fit for you as a user and for your WooCommerce store. You also need to consider things such as integration, compatibility, UX, payment gateways, support (my favorite), code quality, functionality roadmap, maintenance, long-term reliability and – also – price.
This ultimate review guide goes through my top 3 choices. From $49 to $199, you have a full range of products, and each one offers the same exact thing: recurring payments.
So, what’s the difference? Which one should you pick? Continue reading WooCommerce: Which “Subscriptions” Plugin Should You Buy? 
How can WooCommerce customers edit an order they just placed and paid for? I swear I looked on search engine results and other places before coming to the conclusion I needed to code this myself.
For example, a user might want to change the delivery date (if you provide this on the checkout page). Or maybe they need to change size, or make up their mind about a given product in the order.
Either way it’s shocking to me this functionality is not in a plugin – as usual if you’re interested in customizing this snippet/plugin for your specific needs feel free to get in touch.
So, let’s see how it’s done!Continue reading WooCommerce: Allow Users to Edit Processing Orders
We already have a nice “SALE” badge by default with WooCommerce (as well as the “OUT OF STOCK”) one. These show on the shop page once certain conditions are met.
Now, what if we wanted to show a “NEW” badge for products added in the last 30 days? This would certainly grab the customer attention, and also communicate the fact your shop is constantly updating with new products and content (well, good for Google too, right?).
So, how do they do it? (Sounds like one of those Discovery Channel shows…)
Well, here’s a simple snippet for you; simply copy/paste into your functions.php and magically a “NEW” badge will show (note: CSS is not provided, you’ll need to adjust it based on your current theme and custom styles). Continue reading WooCommerce: Display “NEW” Badge on Recent Products
A WooCommerce email notifications pops up – yet another new order, money, revenue, happiness. However, hold on a second – money is not technically in your bank account until you’re forced to give a refund. Even worse, until you realize not only you had to give a refund, but also getting the item back costs you a fortune. And who knows how many times this is going to happen, mostly when you ship physical products.
Fortunately, there are ways in WooCommerce to blacklist customers, deny purchasing from specific countries, block certain IP addresses and do whatever you can to save money.
In the era of Amazon and online shopping we constantly hear of scams and frauds, so this is definitely a topic that shouldn’t be underestimated. A small plugin investment or a few lines of code could actually make a big difference.
Besides, choosing the correct online payment methods (which should give you some sort of anti-fraud out of the box) and avoiding offline payments (bank transfer, cash on delivery, check) are important measures you should already have in place.
So, moving beyond the actual online payments, there is something else we could do to stop scammers placing an order (yes, even before paying or trying to pay). Prevention is better (and more affordable) than cure, right?
I’ve put together a list of WooCommerce plugins and settings you should look into from today on. And sooner rather than later. Enjoy 🙂 Continue reading How to Blacklist WooCommerce Scammers, Emails, IP, Phones?
AOV a.k.a. Average Order Value is one of the most important ecommerce metrics. It describes the average order total in a given period of time. If this year your WooCommerce website converted 150 orders and made $30,000 in revenue, your AOV for this year is $30,000/150 = $200 (i.e. on average, you can expect each order to be $200).
If you don’t know what your WooCommerce store AOV is, immediately go to WordPress Dashboard > WooCommerce > Reports > Orders > Sales by Date > Year and divide “net sales in this period” by the number of “orders placed”. But be careful – those reports are sometimes not correct (I know WooCommerce is working on this at the moment). Mine is giving me AOV = €2… and I know that’s not right.
Your best bet is your Google Analytics account (as long as you’re using the official WooCommerce – Google Analytics integration) and/or your Metorik reports (here’s an article you should read if you need to know how to install reliable WooCommerce tracking, reporting, filtering and segmenting: https://businessbloomer.com/advanced-woocommerce-tracking-analytics-reports-exports-segmentation/). My Metorik dashboard tells me my WooCommerce website AOV for this year is €233 so far – I can trust this one for sure.
So the question is: how can we get our WooCommerce customers to spend more? Well, here’s a list of WooCommerce plugin alternatives you can install right now to boost your AOV.
In fairness, who wouldn’t want some extra revenue? 🙂 Continue reading WooCommerce: How to Increase Average Order Value?
The “woocommerce_thankyou” hook fires on the Thank You page once an order is placed. Most tracking functions like Google Analytics, affiliate commission plugins and other WooCommerce extensions rely on “woocommerce_thankyou” to run their code.
Problem is – “woocommerce_thankyou” is ALSO called if an order fails (i.e. payment did not go through). Now, unless the plugin is smart enough in its own functions to exclude failed orders, which doesn’t happen often I’m afraid, we need to find a way NOT to run “woocommerce_thankyou” if an order fails. Case study: a client uses a third party affiliate plugin, this plugin hooks into “woocommerce_thankyou“, but they don’t want to calculate conversions when an order fails.
This is a guest post by Matthew Abdalah of Rumbleship – if you like the article, make sure to thank him in the comments!
Customers live in a world of digital distractions and the last place you want your customers to be distracted is during checkout.
Consumer ecommerce (B2C, business-to-consumer) has taught the B2B (business-to-business) world a lot about what a distraction-free, conversion-friendly checkout looks like: we should reference these lessons for best practices.
Due to its ubiquity, your wholesale buyers are conditioned to expect a comparable level of service to what they experience on B2C websites such as Amazon and eBay.
Tactics like 30-day terms, free shipping and bulk discounts are some of the techniques referenced in this article but we’ve compiled a few extra ones.
Here are 5 creative ways to reduce wholesale WooCommerce shopping cart abandonment, increase your sales conversion rate and grow your profits. Continue reading WooCommerce: 5 Ways To Increase B2B Conversions
When you add a hidden product to Cart, either manually or programmatically, this will be displayed in the Cart, Checkout and Order details pages (I’m not sure why a hidden product behaves like that… but thankfully you can hide hidden products from the Cart/Checkout/Order page with this snippet).
Problem is, even if you hide hidden products from the Cart page, the “Mini-Cart” product counter icon or text (it depends on your theme) will still count them as products (see the screenshot below). So the question is: in conjunction with the snippet aforementioned, how do I exclude hidden products from being counted in the “menu cart” (also called Mini-Cart Widget)? Continue reading WooCommerce: Exclude Hidden Products from Mini-Cart Counter