I created a custom tab extending catalog_product_view.xml and now I don't know how to order my custom tab, it's displayed the first by default. I want to be displayed after the "Details" tab for example but it's not working the after neither before instructions.

<?xml version="1.0"?>
<page layout="1column" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        <referenceBlock name="product.info.details">
            <block class="Magento\Catalog\Block\Product\View" name="custom.tab" as="custom"
                   template="Vendor_Module::product/custom.phtml" group="detailed_info" after="product.info.description">
                    <argument translate="true" name="title" xsi:type="string">Custom tab</argument>

What am I doing wrong? The "Details" tab is named product.info.description right?

I found some solutions, but all consist rewriting all tabs and ordering as you want, but I think it has to be better solutions because rewriting the structure, what will happen if another extension does the same?

3 Answers 3


You can call your block first like this

<block class="Magento\Catalog\Block\Product\View" name="custom.tab" as="custom" template="Vendor_Module::product/custom.phtml" group="detailed_info">
                <argument translate="true" name="title" xsi:type="string">Custom tab</argument>

and then move the same like this

<move element="custom.tab" destination="product.info.details" after="product.info.description" />

For Change position of Tabbing in details page, Using xml configuration file after or before attribute not help in this case.

You can see more information from here : Change order of Tabs on product page


Magento 2 does not provide any sort order for tab, you can achieve using sequence tag into module.xml file.

    <module name="Magento_Review" />

After that you need to run setup:upgrade command

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.