---
title: "How to Add Custom Placeholders to WooCommerce Invoices"
description: "Learn how to add custom placeholders to WooCommerce invoices using WebToffee&#039;s WooCommerce PDF Invoices, packing slips, and credit notes plugin."
author: "Sanjai Valsan"
published_date: 2023-09-14
modified_date: 2026-07-12
canonical_url: "https://www.webtoffee.com/docs/pdf-invoices/add-custom-placeholders-woocommerce-invoice-packing-slip/"
source: "https://www.webtoffee.com"
reading_time: 3 min
word_count: 598
categories:
  - "Customization"
  - "Documentation"
  - "WooCommerce PDF Invoices, Packing Slips and Credit Notes Plugin"
---

## Summary

Learn how to add custom placeholders to WooCommerce invoices using WebToffee's WooCommerce PDF Invoices, packing slips, and credit notes plugin.

## Breadcrumb

[Home](https://www.webtoffee.com/) > [Documentation](https://www.webtoffee.com/category/documentation/) > [WooCommerce PDF Invoices, Packing Slips and Credit Notes Plugin](https://www.webtoffee.com/category/documentation/pdf-invoices/) > How to Add Custom Placeholders to WooCommerce Invoices

# How to Add Custom Placeholders to WooCommerce Invoices

*Last updated on July 12, 2026*

The introduction of custom placeholders on WooCommerce invoices, packing slips and credit notes proves to be essential for business communication, branding, and operational efficiency. The default templates may not always include all necessary information relevant to your business or customers, such as custom messages, additional order details, or special handling instructions. With WebToffee’s[WooCommerce PDF Invoices, Packing Slips, and Credit Notes](https://www.webtoffee.com/product/woocommerce-pdf-invoices-packing-slips/) plugin, store owners can dynamically insert personalized data into invoices, packing slips and credit notes enhancing clarity, professionalism, and customer experience. Here are the brief steps in adding custom placeholders:

- Add the custom code snippet to your WordPress site.
- Insert the custom placeholder in the template.
- SaveSettings.

## Prerequisites

- Install and activate the free [WooCommerce PDF Invoices, Packing Slips, Delivery Notes, and Shipping Labels](https://wordpress.org/plugins/print-invoices-packing-slip-labels-for-woocommerce/) plugin.
- [Install and activate](https://www.webtoffee.com/how-to-download-install-update-woocommerce-plugin/?guide=480662) the pro add-on [WooCommerce PDF Invoices, Packing Slips, and Credit Notes](https://www.webtoffee.com/product/woocommerce-pdf-invoices-packing-slips/).

## Step 1: Add the custom code snippet

The first step is to add the custom code snippet to your WordPress site.

Before adding the code, ensure you update the custom code snippet by replacing ‘_metakey1’and ‘_metakey2’ with the appropriate meta keys for the data you want to display on the document.

You can add the snippet to the active child theme’s functions.php file or use a third-party plugin. To learn more about adding a custom code snippet using a third-party plugin, refer to this article:[Adding Custom Codes Using Third-Party Plugins](https://www.webtoffee.com/docs/how-tos/add-custom-code-snippets-third-party-plugins/).

Note: To add custom placeholders to packing slips, credit notes and delivery notes, update ($template_type==’invoice’) in the code to ($template_type==’packinglist’) for packing slips or ('creditnote' === $template_type) for credit notes or ($template_type==’deliverynote’) for delivery notes.

## Step 2: Add the custom placeholders to the template

After adding the custom code snippet, next step is to insert the custom placeholder in the document template.

- First, copy the two placeholders [wfte_custommeta1] and [wfte_custommeta2] from the custom code snippet.
- Navigate to Invoice/Packing > Invoice (Packing slip or credit note) > Customize from the WordPress dashboard.
- Scroll down and click on the Code editor.

![Code editor - WooCommerce invoice, packing slip and credit note](https://www.webtoffee.com/wp-content/uploads/2023/09/code-editor--1024x437.jpg)
*caption: Code editor – WooCommerce invoice, packing slip and credit note*

- Paste the placeholders into the template code editor. Their placement within the editor will determine their position in the final document.

![Custom placeholders in WooCommerce invoice](https://www.webtoffee.com/wp-content/uploads/2023/09/custom-placeholder-added-invoice-998x1024.jpg)
*caption: Custom placeholders in WooCommerce invoice*

### Step 3: Save Settings

- Click on Update Template to save the changes.

## Example

Let’s take an example where we add two custom meta fields – Shipping City and Order Currency—to WooCommerce invoices, packing slips, and credit notes. In the custom code, the meta keys _metakey1 and _metakey2 will be replaced with _shipping_city and _order_currency, respectively. These placeholders will then be inserted into the code editor of invoices, packing slips, and credit notes. The placeholders are positioned right below the “From Address” placeholder in the document. The meta fields will appear in WooCommerce invoices, packing slips and credit notes as shown below:

![Custom meta data - WooCommerce invoice](https://www.webtoffee.com/wp-content/uploads/2023/09/invoice-with-custom-metadata-979x1024.jpg)
*caption: Custom meta data – WooCommerce invoice*

In conclusion, adding custom placeholders to WooCommerce invoices, packing slips, and credit notes enables businesses to include tailored information that improves communication, branding, and efficiency. With WebToffee’s plugin, store owners can easily integrate dynamic data through simple code and template customization, resulting in more informative and professional documents.

Discover More:

- [Adding Product Description to WooCommerce Invoices](https://www.webtoffee.com/docs/pdf-invoices/show-product-description-woocommerce-invoice-packing-slip/)## Plugin Spotlight

Plugin spotlight

WooCommerce PDF Invoices, Packing Slips and Credit Notes

4.9

$69 - $199

[View product](https://www.webtoffee.com/product/woocommerce-pdf-invoices-packing-slips/)

## About the Author

[Sanjai Valsan](https://www.webtoffee.com/author/sanjai/)

Technical Content Writer at WebToffee, simplifying complex concepts for seamless user experiences.

## Documentation Navigation

- [Getting Started](#getting-started-woocommerce-pdf-invoices-packing-slips-and-credit-notes-plugin)- [Setup Guide](https://www.webtoffee.com/docs/pdf-invoices/setup-woocommerce-invoices-packing-slips-credit-notes/)
- [Feature Walkthrough](https://www.webtoffee.com/docs/pdf-invoices/woocommerce-invoices-packing-slips-credit-notes-feature-walkthrough/)
- [Remote Print](#remote-print-pdf-invoices)- [Set up Remote Printing](https://www.webtoffee.com/docs/pdf-invoices/setup-remote-print-woocommerce-invoices/)
- [QR Code](#qr-code-pdf-invoices)- [Set up QR Code](https://www.webtoffee.com/docs/add-qr-code-woocommerce-invoice/?cid=909)
- [Cloud Storage](#cloud-storage)- [Dropbox Storage](https://www.webtoffee.com/docs/pdf-invoices/drop-box-cloud-storage-for-woocommerce-invoices-packing-slip-and-credit-note/)
- [Customizer](#customizer)- [How to Customize WooCommerce Cre...](https://www.webtoffee.com/docs/pdf-invoices/customize-woocommerce-credit-notes-using-webtoffee-pdf-customizer-step-by-step/)
- [How to Customize WooCommerce Pac...](https://www.webtoffee.com/docs/pdf-invoices/how-to-customize-woocommerce-packing-slips-using-webtoffee-pdf-customizer-step-by-step/)
- [Customize WooCommerce Invoices](https://www.webtoffee.com/docs/pdf-invoices/customize-woocommerce-invoices-using-webtoffee-pdf-customizer-step-by-step/)
- [What's New?](#whats-new-woocommerce-invoices-packingslip)- [Auto Reset Invoice Numbers](https://www.webtoffee.com/docs/pdf-invoices/auto-reset-woocommerce-invoice-numbers-annually/)
- [Select Language Preference](https://www.webtoffee.com/docs/set-language-preferences-woocommerce-document-types/?cid=909)
- [Exclude Backorder and Virtual Items](https://www.webtoffee.com/docs/exclude-backorder-virtual-items-packing-slip/?cid=909)
- [Invoice](#invoice-woocommerce-pdf-invoices-packing-slips-and-credit-notes-plugin)- [Adding Tax](#woocommerce-invoices-adding-tax)- [Add Tax Column in Invoice](https://www.webtoffee.com/docs/pdf-invoices/add-tax-column-in-woocommerce-invoice/)
- [Adding Metadata](#adding-meta-data-woocommerce-pdf-invoices-packing-slips-and-credit-notes-plugin)- [Add Order Meta](https://www.webtoffee.com/docs/pdf-invoices/add-order-meta-invoice-packing-slip-credit-note/)
- [Add Product Meta](https://www.webtoffee.com/docs/pdf-invoices/add-product-meta-invoice-packing-slip-credit-note/)
- [Add Product Attributes](https://www.webtoffee.com/docs/pdf-invoices/add-product-attributes-invoice-packing-slip-credit-note/)
- [Email Invoice](#email)- [Email Invoices by Order Status](https://www.webtoffee.com/docs/pdf-invoices/attach-invoice-pdf-woocommerce-order-emails/)
- [Pay Via Invoice](#pay-via-invoice)- [Pay from PDF Invoices](https://www.webtoffee.com/docs/pdf-invoices/enable-pay-now-in-woocommerce-invoices/)
- [Managing Invoice Numbers](#woocommerce-invoice-numbers)- [Set Up Invoice Numbering](https://www.webtoffee.com/docs/setup-invoice-numbering-woocommerce/?cid=940)
- [Auto Reset Invoice Numbers](https://www.webtoffee.com/docs/pdf-invoices/auto-reset-woocommerce-invoice-numbers-annually/)
- [Delete Existing Invoice Numbers](https://www.webtoffee.com/docs/pdf-invoices/delete-existing-invoice-numbers-woocommerce/)
- [Invoice Generation](#woocommerce-invoices-print-invoice)- [Auto Generate Invoices for Past Orders](https://www.webtoffee.com/docs/auto-generate-invoices-past-woocommerce-orders/?cid=940)
- [From My Account Page and Order Email](https://www.webtoffee.com/docs/pdf-invoices/enable-print-invoice-button-woocommerce-my-account/)
- [Generate Invoice for Free Orders](https://www.webtoffee.com/docs/generate-woocommerce-invoices-free-orders/?cid=940)
- [Bulk Print Using Filters](https://www.webtoffee.com/docs/bulk-generate-documents-filtering/?cid=940)
- [UBL Invoicing](#ubl-invoice-pdf-invoice-packing-slip)- [Generate UBL Invoices](https://www.webtoffee.com/docs/generate-ubl-invoices-woocommerce/?cid=940)
- [Email UBL Invoices](https://www.webtoffee.com/docs/attach-ubl-invoices-woocommerce-order-emails/?cid=940)
- [Customization](#customization)- [Add Discount Details](https://www.webtoffee.com/docs/pdf-invoices/show-product-discount-woocommerce-invoice/)
- [Custom Filename for PDF Invoices](https://www.webtoffee.com/docs/custom-pdf-invoice-filename-woocommerce/?cid=940)
- [Add Custom Placeholders](https://www.webtoffee.com/docs/pdf-invoices/add-custom-placeholders-woocommerce-invoice-packing-slip/)
- [Add Signature](https://www.webtoffee.com/docs/pdf-invoices/add-signature-woocommerce-invoices/)
- [Add Customer Note](https://www.webtoffee.com/docs/pdf-invoices/add-customer-note-woocommerce-invoice/)
- [Add Product Image, SKU](https://www.webtoffee.com/docs/pdf-invoices/add-product-image-sku-woocommerce-invoices/)
- [Show Free Products on Invoices](https://www.webtoffee.com/docs/display-free-product-woocommerce-invoices/?cid=940)
- [Apply Latest Settings to Invoice](https://www.webtoffee.com/docs/apply-latest-settings-woocommerce-invoices/?cid=940)
- [Display Custom Product Names](https://www.webtoffee.com/docs/pdf-invoices/custom-product-names-in-woocommerce-invoices/)
- [Add Custom Invoice Logo](https://www.webtoffee.com/docs/add-custom-logo-woocommerce-invoices/?cid=940)
- [Customize Print and Download Button Labels](https://www.webtoffee.com/docs/pdf-invoices/customize-invoice-button-labels-woocommerce-my-account/)
- [Packing Slip](#woocommerce-packing-slip)- [Email Packing Slip](#woocommerce-packing-slip-email)- [Email Packing Slip to Custom Email Address](https://www.webtoffee.com/docs/pdf-invoices/email-woocommerce-packing-slip-to-multiple-recipients/)
- [Add Metadata](#add-metadata-woocommerce-packing-slip)- [Add Order Meta](https://www.webtoffee.com/docs/pdf-invoices/add-order-meta-invoice-packing-slip-credit-note/)
- [Add Product Meta](https://www.webtoffee.com/docs/pdf-invoices/add-product-meta-invoice-packing-slip-credit-note/)
- [Add Product Attributes](https://www.webtoffee.com/docs/pdf-invoices/add-product-attributes-invoice-packing-slip-credit-note/)
- [Packaging Types](#woocommerce-packing-slip-packaging-types)- [Different Packaging Types](https://www.webtoffee.com/docs/different-packaging-types-woocommerce/?cid=1065)
- [Product Display](#woocommerce-packing-slip-product-display)- [Display Bundled Products](https://www.webtoffee.com/docs/pdf-invoices/display-bundled-products-woocommerce-invoice-packing-slip/)
- [Exclude Backorder and Virtual Items](https://www.webtoffee.com/docs/exclude-backorder-virtual-items-packing-slip/?cid=1065)
- [Customizations](#customization-woocommerce-packing-slip)- [Sort Items by Category and Product Name](https://www.webtoffee.com/docs/pdf-invoices/sort-products-by-category-woocommerce-packing-slip/)
- [Display Only Parent Category](https://www.webtoffee.com/docs/pdf-invoices/show-parent-categories-woocommerce-packing-slip/)
- [Credit Note](#woocommerce-credit-notes)- [Add Order Meta](https://www.webtoffee.com/docs/pdf-invoices/add-order-meta-invoice-packing-slip-credit-note/)
- [Add Product Meta](https://www.webtoffee.com/docs/pdf-invoices/add-product-meta-invoice-packing-slip-credit-note/)
- [Add Product Attributes](https://www.webtoffee.com/docs/pdf-invoices/add-product-attributes-invoice-packing-slip-credit-note/)
- [Email Credit Notes upon Order Refund](https://www.webtoffee.com/docs/pdf-invoices/email-woocommerce-credits-upon-order-refund/)
- [Reports](#woocommerce-invoices-packing-slips-reports)- [Export as ZIP file](https://www.webtoffee.com/docs/pdf-invoices/export-woocommerce-pdf-invoices-packing-slips-credit-notes/)
- [Shared Features](#shared-features-woocommerce-invoice-packing-slip)- [Add Custom Fields to the Checkout](https://www.webtoffee.com/docs/pdf-invoices/add-custom-checkout-fields-woocommerce-invoice/)
- [Preview Documents Before Printing](https://www.webtoffee.com/docs/pdf-invoices/preview-woocommerce-invoices-packing-slips-before-printing/)
- [Include Tracking Number Meta](https://www.webtoffee.com/docs/pdf-invoices/add-tracking-number-woocommerce-invoice-packing-slip/)
- [Add Dedicated Print Buttons](https://www.webtoffee.com/docs/add-print-buttons-woocommerce-invoices-shipping-labels/?cid=909)
- [Pre-Defined Filters](https://www.webtoffee.com/docs/pdf-invoices/customize-woocommerce-invoices-using-filters/)
- [Display Currency Codes](https://www.webtoffee.com/docs/pdf-invoices/display-currency-codes-woocommerce-invoices-credit-notes/)
- [Shared Customizations](#shared-customizations-invoices-packing-slips-credit-notes)- [Disable Document Types](https://www.webtoffee.com/docs/disable-woocommerce-invoices-packing-slips/?cid=909)
- [Customize Using Code Editor](https://www.webtoffee.com/docs/pdf-invoices/customize-woocommerce-invoice-packing-slip-using-code-editor/)
- [Customize Address Formats](https://www.webtoffee.com/docs/customize-address-formats-woocommerce-invoice-packing-slip-credit-note/?cid=909)
- [Remove Unnecessary Product Meta](https://www.webtoffee.com/docs/remove-product-meta-woocommerce-invoice/?cid=909)
- [Add Product Description](https://www.webtoffee.com/docs/pdf-invoices/show-product-description-woocommerce-invoice-packing-slip/)
- [Add Barcode](https://www.webtoffee.com/docs/pdf-invoices/add-barcode-woocommerce-invoices-packing-slips/)
- [Show Hidden Product Meta](https://www.webtoffee.com/docs/display-hidden-product-meta-document-types/?cid=909)
- [Highlight Item Quantity](https://www.webtoffee.com/docs/pdf-invoices/highlight-item-quantity-woocommerce-invoice-packing-slip/)
- [Hide Variation Details](https://www.webtoffee.com/docs/hide-variation-details-from-woocommerce-invoice-and-labels/?cid=909)
- [Add Custom Footer](https://www.webtoffee.com/docs/pdf-invoices/add-custom-footer-woocommerce-invoice-packing-slip/)
- [Display Product Meta in a New Column](https://www.webtoffee.com/docs/pdf-invoices/add-product-meta-column-woocommerce-invoice-packing-slip/)
- [Change to EU Address Format](https://www.webtoffee.com/docs/pdf-invoices/change-address-format-woocommerce-invoice/)
- [Multilingual Support](#woocommerce-invoices-multilingual-support)- [Translate Using Poedit](https://www.webtoffee.com/docs/pdf-invoices/translate-invoice-packing-slip-using-poedit/)
- [Translate Using Loco Translate](https://www.webtoffee.com/docs/pdf-invoices/translate-invoice-packing-slip-using-loco-translate/)
- [Translate Using WPML](https://www.webtoffee.com/docs/pdf-invoices/translate-invoice-packing-slip-using-wpml/)
- [Supported Languages](https://www.webtoffee.com/docs/pdf-invoices/language-support-woocommerce-invoice-packing-slip-credit-note/)
- [Backup & Restore Settings](#backup-restore-settings-pdf-invoice)- [Export Invoice Plugin Settings](https://www.webtoffee.com/docs/export-woocommerce-pdf-invoice-settings/?cid=909)
- [Import Invoice Plugin Settings](https://www.webtoffee.com/docs/import-woocommerce-pdf-invoice-settings/?cid=909)
- [Reset Invoice Plugin Settings](https://www.webtoffee.com/docs/reset-woocommerce-pdf-invoice-settings/?cid=909)
- [Third-Party Compatibility](#third-party-compatibility-woocommerce-invoice-packingslip-credit-note)- [Compatible Plugins](https://www.webtoffee.com/docs/pdf-invoices/pdf-invoice-plugin-third-party-compatibility/)
- [Compatibility with 'Product Add-Ons Ultimate'](https://www.webtoffee.com/docs/pdf-invoices/woocommerce-invoice-product-addons-ultimate-compatibility/)
- [Vendor's Store Address as From Address (Dokan)](https://www.webtoffee.com/docs/use-vendors-store-address-woocommerce-invoices-packing-slips-credit-notes/?cid=909)
- [Troubleshoot](#woocommerce-invoices-troubleshoot)- [Fix Image/Logo Missing Issues](https://www.webtoffee.com/docs/pdf-invoices/fix-missing-images-woocommerce-pdf-invoices/)
- [Fix Language Missing Issues](https://www.webtoffee.com/docs/pdf-invoices/fix-language-issues-woocommerce-pdf-invoices/)
- [Troubleshooting Guide](https://www.webtoffee.com/docs/pdf-invoices/woocommerce-pdf-invoices-packing-slips-troubleshooting-guide/)
- [Changelog](#changelog-woocommerce-pdf-invoices-packing-slips-and-credit-notes-plugin)- [Full changelog](https://www.webtoffee.com/docs/pdf-invoices/changelog-woocommerce-pdf-invoices-packing-slips-and-credit-notes-plugin/)