Collection for WooCommerce
Turn WooCommerce product categories and tags into smart collections. Add conditions to a category or tag and matching products are put into it automatically. You decide what happens to products that stop matching, and the plugin tells you before it removes anything.
Version 3.0.0 WooCommerce plugin Paid plugin Requires WordPress 6.5 Requires PHP 7.4 Tested up to 7.1 WooCommerce 11.2 Updated 13 Oct 2026
1. Overview
Collection for WooCommerce turns WooCommerce product categories and product tags into smart collections, the way collections work in Shopify. You add conditions to a category, for example "Tag is equal to summer" and "On sale is equal to Yes", choose whether a product must match all of them or any of them, and the plugin puts every matching product into the category.
A collection is an ordinary product category or tag. Its archive page, menu entries, widgets, filters and blocks work as before. The only difference is a set of conditions stored on the term (see Term meta and post meta). Categories and tags without conditions are never changed, and a product's other categories and tags always stay as they are.
For every collection you choose what happens to products in it that do not match: remove them, remove them only if the conditions added them, or never remove anything. Version 3 remembers which products the conditions added, so products you put into a category by hand can stay.
How it works
- Open Products → Categories (or Products → Tags), add or edit a term and fill in Collection conditions.
- Choose what happens to products that do not match. A notice explains the choice; Preview matching products shows the result.
- Save. If the new conditions would remove products, the plugin lists them first and asks.
- The plugin stores the conditions on the term and starts a background check of every product. From then on a product is checked again whenever it changes, and all products on a schedule (every hour by default).
- Every change the conditions make is written to the activity log and, after a save on the product screen, shown in a notice.
At a glance
Smart categories and tags
Up to 50 conditions per collection, all or any, on product categories, product tags or both.
Twelve condition fields
Title, description, short description, SKU, category, tag, global attribute, price, on sale, inventory, stock status and product type.
Keep hand-added products
Remove non-matching products, remove only what the conditions added, or only ever add: per collection, with a store default.
No surprises
A notice explains each choice, the products a change would remove are listed before saving, and the preview shows the numbers.
Always current
Products are re-checked when saved, imported or when stock, prices or variations change; all products in background batches.
Activity log and Polylang
Every change with its reason and trigger. With Polylang every language has its own collections.
What it does not do
- It does not create categories or tags, and it never deletes one. Create the term first, then add conditions.
- It does not change categories and tags that have no conditions.
- It does not add anything to the shop front. A collection is shown like any other category or tag.
- It does not test custom (local) product attributes, custom fields or the attributes of single variations. The Attribute condition uses global attributes (Products → Attributes) set on the product.
- It does not order the products inside a collection; WooCommerce does (or Category Products Reorder for WooCommerce).
- It does not touch products in the Trash, auto-drafts or revisions.
- Removing all conditions does not empty a collection: it becomes a normal category or tag and keeps its products.
2. Requirements
| Item | Requirement | Notes |
|---|---|---|
| WordPress | 6.5 or later | Tested up to 7.1. |
| PHP | 7.4 or later | Checked on PHP 8.2 to 8.5. The intl extension is optional: when its Normalizer class exists, text is compared in Unicode normal form. |
| WooCommerce | 8.0 or later | Required (the plugin header says Requires Plugins: woocommerce, so WordPress does not activate the plugin without it). Tested up to 11.2, with HPOS, the Cart and Checkout blocks and the product block editor. |
| Action Scheduler | Comes with WooCommerce | Runs the background checks. If its functions are missing, batches fall back to WP-Cron single events and the periodic check is not scheduled. |
| Polylang or Polylang Pro | Optional | Every language has its own collections. See Polylang. |
| Who can use it | manage_product_terms or manage_woocommerce | Shop Managers and Administrators. The settings tab needs manage_woocommerce. See Who can do what. |
3. Installation
- Make sure WooCommerce is installed and active.
- Open Plugins → Add Plugin → Upload Plugin, choose the zip from your purchase (
wphub-collections-3.0.0.zip), click Install Now and then Activate. - Open Plugins → WpExperts Hub Licences and activate your licence key to receive updates.
- Check the defaults under WooCommerce → Settings → Collections (see Settings).
- Open Products → Categories, add or edit a category and use Collection conditions (see Quick start).
Activation creates no tables, roles or pages. It switches version 2.x off if it is active, takes over its data (see Updating from version 2.x) and schedules the periodic check on the next page load. Settings are stored as WooCommerce options when you first save the settings tab; until then the defaults apply.
Licence and updates
The plugin bundles the WpExperts Hub licence and update client (licence/class-wpxh-licence-client.php). It is loaded only in the admin, for scheduled tasks and for WP-CLI. One screen manages every WpExperts Hub plugin on the site: Plugins → WpExperts Hub Licences.
- Find your licence key in the purchase email or under My Account → Downloads on wpexpertshub.com.
- Paste it into Licence key on the plugin's card and click Activate licence.
- New versions then appear on the normal Dashboard → Updates and Plugins screens. Without an active licence WordPress shows the update but cannot install it automatically.
The licence only unlocks updates. No feature of the plugin checks it. A licence bought for version 2.x works for version 3 (the licence server knows both plugin folders).
Updating from version 2.x
Up to 2.5.0 the plugin lived in the folder wxp-woo-collections. Version 3 lives in wphub-collections, so WordPress treats it as a different plugin. The recommended way:
- Upload and activate version 3 next to the old one. It deactivates version 2.x, copies its conditions, takes over the licence key, removes the old scheduled jobs and shows: "the previous version (folder "wxp-woo-collections") was deactivated because version 3 replaces it. Its N collections were taken over with their conditions."
- Delete the old Collection for WooCommerce (folder
wxp-woo-collections) on the Plugins screen. Your collections stay.
If you clicked "Update now" on version 2.x (or WordPress updated it automatically): WordPress installs the new folder in place of the old one but cannot switch the new plugin on, because it is a different plugin. The Plugins screen may say "The plugin wxp-woo-collections/wxp-woo-collections.php has been deactivated due to an error: Plugin file does not exist." Nothing is lost: the old conditions, the licence and the products' categories are still there, but products are not assigned until you click Activate under Collection for WooCommerce. Version 3 then copies everything and says "version 3 took over the N collections of the previous version". Sites with plugin auto-updates switched on should check the Plugins screen after the update.
What the takeover does, once per site (option wphub_collections_legacy_done):
- Copies the 2.x conditions of every product category (term meta
_wxp_term_condition) to_wphub_collections_rules, unless the category already has 3.x conditions. Conditions on values that are not offered any more (a deactivated add-on's product type, a deleted attribute) are copied too. - Marks the products that are in those categories as "added by the conditions", because version 2.x decided all of them. This only matters if you later choose "Remove it only if the conditions added it".
- Copies an activated licence (
_wxp-woo-collections_licence_keyand its status) to_wphub-collections_licence_keyif version 3 has none yet. - Removes the 2.x scheduled actions (
wxp_col_queue,wxp_col_queue_batch) and its temporary options and transients. The 2.x conditions themselves stay for the old uninstall routine.
Version 2.x always removed products that did not match. Version 3 does the same by default ("Remove it, also when it was added by hand"), so nothing changes until you choose another setting. Code that used the 2.x hooks keeps working; see Hooks of version 2.x. If both versions are loaded in one request (2.x reactivated by hand), version 3 stops the hooks of 2.x and deactivates it on the next admin page.
Multisite
Conditions are term meta and settings are options, so each site has its own collections, settings, log and scheduled actions. Network activation takes over the 2.x data on every site at once. A 2.x copy that is active for the whole network is only deactivated network-wide when version 3 is network-active too; otherwise a notice asks you to deactivate it once every site uses version 3. Deleting the plugin cleans every site (see What deactivation and uninstall remove).
Deactivating and deleting
Deactivating removes the plugin's scheduled actions (on every site when it was network-active). Conditions, settings and the log stay, products keep their categories, and nothing is checked until you activate the plugin again. Deleting the plugin keeps the conditions unless "When the plugin is deleted: also delete the conditions of all collections and these settings" is ticked. Categories, tags and the products in them are never deleted.
4. Quick start
- Open Products → Categories, enter a name such as "Summer Sale" and scroll to Collection conditions. To turn an existing category into a collection, click its name instead.
- Under Products must match, choose All conditions (the default) or Any condition.
- Set the first condition: a field such as Tag, an operator such as "is equal to" and a value such as summer. Click Add another condition for more, for example On sale is equal to Yes.
- Under When a product in this category does not match, keep the store default or choose another setting. The notice below the list explains it.
- Click Preview matching products to see how many products match.
- Click Add new category, or Update on the edit screen. If products would be removed, the plugin lists them first.
Products are assigned at once when they change and all existing products are checked in the background; the blue panel at the top of the screen shows the progress.
5. Smart collections
The Collection conditions box
The box appears on the Add and Edit screens of Products → Categories and Products → Tags for users who can manage product terms, when conditions are switched on for that type (Conditions on). On the edit screen it says how many products are in the term now, with a View products link.
- Products must match: All conditions or Any condition. A counter shows how many conditions are filled in.
- Conditions: each row has a field, an operator and a value (and an attribute for the Attribute field). Category, tag and attribute values suggest your existing names while you type (up to 500, see filters). Up to 50 rows; a value can be up to 255 characters.
- When a product in this category does not match: the store default or one of the three settings described under Products that do not match. Change the store default opens the settings tab.
- The notice below explains what the chosen setting will do and, when the term has products, how many it holds now.
Rows without a value are ignored. When some rows are filled and others are empty, the first click on Update stops with a warning; fill the rows in, delete them or click Update again. When every submitted condition is invalid (for example a number field with letters), the stored conditions are kept and a warning says so; to turn a collection back into a normal term, delete all rows on purpose and save.
Condition fields and operators
| Field | Operators | What is compared |
|---|---|---|
| Title, Description, Short description, SKU | is equal to, is not equal to, starts with, ends with, contains, does not contain | The product's text as saved (descriptions with their HTML). Case, accents and extra spaces are ignored. |
| Category, Tag | the same six | The names of the product's categories or tags (not their parents, not slugs). |
| Attribute | the same six | The names of the terms of the chosen global attribute set on the product. |
| Price | is equal to, is not equal to, is greater than, is less than | The current price (the sale price during a sale). A variable product matches when any of its variations does. |
| Inventory | the same four | The stock quantity of a product that manages stock (a variable product without own stock: the total of its variations that manage stock). Products that do not manage stock, or every product when stock management is switched off store-wide, have no quantity and never match. |
| On sale, Stock status, Product type | is equal to, is not equal to | A value chosen from a list (Yes/No, In stock/Out of stock/On backorder, Simple/Variable/Grouped/External and the types of add-ons). |
How a condition is evaluated
- "is not equal to" and "does not contain" on Category, Tag and Attribute match products that have no such term at all.
- A Category or Tag condition can name another collection. Collections are evaluated together, so a chain of collections is complete after one check, and two collections that exclude each other do not switch back and forth.
- A stored condition whose value is not offered any more (a product type of a switched-off add-on, a deleted attribute) is kept and shown as "(not available now)" or "Deleted attribute (#ID)". It matches no product until the value exists again, so the collection does not suddenly collect more products.
Products that do not match
Every collection has the setting When a product in this category does not match. The store default is set under General settings.
| Setting | Badge | What happens | Good for |
|---|---|---|---|
| Remove it, also when it was added by hand | Removes non-matching | The collection holds exactly the matching products. A product you put in by hand that does not match is taken out again. This is how version 2.x worked. | Sale, New arrivals, Under $25 |
| Remove it only if the conditions added it | Keeps hand-added | Matching products are added and taken out again when they stop matching. Products that were in the term before, or that you add by hand, always stay. | Categories you also fill by hand |
| Keep it (only add products, never remove) | Only adds | Matching products are added and never taken out. | Collections that only grow, such as "Ever on sale" |
The plugin remembers which products the conditions added (post meta _wphub_collections_auto, one row per collection). That record is what makes the middle setting possible; it is kept up to date in every setting, so you can switch at any time.
The check before saving
When you click Update on an existing collection after changing its conditions or its setting, the plugin first checks the products that are in the term now ("Checking which products these conditions would remove… X of Y"; Save without checking skips it). If none would be removed, it saves. Otherwise it shows Some products will be removed with their names and three choices:
- Save and remove them saves as you set it.
- Keep the products added by hand (only with "Remove it, also when it was added by hand") switches the collection to "Remove it only if the conditions added it" and checks again.
- Cancel returns to the form.
The check is skipped for new terms, for "Keep it", when nothing that matters changed and when "Check before saving" is switched off. If the check cannot finish, you can Save anyway or Cancel.
Preview matching products
The button checks every product against the conditions in the form, in small steps that also work for large catalogues, without saving anything. It says how many products match with a few examples and, on the edit screen, how many would be added, removed or kept by the chosen setting. It follows the same rules as the real check, including other collections named in a condition and the language rule of Polylang.
Smart tags
Product tags get the same box on Products → Tags. A smart tag such as "Last few" (Inventory is less than 5 and Stock status is In stock) can be shown in tag clouds and filters, and category collections can use it ("Tag is equal to Last few"), or the other way round. Switch categories or tags off under Conditions on; a switched-off type keeps its conditions but is not changed any more and its box is hidden.
When products are checked
- At once: when a product is created or saved (edit screen, Quick Edit, Bulk Edit, REST API, the WooCommerce CSV importer, WP All Import, the XAdapter importer, other plugins, WP-CLI), when its stock changes, when a variation is saved, changes stock or is deleted, when its categories, tags or attributes are set by other code, and when a scheduled product is published.
- In the background: all products after you change a collection's conditions or setting, after a relevant setting changes, after a term a condition names is renamed or deleted, and periodically (every hour, twice a day, once a day or never).
- On demand: Re-check all products now in the status panel.
The background check looks at published and private products (also drafts, pending and scheduled products when that setting is on). A draft is always checked when it is saved.
What the plugin changes on a product
Only the categories and tags that have conditions. For each product the plugin works out which collections it matches (with Polylang only collections of its own language), adds the ones it matches and removes the ones it does not match, as far as each collection's setting allows. All other categories and tags stay.
- A product whose only category was the default one ("Uncategorized") loses it when it joins a category collection, unless that setting is switched off.
- A product that would be left without any category gets the default category back (of its own language with Polylang).
- Products in the Trash, auto-drafts and revisions are never changed.
Background checks and the status panel
A full check walks through the products by ID in batches (50 by default), one batch at a time, each limited to 20 seconds, with WooCommerce's Action Scheduler (group wphub-collections). Changing conditions while a check runs starts a new one, so the new conditions reach every product.
The panel at the top of the categories and tags screens and of the settings tab shows the number of smart collections, the progress of a running check ("Checking your products: X of Y done", refreshed every few seconds) or when the last full check ran and how many products it checked and updated. A check that has made no progress for 15 minutes is reported as stopped and can be started again with Re-check all products now. With "Automatic assignment" switched off the panel says that nothing is changed.
The Collection rules column
The lists on Products → Categories and Products → Tags get a Collection rules column (it can be hidden in the settings): a badge such as "2 rules (match all)" and the collection's setting (Removes non-matching, Keeps hand-added, Only adds), or a dash for a normal term.
The product edit screen
In the Product categories box, collections are marked Smart with a note that ticking or unticking them can be changed back when you save; the Product tags box lists the product's smart tags. After you save a product on its edit screen, a notice says what the conditions changed, for example "Collection conditions added it to Summer Sale." with a link to the activity log. Quick Edit and Bulk Edit show no notice; their changes are in the log. Both can be switched off in the settings.
The activity log
WooCommerce → Settings → Collections → Activity log lists every category and tag the conditions added to or removed from a product, newest first: when, the product, the change, why and the trigger. The last 500 changes are kept, 50 per page, and Clear the log empties it.
| Why | Meaning |
|---|---|
| matches the conditions | The product was added because it matches. |
| no longer matches the conditions | The product was removed because it does not match. |
| the collection is in another language | Polylang: a collection of another language was removed from the product. |
| the default category, so the product keeps a category | The default category was added because the product would have had none. |
| the default category was only a placeholder | "Uncategorized" was removed because the product joined a collection. |
| changed by custom code (filter) | A filter of another plugin or theme changed the result. |
Triggers: Product saved (in the admin, by Quick or Bulk Edit, the REST API, or by WooCommerce itself, for example when an order changes the stock), Background check, Stock changed (stock set without a product save), Variation changed, Categories or tags set by other code, Import, Scheduled product published.
Polylang
Add the conditions on the term of each language; the values are names in that language (the French category "Chaussures" uses French tag names). A collection only collects products of its own language, and a product only joins collections of its own language. A product that loses its last category gets the default category of its own language. The preview and the check before saving follow the same rule.
Renaming and deleting terms
Renaming a category, tag or attribute term updates the "is equal to" and "is not equal to" conditions that name it; conditions such as "contains" are not rewritten. Deleting a term re-checks the products. Both start a full check.
Who can do what
| Action | Needs |
|---|---|
| See and use the conditions box, the preview, the status panel and Re-check all products now | manage_product_terms or manage_woocommerce (saving a term also needs permission to edit it) |
| WooCommerce → Settings → Collections, Clear the log | manage_woocommerce |
| Messages about version 2.x | activate_plugins |
| Licence screen | manage_options |
Conditions are saved only from the plugin's own form with its nonce, so forms of other plugins cannot change them by accident.
6. Settings
All settings are on WooCommerce → Settings → Collections, in three sections. They are WooCommerce options named wphub_collections_<key>.
General
| Setting | Option key | Default | What it does |
|---|---|---|---|
| Automatic assignment | enabled | on | Off pauses the plugin (for example during a large import): no product is changed and the conditions are kept. Switching it on again checks all products. |
| Conditions on: Product categories / Product tags | on_categories, on_tags | both on | A switched-off type keeps its conditions, but its collections are not changed and its box is hidden. |
| When a product does not match | default_mode | Remove it, also when it was added by hand | The store default for every collection that has no setting of its own. |
| Default category | drop_default_cat | on | Remove "Uncategorized" when a product joins a category collection (only when it was the product's only category). |
| Check before saving | confirm_removals | on | List the products changed conditions would remove before saving. |
| Rules column | rules_column | on | The Collection rules column on the categories and tags lists. |
| Product edit screen | product_screen | on | Smart marks in the Product categories and Product tags boxes and the notice after a save. |
| Activity log | log_enabled | on | Keep a log of the last 500 changes. |
| When the plugin is deleted | delete_data | off | On: deleting the plugin also deletes the conditions of all collections, the settings and the log. |
Saving a setting that changes which products belong where (pause, categories/tags, store default, default category, drafts) starts a full check.
Background checks
| Setting | Option key | Default | What it does |
|---|---|---|---|
| Full check of all products | schedule | Every hour | Every hour, twice a day, once a day or never. Catches changes that happen without a product save (a scheduled sale starting or ending, direct database imports). |
| Products per batch | batch_size | 50 | 1 to 500. Lower it on slow hosting, raise it on fast servers with large catalogues. |
| Draft products | include_drafts | off | Also check draft, pending and scheduled products in full checks. |
Activity log
The third section shows the log described under The activity log, with paging and Clear the log.
Limits that code can change
| Limit | Value | Change with |
|---|---|---|
| Time one batch may take | 20 seconds | wphub_collections_batch_seconds |
| Products per batch | the setting (50) | wphub_collections_batch_size |
| Seconds between full checks | the setting (3600) | wphub_collections_queue_interval (at least 300) |
| Names suggested while typing a value | 500 | wphub_collections_autocomplete_limit |
| Conditions per collection, characters per value, log entries | 50, 255, 500 | fixed |
7. Developer reference
Filters
| Filter | Arguments | Use |
|---|---|---|
wphub_collections_mode | $mode (sync | keep_manual | add_only), $stored, $term_id, $product_id | What happens to non-matching products, per collection (and product). |
wphub_collections_product_categories | $new (category IDs), $product_id, $matched, $current | Change the categories a product gets. |
wphub_collections_product_tags | $new (tag IDs), $product_id, $matched, $current | Change the tags a product gets. |
wphub_collections_batch_size | $size | Products per background batch. |
wphub_collections_batch_seconds | $seconds (20) | Time budget of one batch. |
wphub_collections_queue_interval | $interval (seconds) | Time between full checks (minimum 300). |
wphub_collections_autocomplete_limit | $limit (500) | Names offered while typing a category, tag or attribute value. |
// Never remove products from the "Sale" category, whatever its setting says.
add_filter( 'wphub_collections_mode', function ( $mode, $stored, $term_id ) {
return 42 === (int) $term_id ? 'add_only' : $mode;
}, 10, 3 );
Actions
| Action | Arguments | When |
|---|---|---|
wphub_collections_product_updated | $product_id, $after, $before (product_cat / product_tag => IDs), $changes (taxonomy => added / removed IDs) | After the conditions changed a product's categories or tags. |
wphub_collections_pass_completed | $job (processed, changed, started, finished) | After a full check of all products. |
Hooks of version 2.x
They still work and are reported as deprecated (once per request) when something uses them: merge_collection_categories (true = every collection only adds; use wphub_collections_mode), wxp_collection_product_categories, wxp_collection_batch_size, wxp_collection_batch_seconds, wxp_collection_queue_interval, wxp_collection_product_updated (with category IDs only) and wxp_collection_pass_completed.
AJAX and admin-post actions
| Action | Nonce | Purpose |
|---|---|---|
wp_ajax_wphub_collections_preview | wphub_collections_admin | Preview and the check before saving (scope all or members), in steps. |
wp_ajax_wphub_collections_status | wphub_collections_admin | Refreshes the status panel while a check runs. |
admin_post_wphub_collections_recheck | wphub_collections_recheck | Re-check all products now (returns to the screen it came from). |
admin_post_wphub_collections_clear_log | wphub_collections_clear_log | Clear the log (needs manage_woocommerce). |
The conditions are posted with the term form (fields wphub-collections-field[], -operator[], -value[], -attribute[], the match and mode fields) and saved on created_term / edited_term only when the form carries wphub-collections-data and the nonce wphub_collections_nonce (action wphub_collections_rules).
Term meta and post meta
| Key | On | Value |
|---|---|---|
_wphub_collections_rules | product_cat / product_tag term | array( 'type' => 'all'|'any', 'args' => array( array( 'type' => field, 'condition' => operator, 'compare' => value, 'attribute' => attribute taxonomy ID or '' ), ... ) ) |
_wphub_collections_mode | term | sync, keep_manual or add_only; missing = store default. |
_wphub_collections_auto | product (post meta) | One row per collection the conditions added the product to (the term ID). |
_wxp_term_condition | term | Conditions of version 2.x, read once by the takeover and otherwise left alone. |
Options, transients and scheduled actions
- Settings:
wphub_collections_enabled,_on_categories,_on_tags,_default_mode,_drop_default_cat,_confirm_removals,_rules_column,_product_screen,_log_enabled,_delete_data,_schedule,_batch_size,_include_drafts. - State:
wphub_collections_job(the running or last full check),wphub_collections_lock(one batch at a time; a lock older than two minutes is taken over),wphub_collections_log,wphub_collections_version,wphub_collections_legacy_done,wphub_collections_legacy_copied. - Licence:
_wphub-collections_licence_key,_wphub-collections_key_status; the shared update cachewpxh_licence_check_v2(site transient). - Transients:
wphub_collections_rules_cache(all conditions, 12 hours, cleared on every change),wphub_collections_schedule_checked,wphub_collections_legacy_notice,wphub_collections_notice_<user ID>andwphub_collections_product_notice_<user ID>(messages after saving, 5 and 10 minutes). - Action Scheduler, group
wphub-collections:wphub_collections_check(recurring full check) andwphub_collections_batch(one batch, argument = the run ID). Without Action Scheduler a batch runs as the WP-Cron eventwphub_collections_batch.
WordPress and WooCommerce hooks used
Products: woocommerce_new_product, woocommerce_update_product, woocommerce_new_product_variation, woocommerce_update_product_variation, woocommerce_before_delete_product_variation, woocommerce_product_set_stock, woocommerce_variation_set_stock, woocommerce_before_product_object_save / woocommerce_after_product_object_save, set_object_terms, future_to_publish, pmxi_saved_post (WP All Import), xadapter_product_imported, shutdown. Terms: created_term, edited_term, edit_terms, delete_term, manage_edit-{taxonomy}_columns. Admin: woocommerce_get_settings_pages, admin_enqueue_scripts (handles wphub-collections-admin and wphub-collections-product), admin_notices, admin_init. Compatibility is declared on before_woocommerce_init.
File layout
wphub-collections/
wphub-collections.php engine: conditions, assignment, background checks, log, upgrade
classes/class-wphub-collections-admin.php conditions box, preview, notices, rules column, product screen
classes/class-wphub-collections-settings.php WooCommerce → Settings → Collections
classes/class-wphub-collections-migration.php takeover of version 2.x
view/ add.php edit.php builder.php row.php
assets/js/admin.js assets/js/product.js assets/css/admin.css
licence/class-wpxh-licence-client.php
languages/wphub-collections.pot
uninstall.php readme.txt
Constants: WPHUB_COLLECTIONS_VERSION, WPHUB_COLLECTIONS_FILE. Main object: wphub_collections() (class WPHub_Collections).
8. Privacy
What is stored
Conditions and settings, which products the conditions added, and the activity log (time, product ID and name, term, change, reason, trigger). No customer data and no data about the admin who made a change; the short messages after saving are stored per user ID for a few minutes. Nothing is shown on the shop front.
Data sent to wpexpertshub.com
Only the licence and update client contacts wpexpertshub.com: your licence key, the site address and the plugin version, when you activate or deactivate a licence and when WordPress checks for updates (cached for 12 hours). No product or customer data leaves your site.
What deactivation and uninstall remove
- Deactivation: the scheduled actions. Everything else stays.
- Uninstall (delete), always: the scheduled actions, the job state and lock, and the temporary transients, on every site of a network.
- Uninstall with "When the plugin is deleted: also delete…" ticked: also every
wphub_collections_*option (settings, log, version), the licence options, the conditions and settings of all collections (also the conditions of version 2.x) and the "added by the conditions" marks. - Never: categories, tags, products or their assignments.
9. Troubleshooting
- After updating from 2.x the plugin is switched off and WordPress says "Plugin file does not exist": expected after "Update now" on version 2.x. Go to Plugins and click Activate under Collection for WooCommerce; see Updating from version 2.x.
- A product did not join a collection: look at the Collection rules column (a dash means no valid condition) and at the activity log. Common causes: an empty value, an Attribute condition without an attribute, All conditions with one that cannot match, a name that differs from the typed value, an Inventory condition on a product that does not manage stock, another Polylang language, a draft (see Draft products), or Automatic assignment switched off. Use Preview matching products, then Re-check all products now.
- A category I ticked by hand disappeared from a product: the category is a collection set to "Remove it, also when it was added by hand" and the product does not match. Choose "Remove it only if the conditions added it", or remove the conditions.
- Products never leave a collection: its setting is "Keep it", the store default is, or a filter on
wphub_collections_mode(or the 2.xmerge_collection_categories) returns add_only. - The Collection conditions box is missing: conditions are switched off for that type in the settings, WooCommerce is not active, or your user cannot manage product terms.
- The panel says "Checking your products" for a long time: open Tools → Scheduled Actions and look for pending
wphub_collections_batchactions. If they stay pending, WP-Cron or Action Scheduler is not running on the site. After 15 minutes without progress the panel offers Re-check all products now again. - The preview shows another number than the collection ends up with: a product changed in between, or the collection's setting keeps products that do not match; the preview counts them as kept.
10. FAQ
Will the plugin remove categories I assigned by hand?
Only categories and tags that have conditions are managed. With "Remove it, also when it was added by hand" a product you put into a smart collection by hand is taken out again when it does not match; choose "Remove it only if the conditions added it" or "Keep it" to keep it.
How do I know what will be removed before I save?
The notice next to the conditions explains the setting, the check before saving lists the products a change would remove, and Preview matching products shows the numbers at any time.
What happens to products that were in a category before I added conditions?
With "Remove it, also when it was added by hand" they stay only if they match. With the other two settings they always stay.
Can I make tags smart too?
Yes, on Products → Tags, and categories and tags can use each other.
Can I pause the plugin during an import?
Yes: untick Automatic assignment. Nothing is changed and the conditions are kept; all products are checked when you switch it on again.
Which products match an Inventory condition?
Products that manage stock. Use Stock status for the others.
Does it work with Polylang?
Yes: every language has its own collections and a product only joins collections of its own language.
My store has thousands of products. Is the check slow?
It runs in the background in small, time-boxed batches, one at a time, and never blocks a page. Tune the batch size and the schedule under Background checks.
What is removed when I delete the plugin?
By default only its scheduled jobs and temporary data, so a reinstall keeps your collections. See What deactivation and uninstall remove.
11. Changelog
3.0.0 (13 October 2026)
- New: plugin folder, text domain and code renamed to
wphub-collections. Version 3 takes over the conditions, licence and settings of version 2.x, deactivates the old plugin and says it can be deleted; after an "Update now" of version 2.x the takeover happens when you activate version 3. The old hooks keep working (deprecated). - New: per collection, "When a product does not match": remove it, remove it only if the conditions added it, or keep it. The plugin remembers which products the conditions added.
- New: a notice next to the conditions, and the check before saving with Save and remove them / Keep the products added by hand / Cancel.
- New: smart tags.
- New: WooCommerce → Settings → Collections (pause, categories/tags, store default, Uncategorized, check before saving, rules column, product screen, log, schedule, batch size, drafts, data on uninstall).
- New: activity log; Smart marks and a notice on the product edit screen.
- Fix: the preview ignored other collections named in a condition and the Polylang language rule; Inventory used stock numbers while stock management was off store-wide; conditions on unavailable values were dropped (the collection widened); conditions saved during a running check could be overwritten; saving only invalid conditions removed all conditions; a stopped check could not be restarted; scheduled products published by WP-Cron were checked late; saving needs the plugin's own nonce.
- Tweak: uninstall keeps the conditions unless you choose otherwise; the licence client loads only in the admin, cron and WP-CLI; tested with WordPress 7.1 and WooCommerce 11.2.
2.5.0 (6 October 2026)
- Polylang fixes (rules cache, rules applied to every language, default category of the language), Inventory without stock management, chains of collections, a more robust background check, validation of values, renamed and deleted terms, terms set by other code, new fields (short description, SKU, price, on sale, stock status, product type), Preview matching products and the status panel.
2.4.0 (27 September 2026)
- New licence client; "contains" conditions, manual categories, Quick Edit and stock changes fixed; renamed to Collection for WooCommerce.
12. Support
Email support@wpexpertshub.com. Please include:
- Your order ID.
- The plugin version (this page describes 3.0.0), your WordPress, WooCommerce and PHP versions, and your Polylang version if you use it.
- The collection's conditions and setting (a screenshot of the Collection conditions box helps) and the name of a product that does not behave as expected.
- The matching lines of the activity log and the text of the status panel.
More plugins and documentation are at wpexpertshub.com.