By default, very few users are allowed to access the WooCommerce admin area.
WooCommerce stores can contain a lot of sensitive information, so only users who have the “Administrator” or “Shop Manager” roles can access the WooCommerce admin.
Both “Administrator” or “Shop Manager” users can access the entire WooCommerce admin. There is no middle ground where users can access only some WooCommerce features.
In this guide, I'll show you how to customize access to the WooCommerce Products area. This will allow some users to login to the “Products” area and manage products.
We're going to use the PublishPress Capabilities plugin.
Accessing WooCommerce Products #
Once you have the PublishPress Capabilities plugin installed on your site, go to “Capabilities”.
In the left corner, choose the role you want to give “Products” access. In this example, I'm choosing the “Editor” role:
- Check the edit_product
- Click “Save Changes”.
- When your “Editor” user logs into WordPress, they can now see an “Products” menu link.
Editing WooCommerce Products #
At this point, the “Editor” user can create new products. However, they can not edit existing products, unless they created the product themselves.
If you want to allow Editors to update orders, go back to “Capabilities” and give them the “Edit Others” permission for “Products”:
Deleting WooCommerce Products #
If you want to allow users to delete WooCommerce products, check these boxes in the “Capabilities” area:
These settings will allow the user to move orders to the trash. Here's the “Move to trash” link they will send when editing an order.
Creating WooCommerce Products #
“Create posts” is a WordPress permission that we covered in detail in this blog post.
By default, the “Edit” permission in WordPress covers both editing and creating. This “Edit” permission allowed users to create and edit blog posts.
But what happens if you want some users to edit products, but not create them?
That’s where this permission is useful.
- Look for the “Unique Capabilities for Post Types” box in the right sidebar.
- Check the “Products” box
- Check the “Use create_posts capability” box.
- Click “Update”.
Now in the center of the screen, you can check the “Create” box for products. In the example shown below, users can create new products, but not edit any existing products.