Error message

"Harmonized code is invalid"

The error Harmonized code is invalid

This one is different from a missing code. The field has something in it. The carrier looked at it and refused it.

What makes a code valid

Two rules, and almost every rejection is one of them:

If the digits themselves are the question rather than the formatting, start with what an HS code is — what each digit means and how many you actually need.

Where the bad characters come from

Nobody types a period into an HS code on purpose. It arrives one of these ways:

The version of this you don't see

An invalid code throws an error, which is annoying but at least it's loud.

A blank code can be quieter. Depending on the shipping tool, a label can still print with an automatically generated placeholder in the customs field rather than a real classification. The label buys, the package ships, and the problem surfaces at the border instead of at your desk. That's the expensive version.

Worth checking either way If your products were filled in by hand, by an import, or by someone else on the team, it's worth confirming that what's in the field is actually a code and not a placeholder that happens to pass a length check.

Fixing one

  1. From your Shopify admin, go to Products.
  2. Click the product.
  3. In the Shipping section, confirm Physical product is on.
  4. Clear the Harmonized System (HS) code field completely and retype the digits. Don't edit around the bad characters — a trailing space survives that.

Finding all of them

One bad code means there are probably more, because they nearly always arrive the same way: one import, one copy-paste session, one spreadsheet. The codes that came in with periods came in with periods everywhere.

Shopify's bulk editor will let you fix them once you know which ones they are — from the product list, check the products, click Bulk edit, click Columns, and under Shipping tick Harmonized system code. What it won't do is find them. There's no filter for "HS code is malformed," so the search is either opening products one at a time or exporting and reading a column by eye.

Frequently asked questions

How many digits does an HS code need?

Six at minimum. That's the internationally standardized part of the Harmonized System. Countries extend it for their own tariff schedules, so a US import code runs to ten digits, but six is what clears a validity check.

Can an HS code contain a period?

Not in Shopify's field. Official tariff schedules print codes with periods for readability, like 6109.10.0012, but the field wants digits only: 6109100012.

Why did a code that worked before stop working?

Usually the value changed rather than the rule. A re-import, a bulk edit, or a spreadsheet round-trip can reformat the field, most often by stripping a leading zero or converting a long number to scientific notation.

Does a wrong-but-valid code cause problems?

It passes the format check and prints a label, and the problem moves downstream. The code sets the duty rate and, on some international labels, drives the description of contents that gets printed. Wrong code means wrong duty and a description that doesn't match what's in the box.

Related: "HS codes and country of origin are required" · What is an HS code? · Adding HS codes in bulk · Shopify customs information

Last reviewed 27 July 2026.

Find every product that's missing customs data.

Origova scans your whole catalog and lists exactly what's missing. The scan is free and unlimited — you see your number before you decide anything.

Install on Shopify