How To Fix Missing Wholesale Roles

Unfortunately, we do not have a single specific reason why wholesale roles might disappear.

In many cases, this is related to the use of a third-party user role editing plugin which suddenly removes the wholesale roles in the WooCommerce > Wholesale Roles setting.

Before you proceed: We strongly advise to backup your site and database before doing anything.

There are two ways to fix this issue:

1. Move your current wholesale users temporarily to a certain role using a third party User Role Editor plugin, then delete the wholesale role that was missing. Then re-create it again on WooCommerce > Wholesale Roles and re-apply the newly created role back to your users. This is the safest way to bring back the wholesale role and ideal if you have a few users.

2. If you have a backup of your site where your wholesale roles are still present, go to the Dashboard, then adjust the URL to point to /wp-admin/options.php. Find the wwp_options_registered_custom_roles. This meta key contains serialized data for the wholesale roles that you have. Copy its value from the backup site to the existing site and it should put the missing wholesale roles back.

Remember: editing via the options.php page is risky if modified incorrectly. So if you don’t know what you’re doing here, we suggest you contact a developer.

Frequently Asked Questions

How do I recreate missing wholesale roles in WooCommerce?
Once a wholesale role has disappeared, navigate to WooCommerce > Wholesale Roles and add the entry back manually. Before doing this, temporarily reassign affected buyers to a different group using a user role editor. After the fresh entry is in place, reapply it to those customers. This approach works best for stores with a small number of wholesale accounts.

Can third-party role editor plugins break wholesale roles?
Yes, certain user role editor tools can unexpectedly delete custom wholesale roles from your WooCommerce store. This typically happens when a plugin flushes or overwrites role data stored in the database. To avoid issues, review the tool’s settings before making bulk changes, and keep a full site snapshot handy as a safeguard.

What happens to wholesale customers when their role goes missing?
Generally, buyers assigned to a deleted role lose access to discounted pricing immediately. They may revert to standard retail rates or be blocked from completing orders depending on how your store is configured. Moving them to a temporary group while you reinstate the original entry helps minimise disruption.

Can I restore wholesale role data from a database backup?
Absolutely — if you have a site backup, retrieve the wwp_options_registered_custom_roles value from the options table and paste that serialized string into the matching field on your live installation via /wp-admin/options.php. Because this involves direct database editing, having a developer handle it is strongly advised if you are unfamiliar with raw database values.

Why did my wholesale roles suddenly disappear from WooCommerce?
In most cases, a third-party security or optimization tool triggers the removal by modifying user role data stored in WordPress. Bulk cleanup utilities can wipe custom entries unintentionally. If this keeps recurring, audit your installed extensions, disable any that interact with user permissions, and rebuild the missing role through WooCommerce > Wholesale Roles.

Need Help?

If you have a question or run into any issues, we’re here to help.

Was this article helpful?

Related Articles

Need Support?

Can't find the answer you're looking for?
Contact Support
Complete Your Purchase