How to remove block from magento left panel?

How to remove block from magento left panel?

September 23, 2026 · Illustrated author avatarBy Stefan Bogdanescu
How to remove block from magento left panel?

Removing Magento Blocks from Left Panel Using XML

As a senior developer working on Magento projects, I often encounter situations where clients need to customize the layout of specific pages. One common request is to remove certain blocks from the left panel on a particular page.

In your case, you’ve already changed the layout file for the customer registration page from 1column.phtml to 2columns-left.phtml. This means that by default, Magento will display two columns—the main content area and the left sidebar containing various blocks.

To remove specific blocks from this left panel, you’ll need to modify the XML layout definition. In your question, you mentioned editing the customer.xml file. However, for a more targeted approach, let’s focus on the template/column/left.phtml file instead, which is responsible for rendering the content of the left sidebar.

First, locate the Magento root directory and navigate to the following path: app/design/frontend/[Your_Theme]/[Your_Version]/template/column.

Here, you’ll find the left.phtml file. Open this file in your preferred code editor or IDE.

The left.phtml file contains PHP code that fetches blocks from Magento’s layout definition and renders them. To remove a specific block, you need to identify its unique identifier (block ID) within the Magento configuration files.

In your case, let’s assume you want to remove a block with an ID of block.cms.left.column. You would find this block in the app/code/core/Mage/Cms/etc/layout.xml file under the <layout> tag:

<block type="cms/block" name="block.cms.left.column">
    <action method="setBlockId"><block_id>block_cms_left_column</block_id></action>
    <action method="setTemplate"><template>cms/block.phtml</template></action>
</block>

To remove this block from the left sidebar of your customer registration page, you would need to add a new <remove> tag in the local.xml file located at: app/code/local/[Your_Company]/[Your_Module]/etc/layout.xml.

The content of the local.xml file might look something like this:

<layout version="1.0">
  <customer_account_create translate="label">
    <remove name="block.cms.left.column" />
  </customer_account_create>
</layout>

In this example, we’ve added a <remove> tag with the name attribute set to "block.cms.left.column". This tells Magento not to include this block in the layout of the customer registration page.

Remember that modifying core files directly is generally discouraged. To avoid losing your changes during updates, you can create an extension and override the necessary XML files there. For more information on creating extensions, refer to the official Magento documentation: https://laravelcompany.com/magento/extension-creation.

Another approach would be to use a layout update plugin or a custom layout file. This involves writing your own PHP code that modifies the layout during runtime based on certain conditions.

For instance, you can create a custom module with a layout update plugin that removes specific blocks only from the customer registration page and leaves them intact for other pages:

public function aroundGetLayoutUpdates($subject, $proceed)
{
    if ($subject->getPage()->getIdentities()->hasIdentify('customer_account_create')) {
        return ['remove' => 'block.cms.left.column'];
    }

    return $proceed();
}

This plugin checks for the customer_account_create identifier and returns a layout update instruction to remove the block.

In conclusion, removing blocks from Magento’s left panel involves understanding how layouts work in Magento and having a clear strategy for managing your customizations. Whether you choose to override XML files directly or create an extension with layout modifications depends on your specific project requirements and long-term maintenance goals.

For more advanced layout customization techniques and best practices, I recommend exploring the following resources:

Themes Configuration Customers CLI

Our network