How To Create Magento 2 Attributes?

N

Nilesh-Kothari

In Magento 2, attributes means the property/characteristic of a product, useful for the function of the e-commerce website.

Attributes can be used as search parameters and product comparisons. The set or group of these properties is known as the Attributes set.

In order to divide the different products into groups, every product must be associated with a respective attribute set.

I want to know how to create Magento 2 Attributes.

Thanks
 
Last edited by a moderator:

EddyRock

Free Member
Jul 23, 2019
35
5
In the admin panel, go to Stores > Attributes > Product. Click Add New Attribute. You will be redirect to attribute edit page.
Fill all necessary information: Label, Option Values. Then click on Storefront Properties tab. Make sure you set this values to YES:
- Visible in Advanced Search
- Comparable on Storefront

Go to Stores > Attributes > Attribute Set. Add more attribute sets here. In the attribute set edit page, drag and drop your attributes into appropriate groups.

That's all.
 
Upvote 0

crackerjackcommerce

Free Member
Aug 1, 2019
96
6
Hi, we use one attribute set (default).

We created each attribute we wanted in Stores>Attributes>Product.

Then from memory we created a new Group inside the default attribute set and then dragged and dropped our previously created attributes into the newly created group.

You can then view and populate these from the edit item page.

Rich
 
Upvote 0

David-Max

Free Member
Oct 16, 2019
18
1
On the Admin panel, click Stores. In the Attributes section, select Product

Click Add New Attribute button

In the Attribute Properties section, do the following
  • In the Default Label, enter a default label to indentify the attribute
  • In the Catalog Input Type for Store Owner field, select the type in input control to be used for data entry
Under Manage Options section, click Add Option button

Open the Storefront Properties section, do the following
  • In the Use in Search field, set to Yes if the attribute is to be available for search
  • In the Comparable on Storefront field, set to Yes to include the attribute in Product Compare
  • In the Use in Layered navigation field, set to Yes if you want to use the attribute as a filter in layered navigation
  • In the Use in Search Results Layered Navigation field, set to Yes if you want to use the attribute in layered navigation on search results pages
  • In the Position field, enter a number to indicate the relative position of the attribute in the layered navigation block
  • In the Use for Promo Rule Conditions field, set to Yes to use the attribute in price rules
  • In the Allow HTML Tags on Frontend field, set to Yes to allow the text to be formatted with HTML
  • In the Visible on Catalog Pages on Storefront field, set to Yes to include the attribute in catalog page listings
  • In the Used in Product Listing field, set to Yes to include the attribute in product listings
  • In the Used for Sorting in Product Listing field, set to Yes to use attribute as a sort parameter for product listings
  • When complete, click Save Attribute button.
 
Upvote 0

Latest Articles