Remove tax from the invoice pdf

Remove tax from the invoice pdf

August 5, 2026 · Illustrated author avatarBy Stefan Bogdanescu
Remove tax from the invoice pdf

Removing Tax Line from Invoice PDF in Magento: A Comprehensive Guide

You’re not alone if you’ve spent hours trying to remove that pesky “Tax:” line from your Magento sales invoice PDF without much success. Let’s dive into why this is harder than it seems and how to finally get rid of it.

The Core Issue

The tax line appears due to the way Magento’s core PDF invoicing system is structured. It uses a predefined list of totals that includes the ‘tax_amount’. This total is always displayed, even if there’s no tax on the order.

When you try to simply remove or skip the tax item in your overridden method (_getTotalsList), it doesn’t work as expected because the system has already processed and set up the PDF layout before reaching this point. By the time your override runs, the damage is already done—the tax line is already included in the PDF template.

The Right Approach

To fix this issue, we need to tackle it from a different angle: customizing the PDF template directly. Here’s a step-by-step guide:

1. Create a Custom PDF Model

First, create your own invoice PDF model that extends the default one (Mage_Sales_Model_Order_Pdf_Abstract). In this new class, you’ll override the _getTotalsList method to exclude tax totals.

class MyCompany_Taxy_Block_Invoice_Pdf_Model extends Mage_Sales_Model_Order_Pdf_Abstract
{
    //... other methods

    protected function _getTotalsList($source)
    {
        // Your code to remove tax...
    }
}

2. Modify the PDF Layout

Next, you need to modify the layout of the invoice PDF template file located under app/design/frontend/{theme}/{package}/template/sales/order/creditmemo/pdf/invoice.phtml.

Look for the line that corresponds to the total amount and adjust it to exclude tax.

<td style="text-align: right; padding-right: 20px;" width="60%"> <?php echo $this->getTotalAmountLabel(); ?> </td>

3. Update the Invoice PDF Model Configuration

Finally, update your config XML file (usually located under app/code/local/Your_Company/Your_Module/etc/config.xml) to tie your new PDF model to the sales invoice:

<default>
    <global>
        <sales>
            <order_pdf_model>yourcompany_taxy/model_invoice_pdf</order_pdf_model>
        </sales>
    </global>
</default>

Conclusion

Removing a simple line like “Tax:” from the Magento invoice PDF can indeed be a challenging task. However, by understanding the core issue and following the approach outlined above—creating a custom PDF model, modifying the template file directly, and updating the configuration—the solution becomes clear.

Remember to thoroughly test your changes after each step, as working with Magento’s PDF invoicing system often requires meticulous attention to detail.

For more advanced customizations and tips on working with Magento PDF templates, feel free to explore our guides at Laravel Company.

Happy coding!

Themes Orders Pricing Errors

Our network