Cookies setting

Cookies help us enhance your experience on our site by storing information about your preferences and interactions. You can customize your cookie settings by choosing which cookies to allow. Please note that disabling certain cookies might impact the functionality and features of our services, such as personalized content and suggestions. Cookie Policy

Cookie Policy
Essential cookies

These cookies are strictly necessary for the site to work and may not be disabled.

Information
Always enabled
Advertising cookies

Advertising cookies deliver ads relevant to your interests, limit ad frequency, and measure ad effectiveness.

Information
Analytics cookies

Analytics cookies collect information and report website usage statistics without personally identifying individual visitors to Google.

Information
mageplaza.com

How to change Invoice, Order PDF templates in Magento 2

Vinh Jacker | 01-11-2018

How to change Invoice, Order PDF template - Mageplaza

Your invoices are part of your brand identity, as they continue the conversation with customers even after purchase.

Customizing invoice, order, shipment, or credit memo templates in Magento 2 isn’t straightforward with the default setup. The Mageplaza PDF Invoice extension makes it simple to create and edit professional templates that reflect your brand. In this guide, you’ll learn what a Magento 2 PDF Invoice includes, why it matters, and how to configure and brand your templates effectively.

Changing Invoice, Order Templates in Magento 2

To change Invoice in Magento 2:

Step 1: Add a new Template

This guide is built using the Mageplaza PDF Invoice extension for Magento 2.

From the Admin Panel, go to Mageplaza > PDF Invoice > Manage Templates

How to change Invoice, Order PDF template in Magento 2

Click the Add New Template Order button and choose the kind of template you want to generate. There will be 4 kinds of templates corresponding to 4 kinds of PDF files:

  • Order
  • Invoice
  • Shipment
  • Credit Memo

You’re able to freely design templates in your own style or using available templates in the extension’s configuration.

How to change Invoice in Magento 2

For example, if you choose to create an Order template, the design form will appear like the below image:

How to change Order PDF template in Magento 2

  • In Load default template field:
    • Template
      • You can choose one of the available templates. After having it done, the chosen template will show up right your left side to be previewed.
      • If you don’t choose a template form, the default template will be Template = Template 1.
    • Load Template: The selected template’s code will be displayed automatically in the below HTML box.
  • In Choose column of product list in PDF field: You can select and rearrange columns in the product list table.

How to change Invoice template in Magento 2

  • In Template Information field:
    • Apply Template At: Click the PDF Invoice link to direct to the configuration section.
    • Template Name
      • This is the place where you name your own template.
      • If you leave it blank, there will be an error message.
    • Insert Variables: Choose a variable to display the value of that variable in the PDF file.

How to change Invoice template in Magento 2

Step 2: Custom design & company information

Keep going from Mageplaza > PDF Invoice: Configuration > General Configuration, expand the section

How to change Invoice and Order PDF template in Magento 2

  • Expand Business Information field:
    • In Company Name field:
      • Enter your company/store name, it will be displayed in your PDF invoice.
      • If you leave it blank, the Company Name place won’t have a name.
      • Check Use system value to use it as default.
    • In Logo field:
      • Select your logo file displayed on the PDF file to match the background: Black or White Logo.
      • Only image/video files can be valid; otherwise, there will be an error message.
      • If you leave it blank, the default logo will be displayed.
      • Check Use system value to use it as default.
    • In Logo Width field:
      • Select the size for your logo (pixel)
      • If you leave it blank, the default width is 180px
      • Check Use system value to use 180px as default logo width.
    • In Logo Height field:
      • Select the size for your logo (pixel)
      • If you leave it blank, the default width is 30px
      • Check Use system value to use 30px as default logo width.
    • In Address field:
      • This is the place where you can fill in your company/store’s address, this will be displayed in the PDF invoice file.
      • If you leave it blank, address information won’t be seen.
      • Check Use system value to use it as default.
    • In VAT number field:
      • Enter your company/store’s VAT number to perform it on the PDF file.
      • There won’t be a VAT number displayed if you leave it blank.
      • Check Use system value to use it as default.
    • In Phone field:
      • Enter your company/store’s phone numbers.
      • If you leave it blank, phone numbers won’t be seen.
      • Check Use system value to use it as default.
    • In [Email](https://www.mageplaza.com/magento-2-smtp/) field:
      • Enter your company/store’s official email address.
      • There won’t be an email displayed if you leave it blank.
      • Check Use system value to use it as default.
    • In Registered Number field:
      • Enter your company/store’s business number in this field.
      • If you leave it blank, the PDF invoice file won’t display it.
      • Check Use system value to use it as default.

Step 3: Preview

  • Edit HTML: This section allows you to generate a unique PDF form by your own idea.
  • Preview: After editing the PDF form, click here to have an overview glance again.

How to change Invoice, Order PDF template in Magento 2

  • Link CSS: This will direct you to a detailed CSS support guide on how to learn to design by CSS properly.
  • Link HTML Support: Click it to direct to a detailed HTML support guide that points out what HTML tags you can use to create a template.
  • Template Style: You can add CSS codes here.

How to change Invoice PDF template in Magento 2

Step 4: Print a test Invoice

Let’s print PDF invoice, order, credit memo, shipment. Remember, you can add Barcode or QRcode in the invoices. So you should test these too.

magento 2 pdf invoice

Best practices for Branding your PDF documents: Do & Don’t

These best practices ensure your documents look professional, build trust, and avoid common design mistakes. Below are some quick checklist to keep in mind:

✅ Do:

  • Keep your logo and brand colors subtle and consistent
  • Use clean, professional fonts that match your storefront
  • Add legal info (VAT, tax ID, company reg. no.) in the footer
  • Use tables and spacing for easy-to-read order details.
  • Test on multiple PDF readers (Acrobat, Chrome, Preview).

❌ Don’t:

  • Overload documents with too many colors or images.
  • Use low-resolution or stretched logos.
  • Mix random fonts and styles that reduce professionalism.
  • Hide essential info (order no., tax, billing details).
  • Forget to update templates after branding changes.

Conclusion

Even though creating or editing PDF templates for orders and invoices can be difficult for Magento 2 builders as it requires a lot of technical knowledge, this task seems much simpler with the PDF Invoice extension. With just some drag-and-drop actions or mouse clicks and a variety of example template designs already available, any Magento developer can quickly customize the order/ invoice PDF templates to match their desired branding.

Related topics

x
    Jacker

    Jacker is the Chief Technology Officer (CTO) at Mageplaza, bringing over 10 years of experience in Magento, Shopify, and other eCommerce platforms. With deep technical expertise, he has led numerous successful projects, optimizing and scaling online stores for global brands. Beyond his work in eCommerce development, he is passionate about running and swimming.



    Related Post