{"id":9868,"date":"2026-07-31T10:43:23","date_gmt":"2026-07-31T10:43:23","guid":{"rendered":"https:\/\/tradegoai.app\/?post_type=tools&#038;p=9868"},"modified":"2026-07-31T10:43:23","modified_gmt":"2026-07-31T10:43:23","slug":"hs%e3%82%b3%e3%83%bc%e3%83%89-%e6%a7%8b%e9%80%a0-%e5%bd%a2%e5%bc%8f-%e3%83%81%e3%82%a7%e3%83%83%e3%82%ab%e3%83%bc","status":"publish","type":"tools","link":"https:\/\/tradegoai.app\/ja\/tools\/hs-code-structure-format-checker\/","title":{"rendered":"HS\u30b3\u30fc\u30c9\u69cb\u9020\u30fb\u5f62\u5f0f\u30c1\u30a7\u30c3\u30ab\u30fc"},"content":{"rendered":"    <main id=\"tga-hs-structure-1\" class=\"tga-hs-structure-tool\" aria-labelledby=\"tga-hs-structure-1-title\">\n        <style>\n            #tga-hs-structure-1{--navy:#0f1831;--purple:#6528f7;--purple-dark:#501bd8;--lilac:#f2efff;--muted:#64748b;--line:#e2e8f0;--success:#047857;--warning:#b45309;--danger:#b91c1c;width:100%;max-width:1180px;margin:44px auto 72px;padding:0 22px;color:var(--navy);font-family:inherit;box-sizing:border-box}\n            #tga-hs-structure-1 *,#tga-hs-structure-1 *::before,#tga-hs-structure-1 *::after{box-sizing:border-box}\n            #tga-hs-structure-1 .tga-hs-hero{position:relative;overflow:hidden;padding:46px 48px;border-radius:22px;background:radial-gradient(circle at 88% 18%,rgba(101,40,247,.78),transparent 34%),linear-gradient(135deg,#081127,#131d42);color:#fff}\n            #tga-hs-structure-1 .tga-hs-hero::after{position:absolute;right:-78px;bottom:-118px;width:320px;height:320px;border:1px solid rgba(255,255,255,.16);border-radius:50%;content:\"\"}\n            #tga-hs-structure-1 .tga-hs-eyebrow{position:relative;z-index:1;margin:0 0 12px;color:#cbbcff;font-size:12px;font-weight:800;letter-spacing:.12em;text-transform:uppercase}\n            #tga-hs-structure-1 .tga-hs-hero h1{position:relative;z-index:1;max-width:980px;margin:0 0 14px;color:#fff;font-size:clamp(36px,5.2vw,60px);line-height:1.03;letter-spacing:-.04em}\n            #tga-hs-structure-1 .tga-hs-hero p:last-child{position:relative;z-index:1;max-width:820px;margin:0;color:#dce4ff;font-size:18px;line-height:1.65}\n            #tga-hs-structure-1 .tga-hs-workspace{display:grid;grid-template-columns:minmax(0,.92fr) minmax(0,1.08fr);gap:24px;margin-top:28px;align-items:start}\n            #tga-hs-structure-1 .tga-hs-workspace>*{min-width:0}\n            #tga-hs-structure-1 .tga-hs-panel,#tga-hs-structure-1 .tga-hs-section{border:1px solid var(--line);border-radius:18px;background:#fff;box-shadow:0 16px 45px rgba(15,24,49,.06)}\n            #tga-hs-structure-1 .tga-hs-panel{padding:28px}#tga-hs-structure-1 .tga-hs-section{margin-top:28px;padding:30px}\n            #tga-hs-structure-1 h2{margin:0 0 8px;color:var(--navy);font-size:25px;line-height:1.25;letter-spacing:-.02em}\n            #tga-hs-structure-1 .tga-hs-intro,#tga-hs-structure-1 .tga-hs-section>p{margin:0;color:var(--muted);line-height:1.7}\n            #tga-hs-structure-1 .tga-hs-fields{display:grid;gap:16px;margin-top:20px}\n            #tga-hs-structure-1 label{display:block;margin:0 0 7px;color:#334155;font-size:13px;font-weight:700}\n            #tga-hs-structure-1 input,#tga-hs-structure-1 select{width:100%;min-height:50px;margin:0;padding:10px 13px;border:1px solid #cbd5e1;border-radius:10px;outline:0;background:#fff;color:var(--navy);font:inherit;font-size:16px}\n            #tga-hs-structure-1 input:focus,#tga-hs-structure-1 select:focus{border-color:var(--purple);box-shadow:0 0 0 3px rgba(101,40,247,.12)}\n            #tga-hs-structure-1 .tga-hs-help{display:block;margin-top:6px;color:var(--muted);font-size:12px;line-height:1.5}\n            #tga-hs-structure-1 .tga-hs-error,#tga-hs-structure-1 .tga-hs-status{min-height:22px;margin:13px 0 0;font-size:13px;font-weight:700;line-height:1.5}\n            #tga-hs-structure-1 .tga-hs-error{color:var(--danger)}#tga-hs-structure-1 .tga-hs-status{color:var(--success)}#tga-hs-structure-1 [hidden]{display:none!important}\n            #tga-hs-structure-1 .tga-hs-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}\n            #tga-hs-structure-1 .tga-hs-button{display:inline-flex;align-items:center;justify-content:center;min-height:42px;padding:9px 14px;border:1px solid #cbd5e1;border-radius:9px;background:#fff;color:var(--navy);cursor:pointer;font:inherit;font-size:14px;font-weight:800;line-height:1.2;text-decoration:none}\n            #tga-hs-structure-1 .tga-hs-button:hover{border-color:var(--purple);transform:translateY(-1px)}\n            #tga-hs-structure-1 .tga-hs-primary{min-height:50px;padding:11px 19px;border-color:var(--purple);background:var(--purple);color:#fff}#tga-hs-structure-1 .tga-hs-primary:hover{border-color:var(--purple-dark);background:var(--purple-dark)}\n            #tga-hs-structure-1 .tga-hs-result{min-height:470px}#tga-hs-structure-1 .tga-hs-empty{margin-top:22px;padding:28px 22px;border:1px dashed #cbd5e1;border-radius:14px;background:#f8fafc;color:var(--muted);line-height:1.7;text-align:center}\n            #tga-hs-structure-1 .tga-hs-result-head{display:flex;gap:14px;align-items:flex-start;justify-content:space-between;margin-top:20px;padding:18px;border:1px solid var(--line);border-radius:14px;background:#fbfdff}\n            #tga-hs-structure-1 .tga-hs-code{display:block;margin-top:5px;color:var(--navy);font-size:clamp(25px,4vw,34px);line-height:1.2;letter-spacing:.06em;overflow-wrap:anywhere}\n            #tga-hs-structure-1 .tga-hs-badge{flex:0 0 auto;padding:7px 10px;border-radius:999px;font-size:12px;font-weight:800}\n            #tga-hs-structure-1 .is-complete{background:#dcfce7;color:#166534}.is-incomplete{background:#fef3c7;color:#92400e}.is-excess{background:#fee2e2;color:#991b1b}\n            #tga-hs-structure-1 .tga-hs-progress{height:8px;margin-top:14px;overflow:hidden;border-radius:999px;background:#e2e8f0}#tga-hs-structure-1 .tga-hs-progress span{display:block;height:100%;width:0;border-radius:inherit;background:linear-gradient(90deg,var(--purple),#8b5cf6)}\n            #tga-hs-structure-1 .tga-hs-metrics{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:16px}\n            #tga-hs-structure-1 .tga-hs-metric{min-width:0;padding:15px;border:1px solid var(--line);border-radius:12px;background:#fff}\n            #tga-hs-structure-1 .tga-hs-metric span{display:block;color:var(--muted);font-size:12px;font-weight:700;line-height:1.4}#tga-hs-structure-1 .tga-hs-metric strong{display:block;margin-top:5px;color:var(--navy);font-size:20px;line-height:1.3;overflow-wrap:anywhere}\n            #tga-hs-structure-1 .tga-hs-callout{margin-top:15px;padding:16px;border-left:4px solid var(--purple);border-radius:10px;background:var(--lilac);color:#334155;line-height:1.65}\n            #tga-hs-structure-1 .tga-hs-guide{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-top:20px}#tga-hs-structure-1 .tga-hs-guide article{padding:18px;border:1px solid var(--line);border-radius:13px;background:#fbfdff}#tga-hs-structure-1 .tga-hs-guide h3{margin:0 0 7px;font-size:16px;line-height:1.35}#tga-hs-structure-1 .tga-hs-guide p{margin:0;color:var(--muted);font-size:14px;line-height:1.65}\n            #tga-hs-structure-1 .tga-hs-cta{display:flex;gap:28px;align-items:center;justify-content:space-between;margin-top:28px;padding:34px 38px;border-radius:18px;background:radial-gradient(circle at 88% 18%,rgba(101,40,247,.65),transparent 38%),linear-gradient(135deg,#081127,#131d42);color:#fff}#tga-hs-structure-1 .tga-hs-cta h2{color:#fff;font-size:28px}#tga-hs-structure-1 .tga-hs-cta p{max-width:720px;margin:0;color:#dce4ff;line-height:1.7}#tga-hs-structure-1 .tga-hs-cta a{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;min-height:50px;padding:11px 19px;border-radius:10px;background:#fff;color:var(--navy);font-weight:800;text-decoration:none}\n            #tga-hs-structure-1 .tga-hs-faq{display:grid;gap:10px;margin-top:20px}#tga-hs-structure-1 details{border:1px solid var(--line);border-radius:12px;background:#fff}#tga-hs-structure-1 summary{padding:16px 18px;cursor:pointer;font-weight:800}#tga-hs-structure-1 details p{margin:0;padding:0 18px 17px;color:var(--muted);line-height:1.7}\n            #tga-hs-structure-1 .tga-hs-related{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-top:20px}#tga-hs-structure-1 .tga-hs-related a{display:block;padding:20px;border:1px solid var(--line);border-radius:13px;color:var(--navy);text-decoration:none}#tga-hs-structure-1 .tga-hs-related a:hover{border-color:var(--purple)}#tga-hs-structure-1 .tga-hs-related strong{display:block;margin-bottom:7px;color:var(--purple)}#tga-hs-structure-1 .tga-hs-related span{display:block;color:var(--muted);font-size:14px;line-height:1.6}\n            @media(max-width:900px){#tga-hs-structure-1 .tga-hs-workspace{grid-template-columns:1fr}#tga-hs-structure-1 .tga-hs-result{min-height:0}#tga-hs-structure-1 .tga-hs-guide,#tga-hs-structure-1 .tga-hs-related{grid-template-columns:1fr}#tga-hs-structure-1 .tga-hs-cta{align-items:flex-start;flex-direction:column}}\n            @media(max-width:600px){#tga-hs-structure-1{margin-top:28px;padding:0 20px}#tga-hs-structure-1 .tga-hs-hero{padding:32px 23px}#tga-hs-structure-1 .tga-hs-hero h1{font-size:35px}#tga-hs-structure-1 .tga-hs-panel,#tga-hs-structure-1 .tga-hs-section{padding:23px 19px}#tga-hs-structure-1 .tga-hs-metrics{grid-template-columns:1fr}#tga-hs-structure-1 .tga-hs-actions{display:grid;grid-template-columns:1fr}#tga-hs-structure-1 .tga-hs-button,#tga-hs-structure-1 .tga-hs-cta a{width:100%}#tga-hs-structure-1 .tga-hs-cta{padding:28px 22px}#tga-hs-structure-1 .tga-hs-result-head{align-items:flex-start;flex-direction:column}}\n        <\/style>\n\n        <section class=\"tga-hs-hero\"><p class=\"tga-hs-eyebrow\">Check the Code Structure Before Tariff Research<\/p><h1 id=\"tga-hs-structure-1-title\">HS Code Structure &amp; Format Checker<\/h1><p>Clean a tariff code, compare its digit length with the selected market, and separate its chapter, heading, subheading, and national extension.<\/p><\/section>\n\n        <section class=\"tga-hs-workspace\" aria-label=\"HS code structure checker workspace\">\n            <form class=\"tga-hs-panel tga-hs-form\" novalidate>\n                <h2>Enter the Code and Market Format<\/h2><p class=\"tga-hs-intro\">Paste a candidate code from a document or tariff source. Spaces, dots, and hyphens are accepted as separators.<\/p>\n                <div class=\"tga-hs-fields\">\n                    <div><label for=\"tga-hs-structure-1-code\">HS or national tariff code<\/label><input id=\"tga-hs-structure-1-code\" data-field=\"code\" type=\"text\" value=\"8517.62.0090\" maxlength=\"40\" inputmode=\"numeric\" autocomplete=\"off\" required><span class=\"tga-hs-help\">Example: 8517.62.0090 becomes 8517620090.<\/span><\/div>\n                    <div><label for=\"tga-hs-structure-1-market\">Market or tariff format<\/label><select id=\"tga-hs-structure-1-market\" data-field=\"market\"><option value=\"us10\">United States HTS \u2014 10 digits<\/option><option value=\"hs6\">International HS \u2014 6 digits<\/option><option value=\"eu8\">European Union CN \u2014 8 digits<\/option><option value=\"eu10\">European Union TARIC \u2014 10 digits<\/option><option value=\"uk10\">United Kingdom commodity code \u2014 10 digits<\/option><option value=\"cn10\">China customs code \u2014 10 digits<\/option><option value=\"jp9\">Japan tariff code \u2014 9 digits<\/option><option value=\"kr10\">South Korea HSK \u2014 10 digits<\/option><option value=\"custom\">Other national format<\/option><\/select><\/div>\n                    <div data-custom hidden><label for=\"tga-hs-structure-1-expected\">Required number of digits<\/label><input id=\"tga-hs-structure-1-expected\" data-field=\"expected\" type=\"number\" value=\"10\" min=\"6\" max=\"14\" step=\"1\"><span class=\"tga-hs-help\">Choose 6 to 14 digits and confirm the requirement with the official market source.<\/span><\/div>\n                <\/div>\n                <p class=\"tga-hs-error\" role=\"alert\" aria-live=\"assertive\"><span data-error=\"empty\" hidden>Enter an HS or national tariff code.<\/span><span data-error=\"characters\" hidden>Use digits with optional spaces, dots, or hyphens only.<\/span><span data-error=\"short\" hidden>Enter at least two digits so the chapter can be identified.<\/span><span data-error=\"expected\" hidden>Enter a whole required length from 6 to 14 digits.<\/span><\/p>\n                <div class=\"tga-hs-actions\"><button class=\"tga-hs-button tga-hs-primary\" type=\"submit\">Check Code Structure<\/button><button class=\"tga-hs-button\" data-action=\"reset\" type=\"button\">Reset<\/button><\/div>\n            <\/form>\n\n            <section class=\"tga-hs-panel tga-hs-result\" aria-labelledby=\"tga-hs-structure-1-result-title\">\n                <h2 id=\"tga-hs-structure-1-result-title\">Structure Check Result<\/h2><p class=\"tga-hs-intro\">A format match confirms the digit structure only, not the product classification.<\/p>\n                <div class=\"tga-hs-empty\" data-empty>Enter a code and select Check Code Structure.<span class=\"tga-hs-status\" data-reset-status hidden>The example code has been restored.<\/span><\/div>\n                <div data-output hidden>\n                    <div class=\"tga-hs-result-head\"><div><span class=\"tga-hs-help\">Normalized code<\/span><strong class=\"tga-hs-code\" data-result=\"normalized\">\u2014<\/strong><\/div><span class=\"tga-hs-badge\" data-result=\"status\">\u2014<\/span><\/div>\n                    <div class=\"tga-hs-progress\" aria-hidden=\"true\"><span data-progress><\/span><\/div>\n                    <div class=\"tga-hs-metrics\">\n                        <div class=\"tga-hs-metric\"><span>Selected format<\/span><strong data-result=\"market\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>Digits entered \/ required<\/span><strong data-result=\"count\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>Chapter \u2014 first 2 digits<\/span><strong data-result=\"chapter\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>Heading \u2014 first 4 digits<\/span><strong data-result=\"heading\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>HS subheading \u2014 first 6 digits<\/span><strong data-result=\"subheading\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>National extension \u2014 after 6 digits<\/span><strong data-result=\"extension\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>Readable grouping<\/span><strong data-result=\"formatted\">\u2014<\/strong><\/div>\n                        <div class=\"tga-hs-metric\"><span>Structure note<\/span><strong data-result=\"difference\">\u2014<\/strong><\/div>\n                    <\/div>\n                    <div class=\"tga-hs-callout\">Format does not establish classification. Verify the code, legal notes, measures, rate, restrictions, and effective date in the official tariff database.<\/div>\n                    <div class=\"tga-hs-actions\"><button class=\"tga-hs-button\" data-action=\"copy\" type=\"button\">Copy Summary<\/button><button class=\"tga-hs-button\" data-action=\"download\" type=\"button\">Download CSV<\/button><\/div>\n                    <p class=\"tga-hs-status\" role=\"status\" aria-live=\"polite\"><span data-status=\"checked\" hidden>Code structure checked.<\/span><span data-status=\"copied\" hidden>Summary copied.<\/span><span data-status=\"copyFailed\" hidden>Copy failed. Select and copy the result manually.<\/span><span data-status=\"downloaded\" hidden>CSV downloaded.<\/span><\/p>\n                <\/div>\n            <\/section>\n        <\/section>\n\n        <section class=\"tga-hs-section\"><h2>How to Read the Structure Check<\/h2><p>The checker separates the universal six-digit HS core from any market-specific extension without claiming what product the code covers.<\/p><div class=\"tga-hs-guide\"><article><h3>Chapter and Heading<\/h3><p>The first two digits identify the chapter. The first four digits form the heading used to organize a broader class of goods.<\/p><\/article><article><h3>HS Subheading<\/h3><p>The first six digits form the international HS subheading. Product interpretation still depends on descriptions and legal notes.<\/p><\/article><article><h3>National Extension<\/h3><p>Digits after position six are market-specific tariff or statistical subdivisions. Required lengths can differ by jurisdiction.<\/p><\/article><\/div><\/section>\n        <section class=\"tga-hs-cta\"><div><h2>Move From Code Checking to Better Trade Preparation<\/h2><p>Explore TradeGoAI services for buyer research, sales preparation, trade documentation, risk review, and market visibility.<\/p><\/div><a href=\"https:\/\/tradegoai.app\/ja\/services\/\">Explore Services \u2192<\/a><\/section>\n        <section class=\"tga-hs-section\"><h2>Frequently Asked Questions<\/h2><div class=\"tga-hs-faq\"><details><summary>What can this HS code checker confirm?<\/summary><p>It confirms whether the entered value contains an acceptable sequence of digits and whether its length matches the selected market format. It also separates the chapter, heading, six-digit HS subheading, and any national extension.<\/p><\/details><details><summary>Does a complete result mean the classification is correct?<\/summary><p>No. A complete result only means the code matches the expected digit structure. Confirm the product description, classification, legal notes, duty treatment, restrictions, and current validity in the destination market\u2019s official tariff source.<\/p><\/details><details><summary>Why are the first six digits important?<\/summary><p>The international Harmonized System is structured around a two-digit chapter, four-digit heading, and six-digit subheading. Markets can add further digits for national tariff and statistical purposes.<\/p><\/details><details><summary>Can I paste a code with spaces, dots, or hyphens?<\/summary><p>Yes. The checker removes spaces, dots, and hyphens before counting digits. Other characters are rejected so they are not silently treated as part of a tariff code.<\/p><\/details><details><summary>Which market formats are included?<\/summary><p>The tool includes common working lengths for the international six-digit HS, United States HTS, European Union CN and TARIC, United Kingdom, China, Japan, and South Korea, plus a custom digit-length option.<\/p><\/details><details><summary>Does the tool use live customs or tariff data?<\/summary><p>No. It runs entirely in the browser and checks structure only. Use the related official-search tools to verify the current code, description, duty rate, measures, and effective date.<\/p><\/details><\/div><\/section>\n        <section class=\"tga-hs-section\"><h2>Related Free Tools<\/h2><p>Continue from structure checking into official tariff research, customs portals, and user-supplied duty estimates.<\/p><div class=\"tga-hs-related\"><a href=\"https:\/\/tradegoai.app\/ja\/tools\/hs-code-search-launcher\/\"><strong>HS Code Search Launcher<\/strong><span>Open official tariff-search destinations using your product keywords and target market.<\/span><\/a><a href=\"https:\/\/tradegoai.app\/ja\/tools\/customs-portal-directory\/\"><strong>Customs Portal Directory<\/strong><span>Find official customs, tariff, and trade-information portals by market.<\/span><\/a><a href=\"https:\/\/tradegoai.app\/ja\/tools\/customs-duty-import-tax-calculator\/\"><strong>Customs Duty &amp; Import Tax Calculator<\/strong><span>Estimate duty and import tax from the rates and customs value you enter.<\/span><\/a><\/div><\/section>\n\n        <div data-i18n hidden>\n            <span data-key=\"complete\">Complete format<\/span><span data-key=\"incomplete\">Incomplete format<\/span><span data-key=\"excess\">Too many digits<\/span><span data-key=\"none\">None<\/span><span data-key=\"notAvailable\">Not available yet<\/span><span data-key=\"digitsNeeded\">more digit(s) needed<\/span><span data-key=\"digitsExtra\">extra digit(s)<\/span><span data-key=\"exact\">Exact length match<\/span>\n            <span data-key=\"title\">HS Code Structure Check<\/span><span data-key=\"code\">Normalized code<\/span><span data-key=\"format\">Selected format<\/span><span data-key=\"count\">Digits entered \/ required<\/span><span data-key=\"chapter\">Chapter<\/span><span data-key=\"heading\">Heading<\/span><span data-key=\"subheading\">HS subheading<\/span><span data-key=\"extension\">National extension<\/span><span data-key=\"grouping\">Readable grouping<\/span><span data-key=\"note\">Structure note<\/span>\n        <\/div>\n        <script>\n        (function(){\n            'use strict';const root=document.getElementById(\"tga-hs-structure-1\");if(!root||root.dataset.ready==='1')return;root.dataset.ready='1';\n            const form=root.querySelector('.tga-hs-form'),empty=root.querySelector('[data-empty]'),output=root.querySelector('[data-output]'),custom=root.querySelector('[data-custom]'),progress=root.querySelector('[data-progress]'),fields={},results={},labels={};root.querySelectorAll('[data-field]').forEach(n=>fields[n.dataset.field]=n);root.querySelectorAll('[data-result]').forEach(n=>results[n.dataset.result]=n);\n            const formats={us10:{digits:10,label:'United States HTS \u2014 10 digits'},hs6:{digits:6,label:'International HS \u2014 6 digits'},eu8:{digits:8,label:'European Union CN \u2014 8 digits'},eu10:{digits:10,label:'European Union TARIC \u2014 10 digits'},uk10:{digits:10,label:'United Kingdom commodity code \u2014 10 digits'},cn10:{digits:10,label:'China customs code \u2014 10 digits'},jp9:{digits:9,label:'Japan tariff code \u2014 9 digits'},kr10:{digits:10,label:'South Korea HSK \u2014 10 digits'}};const defaults={code:'8517.62.0090',market:'us10',expected:'10'};let current=null;\n            function loadLabels(){root.querySelectorAll('[data-i18n] [data-key]').forEach(n=>labels[n.dataset.key]=n.textContent.trim())}loadLabels();\n            function clear(){root.querySelectorAll('[data-error],[data-status],[data-reset-status]').forEach(n=>n.hidden=true)}function message(t,k){clear();const n=root.querySelector(`[data-${t}=\"${k}\"]`);if(n)n.hidden=false}\n            function read(){const raw=fields.code.value.trim();if(!raw)throw new Error('empty');if(!\/^[0-9.\\s-]+$\/.test(raw))throw new Error('characters');const code=raw.replace(\/[.\\s-]\/g,'');if(code.length<2)throw new Error('short');let format=formats[fields.market.value],expected,label;if(fields.market.value==='custom'){expected=Number(fields.expected.value);if(!Number.isInteger(expected)||expected<6||expected>14)throw new Error('expected');label='Other national format \u2014 '+expected+' digits'}else{expected=format.digits;label=format.label}return{raw,code,expected,label,market:fields.market.value}}\n            function group(code){const parts=[];if(code.slice(0,4))parts.push(code.slice(0,4));if(code.slice(4,6))parts.push(code.slice(4,6));for(let i=6;i<code.length;i+=2)parts.push(code.slice(i,i+2));return parts.join('.')}\n            function calculate(d){const count=d.code.length,difference=count-d.expected,status=difference===0?'complete':difference<0?'incomplete':'excess';return{input:d,count,difference,status,chapter:d.code.slice(0,2),heading:count>=4?d.code.slice(0,4):'',subheading:count>=6?d.code.slice(0,6):'',extension:count>6?d.code.slice(6):'',formatted:group(d.code)}}\n            function render(r){results.normalized.textContent=r.input.code;results.market.textContent=r.input.label;results.count.textContent=r.count+' \/ '+r.input.expected;results.chapter.textContent=r.chapter;results.heading.textContent=r.heading||labels.notAvailable;results.subheading.textContent=r.subheading||labels.notAvailable;results.extension.textContent=r.extension||labels.none;results.formatted.textContent=r.formatted;results.status.className='tga-hs-badge is-'+r.status;if(r.status==='complete'){results.status.textContent=labels.complete;results.difference.textContent=labels.exact}else if(r.status==='incomplete'){results.status.textContent=labels.incomplete;results.difference.textContent=Math.abs(r.difference)+' '+labels.digitsNeeded}else{results.status.textContent=labels.excess;results.difference.textContent=r.difference+' '+labels.digitsExtra}progress.style.width=Math.min(100,(r.count\/r.input.expected)*100)+'%';empty.hidden=true;output.hidden=false;message('status','checked')}\n            function rows(r){return[[labels.code,r.input.code],[labels.format,r.input.label],[labels.count,r.count+' \/ '+r.input.expected],[labels.chapter,r.chapter],[labels.heading,r.heading||labels.notAvailable],[labels.subheading,r.subheading||labels.notAvailable],[labels.extension,r.extension||labels.none],[labels.grouping,r.formatted],[labels.note,results.difference.textContent]]}\n            function summary(r){return[labels.title].concat(rows(r).map(x=>x[0]+': '+x[1])).join('\\n')}\n            function csvCell(v){let s=String(v);if(\/^[=+\\-@]\/.test(s))s=\"'\"+s;return '\"'+s.replace(\/\"\/g,'\"\"')+'\"'}\n            async function copy(){if(!current)return;try{const text=summary(current);if(navigator.clipboard&&window.isSecureContext)await navigator.clipboard.writeText(text);else{const a=document.createElement('textarea');a.value=text;a.style.position='fixed';a.style.opacity='0';document.body.appendChild(a);a.select();if(!document.execCommand('copy'))throw new Error();a.remove()}message('status','copied')}catch(e){message('status','copyFailed')}}\n            function download(){if(!current)return;const data=[['Field','Value']].concat(rows(current)),csv='\\uFEFF'+data.map(r=>r.map(csvCell).join(',')).join('\\r\\n'),blob=new Blob([csv],{type:'text\/csv;charset=utf-8'}),url=URL.createObjectURL(blob),a=document.createElement('a');a.href=url;a.download='hs-code-structure-check.csv';document.body.appendChild(a);a.click();a.remove();setTimeout(()=>URL.revokeObjectURL(url),1000);message('status','downloaded')}\n            function reset(){Object.keys(defaults).forEach(k=>fields[k].value=defaults[k]);custom.hidden=true;current=null;clear();output.hidden=true;empty.hidden=false;root.querySelector('[data-reset-status]').hidden=false;fields.code.focus()}\n            fields.market.addEventListener('change',()=>{custom.hidden=fields.market.value!=='custom'});form.addEventListener('submit',e=>{e.preventDefault();loadLabels();clear();try{current=calculate(read());render(current)}catch(err){current=null;output.hidden=true;empty.hidden=false;message('error',err.message||'characters')}});\n            root.querySelector('[data-action=\"reset\"]').addEventListener('click',reset);root.querySelector('[data-action=\"copy\"]').addEventListener('click',copy);root.querySelector('[data-action=\"download\"]').addEventListener('click',download);\n        })();\n        <\/script>\n    <\/main>\n    \n","protected":false},"excerpt":{"rendered":"<p>\u516c\u5f0f\u95a2\u7a0e\u60c5\u5831\u3092\u5229\u7528\u3059\u308b\u524d\u306b\u3001HS\u30b3\u30fc\u30c9\u307e\u305f\u306f\u56fd\u5185\u95a2\u7a0e\u30b3\u30fc\u30c9\u306e\u6841\u6570\u3001\u5fc5\u8981\u306a\u9577\u3055\u3001\u985e\u3001\u9805\u3001\u53f7\u3001\u56fd\u5185\u62e1\u5f35\u3092\u78ba\u8a8d\u3057\u307e\u3059\u3002<\/p>","protected":false},"featured_media":9870,"template":"","meta":{"_uag_custom_page_level_css":"","site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"spectra_gs_classes":"[\"\"]"},"tool_categories":[54,46],"class_list":["post-9868","tools","type-tools","status-publish","has-post-thumbnail","hentry","tool_categories-customs-lookup","tool_categories-trade-operations"],"spectra_custom_meta":{"spectra_gs_classes":["[\"\"]"],"rank_math_internal_links_processed":["1"],"wp_statistics_words_count":["1"],"_thumbnail_id":["9870"],"rank_math_title":["%title% %sep% %sitename%"],"rank_math_description":["%excerpt%"],"rank_math_robots":["a:2:{i:0;s:5:\"index\";i:1;s:6:\"follow\";}"],"rank_math_facebook_image":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share.webp"],"rank_math_facebook_image_id":["9870"],"rank_math_twitter_use_facebook":["on"],"rank_math_twitter_card_type":["summary_large_image"],"rank_math_schema_SoftwareApplication":["a:8:{s:5:\"@type\";s:19:\"SoftwareApplication\";s:4:\"name\";s:34:\"HS Code Structure & Format Checker\";s:11:\"description\";s:157:\"Check an HS or national tariff code\u2019s digits, required length, chapter, heading, subheading, and national extension before using an official tariff source.\";s:3:\"url\";s:61:\"https:\/\/tradegoai.app\/tools\/hs-code-structure-format-checker\/\";s:5:\"image\";s:99:\"https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share.webp\";s:19:\"applicationCategory\";s:19:\"BusinessApplication\";s:15:\"operatingSystem\";s:11:\"Web Browser\";s:6:\"offers\";a:3:{s:5:\"@type\";s:5:\"Offer\";s:5:\"price\";s:1:\"0\";s:13:\"priceCurrency\";s:3:\"USD\";}}"],"astra_style_timestamp_css":["1787215266"],"_uag_page_assets":["a:9:{s:3:\"css\";s:4963:\".uag-blocks-common-selector{z-index:var(--z-index-desktop) !important}@media (max-width: 976px){.uag-blocks-common-selector{z-index:var(--z-index-tablet) !important}}@media (max-width: 767px){.uag-blocks-common-selector{z-index:var(--z-index-mobile) !important}}\n.uagb-icon-list__wrap{display:flex;align-items:flex-start;justify-content:flex-start}.wp-block-uagb-icon-list-child{padding:0;transition:all 0.2s;display:inline-flex;color:#3a3a3a;align-items:center;text-decoration:none;box-shadow:none}.wp-block-uagb-icon-list-child span.uagb-icon-list__source-wrap{display:block;align-items:center}.uagb-icon-list__source-wrap svg{display:block}.uagb-icon-list__source-image{width:40px}.uagb-icon-list__outer-wrap .uagb-icon-list__content-wrap{color:#3a3a3a;display:flex;align-items:center}\n.wp-block-uagb-icon-list-child{position:relative}.wp-block-uagb-icon-list-child>a{position:absolute;top:0;left:0;width:100%;height:100%}img.uagb-icon-list__source-image{max-width:unset}.wp-block-uagb-icon-list-child .uagb-icon-list__label{word-break:break-word}\n.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__source-image{width: 16px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap svg{width: 16px;height: 16px;font-size: 16px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap{padding: 0px;border-radius: 0px;border-width: 0px;align-self: center;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__label{text-decoration: !important;font-weight: 600;line-height: em;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__wrap{display: flex;flex-direction: column;justify-content: center;-webkit-box-pack: center;-ms-flex-pack: center;-webkit-box-align: flex-start;-ms-flex-align: flex-start;align-items: flex-start;margin-top: 30px;margin-right: 0px;margin-bottom: 0px;margin-left: 0px;padding-top: 0px;padding-right: 0px;padding-bottom: 0px;padding-left: 0px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__label{text-align: left;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child{text-decoration: !important;font-weight: 600;line-height: em;}.wp-block-uagb-icon-list.uagb-block-b5768981.wp-block-uagb-icon-list .wp-block-uagb-icon-list-child{margin-left: 0;margin-right: 0;margin-bottom: 10px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__source-wrap{margin-right: 15px;}.uagb-block-75fa870d.wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap{background:  !important;border-color:  !important;}.uagb-block-75fa870d.wp-block-uagb-icon-list-child:hover .uagb-icon-list__source-wrap{background:  !important;border-color:  !important;}.uagb-block-5bf81fd2.wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap{background:  !important;border-color:  !important;}.uagb-block-5bf81fd2.wp-block-uagb-icon-list-child:hover .uagb-icon-list__source-wrap{background:  !important;border-color:  !important;}@media only screen and (max-width: 976px) {.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__source-image{width: 16px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap svg{width: 16px;height: 16px;font-size: 16px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap {padding: 0px;border-width: 0px;align-self: center;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__wrap{display: flex;flex-direction: column;justify-content: center;-webkit-box-pack: center;-ms-flex-pack: center;-webkit-box-align: flex-start;-ms-flex-align: flex-start;align-items: flex-start;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__label{text-align: left;}.wp-block-uagb-icon-list.uagb-block-b5768981.wp-block-uagb-icon-list .wp-block-uagb-icon-list-child{margin-left: 0;margin-right: 0;margin-bottom: 10px;}}@media only screen and (max-width: 767px) {.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__source-image{width: 16px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__label{text-align: center;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap svg{width: 16px;height: 16px;font-size: 16px;}.wp-block-uagb-icon-list.uagb-block-b5768981 .wp-block-uagb-icon-list-child .uagb-icon-list__source-wrap{padding: 0px;border-width: 0px;align-self: center;}.wp-block-uagb-icon-list.uagb-block-b5768981 .uagb-icon-list__wrap{display: flex;flex-direction: column;justify-content: center;-webkit-box-pack: center;-ms-flex-pack: center;-webkit-box-align: center;-ms-flex-align: center;align-items: center;margin-top: 0px;margin-right: 0px;margin-bottom: 0px;margin-left: 0px;}.wp-block-uagb-icon-list.uagb-block-b5768981.wp-block-uagb-icon-list .wp-block-uagb-icon-list-child{margin-left: 0;margin-right: 0;margin-bottom: 10px;}}\";s:2:\"js\";s:0:\"\";s:18:\"current_block_list\";a:10:{i:0;s:11:\"core\/search\";i:1;s:10:\"core\/group\";i:2;s:12:\"core\/heading\";i:3;s:17:\"core\/latest-posts\";i:4;s:20:\"core\/latest-comments\";i:5;s:13:\"core\/archives\";i:6;s:15:\"core\/categories\";i:7;s:14:\"uagb\/icon-list\";i:8;s:20:\"uagb\/icon-list-child\";i:9;s:14:\"core\/shortcode\";}s:8:\"uag_flag\";b:1;s:11:\"uag_version\";s:10:\"1787709447\";s:6:\"gfonts\";a:0:{}s:10:\"gfonts_url\";s:0:\"\";s:12:\"gfonts_files\";a:0:{}s:14:\"uag_faq_layout\";b:0;}"],"_uag_css_file_name":["uag-css-9868.css"]},"uagb_featured_image_src":{"full":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share.webp",1200,630,false],"thumbnail":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share-150x150.webp",150,150,true],"medium":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share-300x158.webp",300,158,true],"medium_large":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share-768x403.webp",768,403,true],"large":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share-1024x538.webp",1024,538,true],"1536x1536":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share.webp",1200,630,false],"2048x2048":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share.webp",1200,630,false],"trp-custom-language-flag":["https:\/\/tradegoai.app\/wp-content\/uploads\/2026\/07\/hs-code-structure-format-checker-social-share-18x9.webp",18,9,true]},"uagb_author_info":{"display_name":"xiaoxi99202@gmail.com","author_link":"https:\/\/tradegoai.app\/ja\/author\/"},"uagb_comment_info":0,"uagb_excerpt":"Check an HS or national tariff code\u2019s digits, required length, chapter, heading, subheading, and national extension before using an official tariff source.","_links":{"self":[{"href":"https:\/\/tradegoai.app\/ja\/wp-json\/wp\/v2\/tools\/9868","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tradegoai.app\/ja\/wp-json\/wp\/v2\/tools"}],"about":[{"href":"https:\/\/tradegoai.app\/ja\/wp-json\/wp\/v2\/types\/tools"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/tradegoai.app\/ja\/wp-json\/wp\/v2\/media\/9870"}],"wp:attachment":[{"href":"https:\/\/tradegoai.app\/ja\/wp-json\/wp\/v2\/media?parent=9868"}],"wp:term":[{"taxonomy":"tool_categories","embeddable":true,"href":"https:\/\/tradegoai.app\/ja\/wp-json\/wp\/v2\/tool_categories?post=9868"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}