Magento PDF Invoices - how do I get custom product options to be on one line?

Magento PDF Invoices - how do I get custom product options to be on one line?

October 17, 2026 · Illustrated author avatarBy Stefan Bogdanescu
Magento PDF Invoices - how do I get custom product options to be on one line?

Optimizing Magento PDF Invoices: Consolidating Custom Product Options

As an e-commerce store owner or developer, you’re likely aware of the importance of professional-looking invoices for building customer trust and satisfaction. However, dealing with custom product options in Magento can lead to significant paper waste on your PDF documents.

By default, Magento lists each configurable option separately under the corresponding simple products. If your customers frequently purchase fully configured items, this layout results in invoices that are half empty, wasting resources and damaging your sustainability image.

The Challenge: Multiple Line Items Per Product

Consider a scenario where you sell customizable t-shirts with numerous color, size, print style options. Each combination is treated as a separate line item by Magento’s default PDF generation process. For instance:

  • Print Style 1: White
    • Size L
      • Color Red
        • Quantity 1

This results in a highly fragmented invoice that fails to provide an easy-to-read overview of the order contents.

The Solution: Consolidating Options into Blocks

To tackle this issue, we can employ custom templates and extensions to merge the configurable options into a single block for each product. This approach significantly reduces the length of your PDF documents while still providing all necessary information.

There are several methods to achieve this:

  1. Custom Magento Extension One efficient way is to develop a custom extension that modifies the PDF generation process. You can use Magento’s template system and override the relevant layout XML files to customize how options are rendered on the invoice.

    Here’s an example of how you might structure your custom layout XML file:

    <reference name="pdf_invoice">
        <action method="setOptionRenderers">
            <argument index="0" translatable="false">custom_option_renderer</argument>
            <argument index="1" xsi:type="array">
                <item index="0">customer_option</item>
                <item index="1">product_option</item>
                <item index="2">row_total</item>
            </argument>
        </action>
    </reference>
    

    In this example, we’re replacing the default option renderers with our own custom logic.

  2. Innobyte’s One Line Invoice Extension A commercial alternative is Innobyte’s One Line Invoice extension, which offers a user-friendly interface for managing your PDF templates and merging options into single lines.

    This extension seamlessly integrates with Magento 2 and provides pre-built layouts that you can customize to match your branding. It supports various document types, including invoices, shipments, credit memos, and packing slips.

Implementing the One Line Invoice Extension

To get started with Innobyte’s solution, follow these steps:

  1. Purchase and download the extension from their official website: https://innobyte.com/magento-one-line-invoice.html

  2. Upload the extension to your Magento 2 installation using the “Upload” or “System > Configuration” method.

  3. Enable the module in your Magento admin panel by navigating to “Stores > Configuration > Sales > PDF Documents.”

  4. Customize the templates and styles to match your brand identity, and ensure that options are merged into single lines for each product.

Conclusion: Streamline Your PDF Invoices

By consolidating custom product options into a single block on your Magento PDF invoices, you can significantly improve the readability of your documents while reducing paper waste. Whether you choose to develop a custom extension or opt for a ready-made solution like Innobyte’s One Line Invoice, this approach will enhance your customers’ experience and contribute to a more sustainable e-commerce operation.

Remember that proper template design is crucial for maintaining a professional appearance, so take the time to customize your layouts and styles. With these improvements in place, you’ll be well on your way to delivering invoices that are both functional and visually appealing.

For more tips on optimizing Magento PDF documents and other e-commerce best practices, visit Laravel Company for insights from our team of experienced developers and technical bloggers.

Catalog Performance Extensions Themes

Our network