All WordPress Plugins Shortcode

WooCommerce Product Count Shortcode

A lightweight WordPress plugin that displays your total WooCommerce product count anywhere on your site using a simple shortcode, with optional category and status filters.

Version 1.0 / WP 6.0+ / Updated Jul 2026
Download v1.0

After activating the plugin, use the shortcode anywhere WordPress accepts shortcodes: the block editor (Shortcode block), classic editor, text widgets, and most page builders (WPBakery, Elementor, etc.).

Basic usage — count all published products:

[wc_product_count]

Example: We currently have [wc_product_count] designs in the shop.We currently have 65 designs in the shop.

Count a single category (use the category slug, found under Products → Categories):

[wc_product_count category="apparel"]

Count multiple categories combined (comma-separated slugs, no spaces needed):

[wc_product_count category="apparel,poster"]

Count by product status (default is publish; accepts any WordPress post status, or any):

[wc_product_count status="any"]
[wc_product_count status="draft"]

Combine attributes:

[wc_product_count category="apparel" status="publish"]

Notes:

  • The output is a bare number formatted for your site’s locale (e.g. 1,250). Style it by styling the text around it — for example, place the shortcode inside a heading to make it part of a large stat counter.
  • Variable products count once each, regardless of how many size or color variations they have.
  • Category filtering includes products in the specified categories; passing several slugs returns the combined total without double-counting products that belong to more than one of them.

What it does

WooCommerce Product Count Shortcode adds a single, no-configuration shortcode to your site: [wc_product_count]. Drop it into any page, post, widget, or page-builder text block and it outputs the live number of products in your WooCommerce store. The count updates automatically as you add or remove products, so marketing copy like "65+ designs and counting" never goes stale.

You can also narrow the count to one or more product categories, or count products by status. The plugin outputs a plain, unstyled number that inherits the typography of whatever surrounds it, so it blends into headlines, hero sections, and stat counters without any CSS work. Variable products count as one product (not one per variation), which matches how customers think about your catalog. There are no settings pages, no database tables, and no scripts or styles loaded on the front end — just one fast query.

Installation

  1. Download the plugin ZIP file.
  2. In your WordPress admin, go to Plugins → Add New → Upload Plugin.
  3. Choose the ZIP file and click Install Now, then Activate.
  4. Add the shortcode [wc_product_count] anywhere shortcodes are supported.

Manual alternative: unzip the file and upload the woocommerce-product-count-shortcode folder to /wp-content/plugins/ via FTP, then activate it from the Plugins screen.

Requirements

  • WordPress 6.0 or higher (6.5+ recommended for automatic plugin dependency handling)
  • WooCommerce installed and active
  • PHP 7.4 or higher

If WooCommerce is deactivated, the shortcode silently outputs nothing rather than causing an error.

Changelog

1.0 July 18, 2026

Get WooCommerce Product Count Shortcode

v1.0 · 1 KB · GPL-2.0 · tested to WP 6.0+
Download plugin

Downloads: 0

Comments

Leave a comment

Your email won't be published. Required fields are marked.