Skip to content
Aaron Carmen
WooCommerce

WooCommerce Shortcodes: The Full List, Tested on 11.2.1

By Aaron CarmenUpdated October 20, 20264 min readTested on WordPress 7.1.3, October 20, 2026

Quick answer

WooCommerce shortcodes still work in version 11.2.1: all 25 were registered on my test store. The one you'll use most is [products], which shows chosen products by ID, category or other filters. New stores now build the cart and checkout pages with blocks, so [woocommerce_cart] and [woocommerce_checkout] mostly matter on older sites. My Account still uses a shortcode.

On this page
  1. What changed: cart and checkout use blocks
  2. The shortcodes worth knowing
  3. The full list, as tested
  4. The block that replaces each one
  5. When a shortcode shows nothing

WooCommerce shortcodes used to build whole stores: the cart, checkout, account pages and product grids. They still work, but new stores now build some of those pages with blocks instead. I tested every shortcode registered by WooCommerce 11.2.1 on a test store to show which still matter and what each one produces.

What changed: cart and checkout use blocks

When I installed WooCommerce 11.2.1, it created four pages. Two of them don’t use shortcodes any more:

Page What WooCommerce 11.2.1 created
Cart The Cart block
Checkout The Checkout block
My Account The [woocommerce_my_account] shortcode
Shop An empty page, filled in by the theme’s template

So on a new store, you’ll only see [woocommerce_cart] and [woocommerce_checkout] if you add them yourself. On stores set up a few years ago, those pages often still use the shortcodes, and they still work: [woocommerce_cart] showed “Your cart is currently empty” on my test store.

The shortcodes worth knowing

[products]: the one you’ll use most

[products] shows a grid of products, filtered however you like. On my test store:

  • [products ids="53,54" columns="2"] showed the two products I named, in two columns.
  • [products category="uncategorized" limit="3"] showed three products from that category.
A page titled Shop Our Favourites showing an Electric Toothbrush and a Whitening Kit in two columns, each with a price and Add to cart button
[products ids=“53,54” columns=“2”] in a Shortcode block on a Twenty Twenty-Five page. WooCommerce 11.2.1, October 20, 2026.

The numbers are product IDs. If you don’t know them, my guide to finding a product ID in WooCommerce shows where they are.

[products] options, tested

[products] takes options that cover most of what the older single-purpose shortcodes did. Each of these worked on my test store:

Shortcode What it showed
[products skus="WK-01,TB-02"] The two products with those SKUs, so you can use SKUs instead of IDs
[products orderby="price" order="DESC" limit="3"] Most expensive first: Night Guard, Electric Toothbrush, Whitening Kit
[products orderby="price" order="ASC" limit="3"] Cheapest first, the same three in reverse
[products limit="2" paginate="true"] Two products with page links and “Showing 1–2 of 3 results”
[products ids="53" class="featured-pick"] The product, wrapped in a CSS class you can style
[products ids="999"] Nothing, because no product has that ID

Drafts don’t appear: a draft copy of the Whitening Kit on my test store never showed in any of these lists, which is what you want while you’re still editing a product.

Single products and buttons

  • [product_page id="53"] puts a whole product section on any page: title, price, quantity box, Add to cart, SKU and reviews. Useful for a landing page selling one product.
  • [add_to_cart id="53"] shows just the price and an Add to cart button.
  • [add_to_cart_url id="53"] prints only the link, for use in your own button. On my test store it built the link from the current page’s address with add-to-cart=53 added.

Account and orders

  • [woocommerce_my_account] is still what new stores use for the My Account page. Logged out, it showed the login form.
  • [woocommerce_order_tracking] shows a form where customers enter their order number and billing email.

The full list, as tested

All 25 shortcodes were registered on WooCommerce 11.2.1:

Shortcode Result on my test store
[products] Product grid filtered by ID, category and more
[product_page] A full product section, as above
[product] One product as a single grid item, with its price and button
[product_category] Products from one category
[product_categories] A list of categories with product counts
[add_to_cart], [add_to_cart_url] A button, or just the link
[recent_products], [best_selling_products], [top_rated_products] Still render; [products] with sorting options can do the same
[featured_products], [sale_products] Empty until you mark products featured or on sale
[product_attribute] Empty for attributes set on single products; needs a global attribute
[related_products] Registered; not rendered in my test
[woocommerce_cart], [woocommerce_checkout] Classic cart and checkout; checkout is empty when the cart is
[woocommerce_my_account], [woocommerce_order_tracking] Account area and order tracking form
[shop_messages] Store notices; empty when there are none
[woocommerce_messages] Registered; not rendered in my test
[product_brand] and four other brand shortcodes Registered by WooCommerce’s built-in Brands; not rendered in my test

The block that replaces each one

If you’re building new pages in the block editor, each main shortcode has a block equivalent in WooCommerce 11.2.1:

Shortcode Block
[products] Product Collection
[product_page] Single Product
[product_categories] Product Categories List
[shop_messages] Store Notices
[woocommerce_cart], [woocommerce_checkout] Cart, Checkout

The exception is [woocommerce_my_account]. The Customer account block is the small account icon and link in a header, not the account area itself, which is why WooCommerce still uses the shortcode for the My Account page.

When a shortcode shows nothing

Three empty results on my test store were all for the same reason: nothing matched. [featured_products] and [sale_products] need products marked featured or with a sale price. [product_attribute attribute="size"] showed nothing because I’d added Size to one product only. It works with attributes created under Products → Attributes, which every product can share.

If a shortcode prints as plain text instead, with the square brackets showing, it isn’t registered: check WooCommerce is active and the name is spelled exactly right.

If you’re moving an older store’s cart and checkout to blocks, or something on a shortcode page has stopped working, that’s the kind of job I handle in my WordPress development work. Choosing between WooCommerce and a hosted store? See WooCommerce vs Shopify.

FAQ

Common questions

Do WooCommerce shortcodes still work?

Yes. On WooCommerce 11.2.1, all 25 shortcodes were registered and the product shortcodes rendered normally on my test store. What changed is the default pages: new stores get a Cart and Checkout built with blocks instead of shortcodes.

Should I switch my cart and checkout from shortcodes to blocks?

Not as an emergency. The shortcodes still rendered on my test store. If your checkout relies on plugins or custom code made for the shortcode version, test them with the Checkout block on a staging copy first, because not every extension supports blocks.

Why does my WooCommerce shortcode show nothing?

Usually because nothing matches it. On my test store, [featured_products] and [sale_products] printed empty containers because no product was featured or on sale, and [product_attribute attribute="size"] showed nothing because Size was set on one product rather than as a global attribute.

How do I add a WooCommerce shortcode to a page?

In the block editor, add a Shortcode block and type the shortcode inside it. In page builders like Elementor, use their shortcode widget. Product shortcodes need product IDs or category slugs, which you can find in the Products and Categories lists.

Aaron Carmen, SEO specialist

About the author

Aaron Carmen

Senior WordPress Developer and SEO Specialist

I've built and optimized WordPress websites since 2013, 13+ years in total, including 9.5 years building WordPress sites for every client of a dental marketing agency. Today I help local businesses and agencies with WordPress development and SEO, so they get found on Google Search, Google Maps and AI search.

WordPress is a trademark of the WordPress Foundation. Aaron Carmen is not affiliated with or endorsed by the WordPress Foundation or the WordPress open source project.

Contact

Want this done for you?

Tell me about your site and what you need. I'll reply within one business day with any questions, then a fixed quote.

  • Reply within one business day
  • No obligation, no hard sell
  • Form and email only, calls optional
What you need

Prefer email? hello@aaroncarmen.com