In Magento, is there a way to remove attribute from configurable product after already created?

In Magento, I have have a bunch of configurable products already created and now have a client that has changed their mind and wants to remove one of the attributes. I’m having a hard time figuring out how to do this b/c I keep getting an error message saying:

This attribute is used in configurable
products. You cannot remove it from
the attribute set.

I have tried going into the attribute and changing Use to Create Configurable Product from “yes” to “no”, but that didn’t seem to do anything when trying to remove attribute from existing products

6 thoughts on “In Magento, is there a way to remove attribute from configurable product after already created?”

  1. To remove one super product attribute (as they are called) from all configurable products, you could execute this SQL query in the database:

    DELETE FROM catalog_product_super_attribute
    WHERE attribute_id = <id>

    The table catalog_product_super_attribute links products to super product attributes. You can add and remove attributes to created configurable products there.

  2. It seems like you’re trying to remove the attribute from the attribute set first, but you need to remove it from the configurable products, then the attribute set. Open each configurable product, go to the Associated Products tab and remove the attribute (and linked products) that is not required. Save each product and then try removing the attribute from the set.

  3. Unfortunately, this is not possible from the standard Magento backend.
    As such, you have to look at SQL solutions (I’m not familair with these).

  4. Building on Christian Davén’s answer, you could use the following to delete based on the attribute_code name instead of the attribute_id itself, just to be sure that you are referencing the right ID:

    DELETE FROM `catalog_product_super_attribute`
    WHERE `attribute_id` IN (
        SELECT `attribute_id` FROM `eav_attribute`
        WHERE `attribute_code` = "attribute"

Leave a Reply

Your email address will not be published. Required fields are marked *