What USPS POSTNET is
POSTNET (Postal Numeric Encoding Technique) is a USPS barcode that encodes a ZIP code, ZIP+4, or full delivery-point code as a pattern of tall and short bars, historically used for automated mail sorting.
Generate it now
Enter a 5-digit ZIP code, 9-digit ZIP+4, or 11-digit delivery-point code to see a live preview -- bwip-js computes and appends the correct check digit for you.
Valid input
By default, bwip-js requires exactly 5, 9, or 11 digits -- the delivery-point code alone, with no check digit -- and rejects any other length with "USPS POSTNET must be 5, 9 or 11 digits excluding check digit". In this default mode there is no way to supply a check digit at all: bwip-js always computes the correct one itself from the digits you provide. Turning on the "validatecheck" option switches to a verification workflow instead: the input must then include a trailing check digit, and bwip-js rejects it if it does not match.
Key options
Supported options include includetext, includecheckintext, and "validatecheck" (verify an existing check digit instead of computing one).
Output and printing
Export SVG for mail-piece artwork or PNG for a quick proof.
Common uses
POSTNET barcodes historically appeared on envelopes and mail pieces to speed automated sorting by ZIP code or delivery point.
Example
See the live preview above, seeded with a bwip-js-verified valid 5-digit ZIP code.
Size guidance
bwip-js's own real default bar height, when height is left unset, is 0.125 inch (about 3.2mm).
Troubleshooting
A rejected code is usually the wrong digit count for the default (non-check-digit) mode; if you are pasting a code that already includes a check digit, turn on "validatecheck" first.
Related formats
Related formats: PLANET (a similar USPS delivery-confirmation barcode) and USPS Intelligent Mail (the newer 4-state barcode that has largely replaced POSTNET).
FAQ
What does "validatecheck" actually change?
Off (the default), the input is just the delivery-point digits (5, 9, or 11 of them) with no check digit at all -- bwip-js computes and appends the correct one itself, and a 6th/10th/12th digit is rejected purely for being the wrong length. On, the input must already include a trailing check digit, and bwip-js verifies it against the delivery-point digits before it, rejecting a genuine mismatch.