Magento Product Catalogue: The Masterclass (Step 2)

Step 2 of 6: Attribute Sets - The second post in a series to help guide you through adding your entire product catalogue into the Magento CMS, one concept at a time. This article covers product attribute sets - what they are and how to create them.
Published on Jan 9 2015 by Marco Rosano

One step at a time is the best way to walk.

In this series, I will attempt to tell you everything you need to know to understand the terms and concepts behind how Magento will store and manage your product catalogue, and the way that we've found works the best for our clients to get everything working in the best way possible.

Doing the product import right the first time has been a rare unicorn in our experience, so we've created this process to eliminate forgotten steps, and make sure you've thought about everything you need to before you're too far in and don't want to have to start over. Let the clouds of confusion disperse …

See step 1 of this process (Product Attributes) for more information on how to get started.

Here's a typical outline of the process that we follow for importing products into a Magento website:

  1. Product Attributes

    Prepare a list of product attributes that need to be added to the site, with which attribute set each product needs to be added to.
  2. Product Attribute Sets

    Prepare a list of product attribute sets that need to be added to the site.
  3. Product Categories

    Prepare a list of product categories that products will be allocated into.
  4. Product Data Fields (Simple Products)

    Insert all your product data into an import spreadsheet to include all information required for the products, for example, name, description, price, etc.
  5. Product Data Fields (Configurable Products)

    Create configurable products for all products that have options (an example with clothing would be a S/M/L size attribute, or a furniture product could have stainless steel/black for a material attribute), and link each configurable product with all associated (child, simple) products.
  6. Product Images

    Upload product images for all products, associate them with the correct products.

This article covers step 2 - product attribute sets.

The Concept

An attribute set is a collection of attributes, that are designed to accommodate different kinds of products. For example, a piece of clothing could have an additional ‘size' attribute, but an oven might not have size, but ‘material' instead.

All attribute sets must contain all of Magento's system attributes (Name, Price, etc), but you can customise an attribute set to include different combinations of other attributes. You can also organise and sort the attributes into a way that makes it easier to manage your products.

Only attribute sets (not individual attributes) can be assigned to a product. If you want to add a small number of attributes, you can add them to the Default attribute set, however if you want to add attributes that will be applied only to a subset of products, it is advisable to create an attribute set for each set of attributes that you want to assign to products. If you add all your attributes to the Default attribute set, then creating a new product will require you to go through every attribute you've ever added to find the one you want to set. Less is more.

The attribute set of a product is specified when creating a new product, so that means that when creating any new product, we are asked to chose which attribute set to use (e.g. Oven) - you can only chose one - which will then add the additional attributes that are relevant to that product (burners, shelves, material, capacity, etc).

Note: Attributes can belong to more than one attribute set. So ‘Size' could belong in ‘Clothing' and ‘Ovens':

e.g. Size could have values of:

  • Size
    • Small
    • Medium
    • Large
    • 12L
    • 15L
    • 20L

All you really need to remember is which extra fields you want to have available for different types/kinds of products.

How Attributes Work

The point of the attribute sets it so only show the relevant attributes when you're setting up a product, rather than every attribute you've ever added. So it's a way of just making things easier. Attribute sets have a name, a list of attributes which belong to the set, and attribute groups.

Attribute Name

This is what is displayed in a drop-down when creating a new product, allowing you to select the correct group of attributes to add to your product. When deciding on the name for your attribute set, choose something that is meaningful to you - your customers won't see the attribute name.

Attributes List

This is a complete list of all attributes that the attribute set will make available for the product you are creating. You will need to keep all Magento system attributes in your set, but you can re-arrange them into different groups. You can also add additional attributes to the set which are relevant to the specific product type that the attribute set will apply to.

Attribute Groups

These can be thought of as folders that contain attributes. Each group corresponds to a different tab on the product page (the page you see when creating a new product) in the backend. Magento CE comes with six attribute groups by default: General, Prices, Meta Information, Images, Recurring Profiles, Design, and Gift Options. They contain the various system attributes. You can add attributes to these existing groups if it makes sense for your new attributes, otherwise you can create your own groups that make more sense for your attributes.

Your list of attribute sets won't exactly match your list of categories, it's more a product ‘type'. If you had a clothing store, the ‘Neck Size' attribute would be used in jumpers, t-shirts, shirts, etc - so you'd only have one attribute set called ‘tops', rather than an attribute set for each category (jumpers, t-shirts, shirts, etc) that has the same set of attributes in each set. You don't want to have extra attribute sets just for the sake of it. You may actually find that your attribute sets match your categories exactly, however this is not normally the case.

What You Need to Prepare

And an attributes sets list which has a list of sets, and which attributes belong to each set, e.g.:

  • Oven
    • Burners
    • Shelves
    • Exterior Finish
    • Size
  • Clothing
    • Size
    • Colour

Add the Attribute Sets in Magento

Once you have your complete list of all attribute sets, you can login to your Magento backend and start adding in your attributes and their values.

In the Admin Panel, select Catalog > Attributes > Manage Attribute Sets. A list of existing attribute sets is displayed.

Attribute Sets - Manage

Note: The Default attribute set is composed mostly of system attributes. This attribute set is typically inherited by all other attribute sets.

  1. Click the Add New Set button to display the Add New Attribute Set page.
    Attribute Sets - Add New

  2. In the Name field, specify the name of this attribute set. This name is used only in the backend.

  3. In the Based On field, select another attribute set from which this attribute set is to inherit. This enables you to reuse the attributes that are already defined in a set to build other attribute sets. The simple option is to leave the Default option that appears in this field.
    Click Save Attribute Set to display the Edit Attribute Set page:
    Attribute sets - Edit Set
    The top left of the page shows the name of the attribute set that you are defining. The centre of the page shows a hierarchical tree representing groups of attributes. An attribute group is a logical grouping of attributes within an attribute set.
    The right side of the page shows a list of attributes defined in other attribute sets and not assigned to this attribute set.

  4. Assign attributes to this attribute set by dragging them from the Unassigned Attributes area on the right into a group in the tree in the Groups area.

Creating a New Attribute Group

The centre of the Edit Attribute Set page shows a hierarchical tree representing groups of attributes.

Attribute Sets - Edit Set

Attribute groups can be thought of as folders that contain attributes. Each group corresponds to a different tab on the product page in the backend. Magento CE comes with six attribute groups by default: General, Prices, Meta Information, Images, Recurring Profiles, Design, and Gift Options. They contain the various system attributes. System attributes cannot be removed from an attribute set; however, they can be moved to other attribute groups. Therefore, you can remove an attribute group as long as there are no system attributes within it. The order of both the attribute groups and the attributes can be changed by selecting and dragging them. This affects the order of tabs and attributes on the product page in the backend, respectively. You can also create a new attribute group, to which you can move system attributes, or associate simple attributes.

Attribute Sets - Groups

To create a new attribute group:

  1. Click Add New in the Groups area to display a popup window asking for the group name.

  2. Specify the name of the new group and click OK.

  3. Click and drag attributes from the Unassigned Attributes area into the newly created group to assign them to this group.

  4. You can also click and drag attributes that are already assigned to move them between groups.

Repeat this process for each of your new attribute sets that you need to create.

Once you're done, you're ready to start setting up your categories, which you can read all about in the next article.

Free advice from an agency?

We specialise in online store development, and have many years and many online stores' worth of experience in what works and what doesn't. We've used many platforms and have put them all through their paces - and our favourite at the moment is Magento for is flexibility, expandability, and huge community of developers who actively develop the platform and are continually improving it.

We're writing this series for the benefit of the Magento user community, as the open-source movement has given so much to the web industry, we want to give back. We know what we're doing, and want to share some of that knowledge with you for the benefit of everyone.