WooCommerce Brands allows you to create brands for your shop, with a name, description and image assigned to each.
Installation ↑ Back to top
- Download the .zip file from your WooCommerce.com account.
- Go to: WordPress Admin > Plugins > Add New and Upload Plugin with the file you downloaded with Choose File.
- Install Now and Activate the extension.
More information at: Install and Activate Plugins/Extensions.
Setup and Configuration ↑ Back to top
Creating brands ↑ Back to top
To start adding brands:
- Go to: WooCommerce > Products > Brands. The interface looks and works similar to adding categories and tags — the form on the left lets you add a brand, which are then displayed on the right.
- Enter a Name and Description. Image is optional. Brands can be hierarchical, specifying a ‘parent’ with ‘child’ brands under it.
- Select Add New Brand to save.
Editing and deleting brands ↑ Back to top
Modify Brands by hovering over the Name and click Edit or Delete. Brands may also be re-ordered by dragging and dropping.
Assigning a brand to a product ↑ Back to top
Assigning brands to products is the same process as adding categories and tags.
- Go to: WooCommerce > Products.
- Select a product to assign a brand.
- Find the Brands box in the right sidebar.
- Tick the box of brands you wish to assign to the product.
- Update or Publish to save changes.
Shortcode Reference ↑ Back to top
To display the brands, you can use Shortcodes. Shortcodes are ways to call in complicated code, giving you many options with only a few keystrokes.
To use a shortcode, copy the text starting with “[” and ending with “]”, then paste into your editor. As an example,
[product_brand] shows a brand’s image on the single product page.
Available Shortcodes ↑ Back to top
Shows a single brand’s image with a link to its archive page. This only works on single product pages, not on posts or other WordPress pages. Note that showing brands on the single page with this shortcode will only pull 1 brand and not all.
array( 'width' => '64px', 'height' => '64px', 'class' => 'aligncenter' )
Show all products in a certain brand.
array( 'per_page' => '12', 'columns' => '4', 'orderby' => 'title', 'order' => 'asc', 'category' => 'boots,sandals', )
[brand_products brand="hiro-shoes" per_page="12" columns="4"]
Product Brand List
Shows an A-Z index of all brands with links to their archive pages.
array( 'show_top_links' => 'true', 'show_empty_brands' => 'false' )
Product Brand Thumbnails
Shows a list of all product brand thumbnails with links to their archives.
array( 'columns' => '12', 'show_empty' => 'true', 'orderby' => 'name', 'exclude' => '2,5,8', // Category IDs to exclude 'number' => '' // Number of brands to show. )
[product_brand_thumbnails number="12" show_empty="false"]
Advanced Usage ↑ Back to top
To get the shortcode to display on multiple product pages, you would want to add it into a template or onto a hook using the do_shortcode function, as seen here:
echo do_shortcode('[product_brand width="64px" height="64px" class="alignright"]')
Adding a Brand Image to the Product Page ↑ Back to top
In some situations, you may want to display the brand image associated with the product in your product page, as shown below:
There are two ways to implement this, either on a single product basis or applying to all products.
To apply to a Single Product
In the product’s body area, you can add the shortcode
[product_brand width="64px" height="64px" class="alignright"]
In that example, it would link to the brand of the product, establish the width and height in pixels (each 64), and align it to the right side. The ‘class’ field isn’t required – it’s by default set to ‘aligncenter’, but you can do left or right as well.
To apply to All Products
First, ensure that you’re making edits in a child theme.
This allows you to customize content without the risk of an update removing your work. To learn more about how to customize a child theme, visit our child theme tutorial, or read more about how child themes at the WordPress Codex.
In your child theme, go to the functions.php file and add the following snippet:
You can also add in this snippet using a plugin like Code Snippets.
This gives us the following logo positioning, which is displayed on all product pages and changes dynamically to fit the brand:
Widgets ↑ Back to top
To learn more about how to add the Brands Widgets listed below to your site, you can refer Widgets included with WooCommerce.
Brand Description ↑ Back to top
This widget shows the description for the currently viewed brand archive.
Brand Nav ↑ Back to top
This widget provides layered navigation for products based on brand. This widget works together with other layered-navigation WooCommerce widgets and can be used accordingly.
Brand Thumbnails ↑ Back to top
This widget lists brands with thumbnails.
REST API Support ↑ Back to top
Version 1.5+ supports the REST API
Frequently Asked Questions ↑ Back to top
How do I order the brands on the front end as showcased on the Admin Panel? ↑ Back to top
In your theme’s
functions.php file, add:
Brand thumbnails will then be organized in the same order that they appear in the backend.
How do I change the slug for brand archives? ↑ Back to top
Each brand has its own archive, viewable at http://domain.com/
brand section of the above URL structure can be adjusted by adding the following snippet to your theme’s
functions.php file, or to your custom functionality plugin:
Go to Settings > Permalinks and re-save after adding the above code snippet. This ensures your permalinks are refreshed and ready to go, using the new brand slug.
How do I display product brands in my product page URLs? ↑ Back to top
To display a product’s brand in the product’s URL, visit Settings > Permalinks and add
%product_brand%, as desired, to your Product Permalink setting. Note:
shop as a base:
How do I import brand information from a CSV file? ↑ Back to top
The product import/export feature built into WooCommerce does not yet have feature parity with the Product CSV Import Suite extension as it currently only handles default fields + meta fields while brands are stored in taxonomies.
As such, the Product CSV Import Suite is the tool for the job. You’ll need to add a column with the heading
tax:product_brand to the CSV file with the brand names in that column so that the brand information is tied to your products.
Questions and Feedback ↑ Back to top
Have a question before you buy? Please fill out this pre-sales form.
Already purchased and need some assistance? Get in touch with a Happiness Engineer via the Help Desk.