Sign in with Microsoft
Sign in or create an account.
Hello,
Select a different account.
You have multiple accounts
Choose the account you want to sign in with.

Barcodes

Word no longer has a built-in barcode tool. However you can generate barcodes using two field codes, DisplayBarcode and MergeBarcode.

These field codes support 10 types of barcodes, including UPC, Code 39, and Code 128. There is a postnet code CASE/ITC14, but it is a different tracking type barcode than the traditional Postnet format used for common mail routing.

The earlier Postnet barcode that supported ZIP and ZIP + 4 has been discontinued as of January 2013, at least for postal discounts. It's been replaced by Intelligent Mail barcode. If you need to create postal barcodes, the US Postal Service offers a number of resources to help you. There are also third-party suppliers of add-ons and tools for postal barcodes.

You can create labels with barcodes using DisplayBarcode and MergeBarcode. In this example, we're using multiple MergeFields, so we're showing how to do it with DisplayBarcode.

If you want just a barcode with a hard coded value, just use DisplayBarcode. For info and examples, see Field Code: DisplayBarcode.

These steps use an Excel spreadsheet as the data source for the labels. The merge creates labels with the human readable name and address, and a Code 128 barcode underneath with first name, last name, and city for machine reading. The field names are unique to whatever Excel data source you're using. The ones here are just examples.

Shot of some labels with address and barcodes

For guidelines on creating a spreadsheet with a mailing list, and more details on mail merges, see Create and print mailing labels for an address list in Excel.

Note: Field codes and barcode types are not case sensitive.

  1. In Excel, prepare your worksheet, and name the range. For more info, see Create and print mailing labels for an address list in Excel.

  2. Go to Mailings > Start Mail Merge >Labels.

  3. Choose a label vendor and product to use. If you don't see a list of label vendors, select Options.

    If you don’t see your product number, select New Label and configure a custom label.

  4. Select OK.

  5. Connect the data source in Word.

    1. Go to Mailings > Select Recipients.

    2. Select Existing List, and pick your Excel file.

    3. If you get the Confirm Data Source dialog, select Show all, and then choose MS Excel Worksheets via DDE (*.xls).

    4. Choose the named group.

    5. If you need to, select Mailings >Edit Recipient List and take out anyone you don't want in the list.

  6. Click or tap in the first label of the document.

  7. Put in an «AddressBlock» on the top of the label. For more info, see Create and print mailing labels for an address list in Excel.

  8. Press Enter, and then press Ctrl + F9 to open a Field.

  9. Type DisplayBarcode". Include the quote.

  10. Press Ctrl + F9, and type MergeField FirstName.

  11. Move your cursor outside the right curly brace, and press Ctrl + F9 again.

  12. Type MergeField LastName and move cursor to the right again.

  13. Press Ctrl + F9 and type MergeField City. Move the cursor to the right outside the curly brace.

  14. Type a space and a quote, then the barcode type, and any switches like " Code128 \t \h 1440 | . End with a vertical bar.

  15. Your code should look like this:

    { DisplayBarcode "{ MergeField FirstName } { MergeField LastName } { MergeField City }" CODE128 \t \h 1440| }

    A mailing label with AddressBlock and barcode fields

  16. Select Mailings > Update Labels. The other labels on the page should be filled in.

  17. To test your merge, select Preview Results.

Need more help?

Want more options?

Explore subscription benefits, browse training courses, learn how to secure your device, and more.

Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.

Was this information helpful?

What affected your experience?
By pressing submit, your feedback will be used to improve Microsoft products and services. Your IT admin will be able to collect this data. Privacy Statement.

Thank you for your feedback!

×