Retail codes and internal codes are different problems
EAN-13 and UPC-A identify products moving between companies, so the numbers are allocated centrally by GS1 and a retailer will check that the prefix belongs to you. Any tool can draw the bars; none can issue a number that will survive onboarding.
CODE128 and CODE39 carry identifiers that only mean something inside your own operation — asset tags, bin locations, work orders, consignment references. Nobody assigns those, so you can start printing immediately. Picking the wrong side of this line is the most expensive barcode mistake: an invented EAN scans perfectly and fails commercially.
Choosing between CODE128 and CODE39
CODE128 is the default for anything new. It encodes the full ASCII set, compresses digit pairs, and produces a symbol roughly 40% narrower than CODE39 for the same content — which is what decides it on small labels.
CODE39 is worth using when an external specification demands it, when the scanner fleet is old or unknown, or when existing labels have to stay consistent. It is uppercase-only and wider, but it is self-checking and readable by essentially every scanner ever built.
What makes a barcode fail in the field
Almost never the encoding. The usual culprits are a quiet zone cropped by artwork, bar height truncated to fit a layout, insufficient contrast, or bars printed in red — which is invisible to the red-light scanners still common at checkouts and in warehouses.
Print from the SVG rather than a scaled-up PNG, keep the bars solid black on a light background, and test on the actual scanner before committing to a print run. A curved or glossy surface defeats more barcodes than any choice of symbology.