{"product_id":"cogs","title":"Cost of Goods Sold Calculator","description":"\u003cstyle\u003e\n.cogs-calculator {\n  --ink: #0f172a;\n  --muted: #475569;\n  --border: #e2e8f0;\n  --surface: #ffffff;\n  --tint: #f8fafc;\n  --primary: #1d4ed8;\n  --accent: #c2410c;\n  --accent-hover: #9a3412;\n  --chart-1: #1e40af;\n  --chart-2: #0d9488;\n  --chart-3: #7c3aed;\n  --chart-4: #be185d;\n  --chart-5: #334155;\n  container-type: inline-size;\n  width: 100%;\n  max-width: 1200px;\n  margin: 0 auto;\n  color: var(--ink);\n  background: var(--surface);\n  border: 1px solid var(--border);\n  border-radius: 8px;\n  box-shadow: 0 1px 2px rgba(15, 23, 42, .06);\n  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, \"Segoe UI\", sans-serif;\n  font-size: 15px;\n  line-height: 1.55;\n  overflow-wrap: anywhere;\n}\n.cogs-calculator,\n.cogs-calculator *,\n.cogs-calculator *::before,\n.cogs-calculator *::after {\n  box-sizing: border-box;\n}\n.cogs-calculator * {\n  min-width: 0;\n}\n.cogs-calculator h2,\n.cogs-calculator h3,\n.cogs-calculator p {\n  margin-top: 0;\n}\n.cogs-calculator h2 {\n  margin-bottom: 8px;\n  font-size: 24px;\n  line-height: 1.25;\n  font-weight: 700;\n  letter-spacing: -.02em;\n}\n.cogs-calculator h3 {\n  margin-bottom: 12px;\n  font-size: 18px;\n  line-height: 1.35;\n  font-weight: 650;\n}\n.cogs-calculator a {\n  color: var(--primary);\n  text-decoration-thickness: 1px;\n  text-underline-offset: 2px;\n}\n.cogs-calculator a:hover {\n  text-decoration-thickness: 2px;\n}\n.cogs-calculator button,\n.cogs-calculator input {\n  font: inherit;\n}\n.cogs-calculator button {\n  min-height: 44px;\n  border-radius: 6px;\n  cursor: pointer;\n}\n.cogs-calculator button:focus-visible,\n.cogs-calculator input:focus-visible,\n.cogs-calculator a:focus-visible {\n  outline: 3px solid rgba(29, 78, 216, .35);\n  outline-offset: 2px;\n}\n.cogs-header {\n  padding: 24px 24px 16px;\n  border-bottom: 1px solid var(--border);\n  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);\n  border-radius: 8px 8px 0 0;\n}\n.cogs-subtitle {\n  max-width: 760px;\n  margin-bottom: 16px;\n  color: var(--muted);\n  font-size: 15px;\n}\n.cogs-pills {\n  display: flex;\n  flex-wrap: wrap;\n  gap: 8px;\n}\n.cogs-pill {\n  display: inline-flex;\n  align-items: center;\n  gap: 6px;\n  min-height: 32px;\n  padding: 4px 10px;\n  color: #334155;\n  background: var(--tint);\n  border: 1px solid var(--border);\n  border-radius: 999px;\n  font-size: 13px;\n  font-weight: 500;\n  font-variant-numeric: tabular-nums;\n}\n.cogs-pill strong {\n  color: var(--ink);\n  font-weight: 700;\n}\n.cogs-toolbar {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  gap: 12px;\n  padding: 16px 24px;\n  border-bottom: 1px solid var(--border);\n  background: var(--tint);\n}\n.cogs-download,\n.cogs-reset {\n  display: inline-flex;\n  align-items: center;\n  justify-content: center;\n  gap: 10px;\n  padding: 12px 18px;\n  border: 1px solid transparent;\n  font-size: 15px;\n  font-weight: 700;\n  white-space: nowrap;\n  transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease, transform .05s ease;\n}\n.cogs-download {\n  color: #ffffff;\n  background: var(--accent);\n  border-color: var(--accent);\n}\n.cogs-download:hover {\n  background: var(--accent-hover);\n  border-color: var(--accent-hover);\n  box-shadow: 0 2px 5px rgba(154, 52, 18, .22);\n}\n.cogs-download:active,\n.cogs-reset:active {\n  transform: translateY(1px);\n}\n.cogs-reset {\n  color: var(--ink);\n  background: var(--surface);\n  border-color: #cbd5e1;\n}\n.cogs-reset:hover {\n  background: #f1f5f9;\n  border-color: #94a3b8;\n  box-shadow: 0 2px 5px rgba(15, 23, 42, .08);\n}\n.cogs-button-icon {\n  width: 18px;\n  height: 18px;\n  flex: 0 0 18px;\n}\n.cogs-workspace {\n  display: grid;\n  grid-template-columns: 1fr;\n  gap: 24px;\n  padding: 24px;\n  border-bottom: 1px solid var(--border);\n}\n.cogs-panel,\n.cogs-chart-card,\n.cogs-table-card {\n  min-width: 0;\n  padding: 20px;\n  background: var(--surface);\n  border: 1px solid var(--border);\n  border-radius: 8px;\n  box-shadow: 0 1px 2px rgba(15, 23, 42, .06);\n}\n.cogs-panel-intro,\n.cogs-section-intro {\n  margin-bottom: 16px;\n  color: var(--muted);\n  font-size: 14px;\n}\n.cogs-fields {\n  display: grid;\n  grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));\n  gap: 16px;\n}\n.cogs-field {\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n}\n.cogs-field label {\n  color: var(--ink);\n  font-size: 14px;\n  font-weight: 600;\n}\n.cogs-input-wrap {\n  position: relative;\n}\n.cogs-input-prefix {\n  position: absolute;\n  left: 12px;\n  top: 50%;\n  transform: translateY(-50%);\n  color: #334155;\n  font-size: 15px;\n  font-weight: 600;\n  pointer-events: none;\n}\n.cogs-input {\n  width: 100%;\n  min-height: 44px;\n  padding: 10px 12px 10px 30px;\n  color: var(--ink);\n  background: #ffffff;\n  border: 1px solid #cbd5e1;\n  border-radius: 6px;\n  font-size: 15px;\n  font-variant-numeric: tabular-nums;\n}\n.cogs-input:hover {\n  border-color: #94a3b8;\n}\n.cogs-input[aria-invalid=\"true\"] {\n  border-color: #b91c1c;\n  box-shadow: 0 0 0 1px #b91c1c;\n}\n.cogs-helper {\n  min-height: 40px;\n  margin: 0;\n  color: var(--muted);\n  font-size: 13px;\n  font-weight: 500;\n  line-height: 1.45;\n}\n.cogs-error {\n  min-height: 20px;\n  margin: -2px 0 0;\n  color: #b91c1c;\n  font-size: 13px;\n  font-weight: 600;\n}\n.cogs-formula {\n  display: grid;\n  gap: 8px;\n  margin-top: 16px;\n  padding: 12px;\n  color: #1e293b;\n  background: #eff6ff;\n  border: 1px solid #bfdbfe;\n  border-radius: 6px;\n  font-size: 13px;\n}\n.cogs-formula strong {\n  font-weight: 700;\n}\n.cogs-formula-code {\n  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;\n  font-variant-numeric: tabular-nums;\n}\n.cogs-results {\n  display: flex;\n  flex-direction: column;\n  gap: 16px;\n}\n.cogs-primary-result {\n  padding: 20px;\n  color: #ffffff;\n  background: #0f172a;\n  border-radius: 8px;\n}\n.cogs-primary-label {\n  margin-bottom: 8px;\n  color: #cbd5e1;\n  font-size: 13px;\n  font-weight: 600;\n  letter-spacing: .02em;\n  text-transform: uppercase;\n}\n.cogs-primary-value {\n  margin-bottom: 8px;\n  font-size: 30px;\n  line-height: 1.15;\n  font-weight: 700;\n  font-variant-numeric: tabular-nums;\n  overflow-wrap: anywhere;\n}\n.cogs-primary-note {\n  margin: 0;\n  color: #e2e8f0;\n  font-size: 13px;\n}\n.cogs-metrics {\n  display: grid;\n  grid-template-columns: repeat(2, minmax(0, 1fr));\n  gap: 12px;\n}\n.cogs-metric {\n  padding: 16px;\n  background: var(--tint);\n  border: 1px solid var(--border);\n  border-radius: 8px;\n}\n.cogs-metric-label {\n  margin-bottom: 6px;\n  color: var(--muted);\n  font-size: 13px;\n  font-weight: 600;\n}\n.cogs-metric-value {\n  color: var(--ink);\n  font-size: 20px;\n  line-height: 1.25;\n  font-weight: 700;\n  font-variant-numeric: tabular-nums;\n  overflow-wrap: anywhere;\n}\n.cogs-status {\n  padding: 12px;\n  color: #334155;\n  background: #f8fafc;\n  border: 1px solid var(--border);\n  border-radius: 6px;\n  font-size: 13px;\n  font-weight: 500;\n}\n.cogs-status[data-tone=\"warning\"] {\n  color: #7f1d1d;\n  background: #fef2f2;\n  border-color: #fecaca;\n}\n.cogs-breakdown,\n.cogs-table-section {\n  padding: 24px;\n  border-bottom: 1px solid var(--border);\n}\n.cogs-chart-card,\n.cogs-table-card {\n  width: 100%;\n}\n.cogs-chart-heading,\n.cogs-table-heading {\n  margin-bottom: 4px;\n}\n.cogs-chart-interpretation {\n  margin-bottom: 20px;\n  color: var(--muted);\n  font-size: 14px;\n}\n.cogs-chart-cluster {\n  display: grid;\n  grid-template-columns: 1fr;\n  align-items: center;\n  justify-content: center;\n  gap: 20px;\n  width: 100%;\n  max-width: 900px;\n  margin: 0 auto;\n}\n.cogs-chart-plot {\n  width: 100%;\n  min-height: 300px;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n}\n.cogs-chart-svg {\n  display: block;\n  width: 100%;\n  max-width: 620px;\n  height: 300px;\n  min-height: 0;\n  overflow: visible;\n}\n.cogs-chart-empty {\n  width: 100%;\n  max-width: 560px;\n  padding: 24px;\n  color: var(--muted);\n  background: var(--tint);\n  border: 1px dashed #94a3b8;\n  border-radius: 6px;\n  text-align: center;\n  font-size: 14px;\n  font-weight: 600;\n}\n.cogs-chart-legend {\n  display: grid;\n  gap: 10px;\n  align-content: center;\n}\n.cogs-legend-row {\n  display: grid;\n  grid-template-columns: 12px minmax(90px, max-content) max-content;\n  align-items: center;\n  justify-content: start;\n  column-gap: 10px;\n  row-gap: 4px;\n  color: #334155;\n  font-size: 13px;\n  font-weight: 500;\n  font-variant-numeric: tabular-nums;\n}\n.cogs-legend-swatch {\n  width: 12px;\n  height: 12px;\n  border-radius: 2px;\n}\n.cogs-legend-name {\n  font-weight: 600;\n}\n.cogs-legend-value {\n  color: var(--ink);\n  font-weight: 700;\n  white-space: nowrap;\n}\n.cogs-chart-caption,\n.cogs-table-note {\n  margin-top: 16px;\n  padding: 10px 12px;\n  color: #334155;\n  background: var(--tint);\n  border: 1px solid var(--border);\n  border-radius: 6px;\n  font-size: 13px;\n  font-weight: 500;\n}\n.cogs-chart-summary {\n  position: absolute;\n  width: 1px;\n  height: 1px;\n  padding: 0;\n  margin: -1px;\n  overflow: hidden;\n  clip: rect(0, 0, 0, 0);\n  white-space: nowrap;\n  border: 0;\n}\n.cogs-safe-stack .cogs-chart-cluster {\n  grid-template-columns: 1fr;\n  gap: 24px;\n  max-width: 680px;\n}\n.cogs-safe-stack .cogs-chart-plot {\n  min-height: 280px;\n}\n.cogs-safe-stack .cogs-chart-legend {\n  justify-content: center;\n}\n.cogs-safe-stack .cogs-chart-caption {\n  margin-top: 20px;\n}\n.cogs-table-overflow {\n  width: 100%;\n  overflow-x: auto;\n  border: 1px solid var(--border);\n  border-radius: 6px;\n  scrollbar-gutter: stable;\n}\n.cogs-table {\n  width: 100%;\n  min-width: 720px;\n  border-collapse: collapse;\n  font-variant-numeric: tabular-nums;\n}\n.cogs-table th,\n.cogs-table td {\n  padding: 12px;\n  border-bottom: 1px solid var(--border);\n  text-align: left;\n  vertical-align: top;\n  font-size: 13px;\n}\n.cogs-table th {\n  color: #ffffff;\n  background: #1e293b;\n  font-weight: 700;\n}\n.cogs-table tbody tr:last-child td {\n  border-bottom: 0;\n}\n.cogs-table tbody tr:nth-child(even) td {\n  background: #f8fafc;\n}\n.cogs-table .cogs-num {\n  text-align: right;\n  white-space: nowrap;\n}\n.cogs-table .cogs-total-row td {\n  color: var(--ink);\n  background: #eff6ff;\n  font-weight: 700;\n}\n.cogs-safe-table-stack .cogs-table-note {\n  margin-top: 20px;\n}\n.cogs-education {\n  padding: 32px 24px;\n}\n.cogs-education-inner {\n  max-width: 900px;\n  margin: 0 auto;\n}\n.cogs-education h2 {\n  margin-top: 32px;\n}\n.cogs-education h2:first-child {\n  margin-top: 0;\n}\n.cogs-education h3 {\n  margin-top: 24px;\n}\n.cogs-education p,\n.cogs-education li {\n  color: #334155;\n}\n.cogs-education ul {\n  margin: 0 0 16px;\n  padding-left: 22px;\n}\n.cogs-education li + li {\n  margin-top: 8px;\n}\n.cogs-equation {\n  margin: 16px 0;\n  padding: 16px;\n  color: #0f172a;\n  background: #eff6ff;\n  border-left: 4px solid var(--primary);\n  border-radius: 0 6px 6px 0;\n  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;\n  font-size: 14px;\n  font-weight: 700;\n  font-variant-numeric: tabular-nums;\n}\n.cogs-disclaimer {\n  margin-top: 24px;\n  padding: 12px;\n  color: var(--muted);\n  background: var(--tint);\n  border: 1px solid var(--border);\n  border-radius: 6px;\n  font-size: 13px;\n}\n@container (min-width: 640px) {\n  .cogs-chart-cluster {\n    grid-template-columns: minmax(300px, 620px) max-content;\n    gap: 24px;\n  }\n  .cogs-chart-legend {\n    min-width: 220px;\n  }\n}\n@container (min-width: 900px) {\n  .cogs-workspace {\n    grid-template-columns: minmax(0, 1.08fr) minmax(340px, .92fr);\n    align-items: start;\n  }\n}\n@container (max-width: 639px) {\n  .cogs-header,\n  .cogs-toolbar,\n  .cogs-workspace,\n  .cogs-breakdown,\n  .cogs-table-section,\n  .cogs-education {\n    padding-left: 16px;\n    padding-right: 16px;\n  }\n  .cogs-panel,\n  .cogs-chart-card,\n  .cogs-table-card {\n    padding: 16px;\n  }\n  .cogs-metrics {\n    grid-template-columns: 1fr;\n  }\n  .cogs-toolbar {\n    align-items: stretch;\n  }\n  .cogs-download,\n  .cogs-reset {\n    width: 100%;\n  }\n  .cogs-chart-cluster {\n    gap: 16px;\n  }\n  .cogs-chart-plot {\n    min-height: 280px;\n  }\n  .cogs-chart-svg {\n    height: 280px;\n    min-height: 0;\n  }\n  .cogs-chart-caption,\n  .cogs-table-note {\n    margin-top: 16px;\n  }\n}\n\u003c\/style\u003e\n\u003cdiv class=\"cogs-calculator\" data-calculator-root\u003e\n  \u003cheader class=\"cogs-header\"\u003e\n    \u003ch2\u003eCost of Goods Sold Calculator\u003c\/h2\u003e\n    \u003cp class=\"cogs-subtitle\"\u003eCalculate COGS from beginning inventory, purchases, and ending inventory, then review the inventory-cost bridge and export the current analysis to Excel.\u003c\/p\u003e\n    \u003cdiv class=\"cogs-pills\" aria-label=\"Live calculation summary\"\u003e\n      \u003cspan class=\"cogs-pill\"\u003eGoods available \u003cstrong class=\"cogs-pill-available\"\u003e$35,000.00\u003c\/strong\u003e\u003c\/span\u003e\n      \u003cspan class=\"cogs-pill\"\u003eCOGS \u003cstrong class=\"cogs-pill-cogs\"\u003e$27,000.00\u003c\/strong\u003e\u003c\/span\u003e\n      \u003cspan class=\"cogs-pill\"\u003eCost released \u003cstrong class=\"cogs-pill-release\"\u003e77.14%\u003c\/strong\u003e\u003c\/span\u003e\n      \u003cspan class=\"cogs-pill\"\u003eEnding share \u003cstrong class=\"cogs-pill-ending\"\u003e22.86%\u003c\/strong\u003e\u003c\/span\u003e\n    \u003c\/div\u003e\n  \u003c\/header\u003e\n\n  \u003cdiv class=\"cogs-toolbar\" role=\"toolbar\" aria-label=\"Calculator actions\"\u003e\n    \u003cbutton class=\"cogs-download\" type=\"button\"\u003e\n      \u003csvg class=\"cogs-button-icon\" viewbox=\"0 0 24 24\" aria-hidden=\"true\" focusable=\"false\"\u003e\n        \u003cpath fill=\"currentColor\" d=\"M5 2h10l4 4v16H5V2zm9 2v3h3l-3-3zM8 11h2l2 3 2-3h2l-3 4 3 4h-2l-2-3-2 3H8l3-4-3-4z\"\u003e\u003c\/path\u003e\n      \u003c\/svg\u003e\n      \u003cspan\u003eDownload Excel\u003c\/span\u003e\n    \u003c\/button\u003e\n    \u003cbutton class=\"cogs-reset\" type=\"button\"\u003eReset\u003c\/button\u003e\n  \u003c\/div\u003e\n\n  \u003cdiv class=\"cogs-workspace\"\u003e\n    \u003csection class=\"cogs-panel\" aria-labelledby=\"cogs-inputs-heading\"\u003e\n      \u003ch3 id=\"cogs-inputs-heading\"\u003eInventory inputs\u003c\/h3\u003e\n      \u003cp class=\"cogs-panel-intro\"\u003eUse values from the same accounting period and the same inventory valuation method.\u003c\/p\u003e\n      \u003cdiv class=\"cogs-fields\"\u003e\n        \u003cdiv class=\"cogs-field\"\u003e\n          \u003clabel for=\"cogs-beginning\"\u003eBeginning inventory\u003c\/label\u003e\n          \u003cdiv class=\"cogs-input-wrap\"\u003e\n            \u003cspan class=\"cogs-input-prefix\" aria-hidden=\"true\"\u003e$\u003c\/span\u003e\n            \u003cinput class=\"cogs-input\" id=\"cogs-beginning\" name=\"cogs-beginning\" type=\"text\" inputmode=\"decimal\" autocomplete=\"off\" value=\"10,000.00\" aria-describedby=\"cogs-beginning-help cogs-beginning-error\"\u003e\n          \u003c\/div\u003e\n          \u003cp class=\"cogs-helper\" id=\"cogs-beginning-help\"\u003eInventory value at the start of the period. It normally equals the previous period's ending inventory.\u003c\/p\u003e\n          \u003cp class=\"cogs-error\" id=\"cogs-beginning-error\" aria-live=\"polite\"\u003e\u003c\/p\u003e\n        \u003c\/div\u003e\n        \u003cdiv class=\"cogs-field\"\u003e\n          \u003clabel for=\"cogs-purchases\"\u003ePurchases\u003c\/label\u003e\n          \u003cdiv class=\"cogs-input-wrap\"\u003e\n            \u003cspan class=\"cogs-input-prefix\" aria-hidden=\"true\"\u003e$\u003c\/span\u003e\n            \u003cinput class=\"cogs-input\" id=\"cogs-purchases\" name=\"cogs-purchases\" type=\"text\" inputmode=\"decimal\" autocomplete=\"off\" value=\"25,000.00\" aria-describedby=\"cogs-purchases-help cogs-purchases-error\"\u003e\n          \u003c\/div\u003e\n          \u003cp class=\"cogs-helper\" id=\"cogs-purchases-help\"\u003eInventory acquired or produced during the period, including directly attributable costs under your accounting policy.\u003c\/p\u003e\n          \u003cp class=\"cogs-error\" id=\"cogs-purchases-error\" aria-live=\"polite\"\u003e\u003c\/p\u003e\n        \u003c\/div\u003e\n        \u003cdiv class=\"cogs-field\"\u003e\n          \u003clabel for=\"cogs-ending\"\u003eEnding inventory\u003c\/label\u003e\n          \u003cdiv class=\"cogs-input-wrap\"\u003e\n            \u003cspan class=\"cogs-input-prefix\" aria-hidden=\"true\"\u003e$\u003c\/span\u003e\n            \u003cinput class=\"cogs-input\" id=\"cogs-ending\" name=\"cogs-ending\" type=\"text\" inputmode=\"decimal\" autocomplete=\"off\" value=\"8,000.00\" aria-describedby=\"cogs-ending-help cogs-ending-error\"\u003e\n          \u003c\/div\u003e\n          \u003cp class=\"cogs-helper\" id=\"cogs-ending-help\"\u003eInventory still on hand at period end. It cannot exceed goods available without an adjustment or data mismatch.\u003c\/p\u003e\n          \u003cp class=\"cogs-error\" id=\"cogs-ending-error\" aria-live=\"polite\"\u003e\u003c\/p\u003e\n        \u003c\/div\u003e\n      \u003c\/div\u003e\n      \u003cdiv class=\"cogs-formula\"\u003e\n        \u003cstrong\u003eFormula\u003c\/strong\u003e\n        \u003cspan class=\"cogs-formula-code\"\u003eCOGS = beginning inventory + purchases − ending inventory\u003c\/span\u003e\n      \u003c\/div\u003e\n    \u003c\/section\u003e\n\n    \u003csection class=\"cogs-panel cogs-results\" aria-labelledby=\"cogs-results-heading\"\u003e\n      \u003ch3 id=\"cogs-results-heading\"\u003eLive results\u003c\/h3\u003e\n      \u003cdiv class=\"cogs-primary-result\"\u003e\n        \u003cdiv class=\"cogs-primary-label\"\u003eCost of goods sold\u003c\/div\u003e\n        \u003cdiv class=\"cogs-primary-value\" aria-live=\"polite\"\u003e$27,000.00\u003c\/div\u003e\n        \u003cp class=\"cogs-primary-note\"\u003eDirect inventory cost recognized for goods sold during the period.\u003c\/p\u003e\n      \u003c\/div\u003e\n      \u003cdiv class=\"cogs-metrics\"\u003e\n        \u003cdiv class=\"cogs-metric\"\u003e\n          \u003cdiv class=\"cogs-metric-label\"\u003eGoods available for sale\u003c\/div\u003e\n          \u003cdiv class=\"cogs-metric-value cogs-available-value\"\u003e$35,000.00\u003c\/div\u003e\n        \u003c\/div\u003e\n        \u003cdiv class=\"cogs-metric\"\u003e\n          \u003cdiv class=\"cogs-metric-label\"\u003eInventory cost released\u003c\/div\u003e\n          \u003cdiv class=\"cogs-metric-value cogs-release-value\"\u003e77.14%\u003c\/div\u003e\n        \u003c\/div\u003e\n        \u003cdiv class=\"cogs-metric\"\u003e\n          \u003cdiv class=\"cogs-metric-label\"\u003eEnding inventory share\u003c\/div\u003e\n          \u003cdiv class=\"cogs-metric-value cogs-ending-share-value\"\u003e22.86%\u003c\/div\u003e\n        \u003c\/div\u003e\n        \u003cdiv class=\"cogs-metric\"\u003e\n          \u003cdiv class=\"cogs-metric-label\"\u003ePurchases share\u003c\/div\u003e\n          \u003cdiv class=\"cogs-metric-value cogs-purchases-share-value\"\u003e71.43%\u003c\/div\u003e\n        \u003c\/div\u003e\n      \u003c\/div\u003e\n      \u003cdiv class=\"cogs-status\" data-tone=\"neutral\"\u003eThe inputs reconcile: ending inventory plus COGS equals goods available for sale.\u003c\/div\u003e\n    \u003c\/section\u003e\n  \u003c\/div\u003e\n\n  \u003csection class=\"cogs-breakdown\" aria-labelledby=\"cogs-chart-heading\"\u003e\n    \u003cdiv class=\"cogs-chart-card\" data-cogs-chart-card\u003e\n      \u003ch3 class=\"cogs-chart-heading\" id=\"cogs-chart-heading\"\u003eInventory cost bridge\u003c\/h3\u003e\n      \u003cp class=\"cogs-chart-interpretation\"\u003eCompare the opening balance and purchases with the cost recognized and inventory retained.\u003c\/p\u003e\n      \u003cdiv class=\"cogs-chart-cluster\"\u003e\n        \u003cdiv class=\"cogs-chart-plot\" data-cogs-chart-plot\u003e\u003c\/div\u003e\n        \u003cdiv class=\"cogs-chart-legend\" aria-label=\"Chart legend\"\u003e\u003c\/div\u003e\n      \u003c\/div\u003e\n      \u003cdiv class=\"cogs-chart-caption\"\u003e\u003c\/div\u003e\n      \u003cdiv class=\"cogs-chart-summary\" role=\"img\" aria-label=\"Inventory cost bridge summary\"\u003e\u003c\/div\u003e\n    \u003c\/div\u003e\n  \u003c\/section\u003e\n\n  \u003csection class=\"cogs-table-section\" aria-labelledby=\"cogs-table-heading\"\u003e\n    \u003cdiv class=\"cogs-table-card\" data-cogs-table-card\u003e\n      \u003ch3 class=\"cogs-table-heading\" id=\"cogs-table-heading\"\u003eCalculation detail\u003c\/h3\u003e\n      \u003cp class=\"cogs-section-intro\"\u003eThe bridge below cross-checks each input and the final COGS result.\u003c\/p\u003e\n      \u003cdiv class=\"cogs-table-overflow\"\u003e\n        \u003ctable class=\"cogs-table\"\u003e\n          \u003cthead\u003e\n            \u003ctr\u003e\n              \u003cth scope=\"col\"\u003eLine item\u003c\/th\u003e\n              \u003cth scope=\"col\"\u003eOperation\u003c\/th\u003e\n              \u003cth class=\"cogs-num\" scope=\"col\"\u003eAmount\u003c\/th\u003e\n              \u003cth class=\"cogs-num\" scope=\"col\"\u003eShare of goods available\u003c\/th\u003e\n              \u003cth scope=\"col\"\u003eInterpretation\u003c\/th\u003e\n            \u003c\/tr\u003e\n          \u003c\/thead\u003e\n          \u003ctbody class=\"cogs-table-body\"\u003e\u003c\/tbody\u003e\n        \u003c\/table\u003e\n      \u003c\/div\u003e\n      \u003cdiv class=\"cogs-table-note\"\u003eA valid bridge satisfies: beginning inventory + purchases = COGS + ending inventory. Small differences in accounting reports can arise from rounding, write-downs, returns, freight treatment, or period cut-off adjustments.\u003c\/div\u003e\n    \u003c\/div\u003e\n  \u003c\/section\u003e\n\n  \u003csection class=\"cogs-education\"\u003e\n    \u003cdiv class=\"cogs-education-inner\"\u003e\n      \u003ch2\u003eWhat this COGS calculator estimates\u003c\/h2\u003e\n      \u003cp\u003eCost of goods sold, commonly shortened to COGS, is the inventory cost assigned to products that were sold during an accounting period. This calculator applies the standard inventory roll-forward: start with inventory on hand, add purchases or production costs added during the period, and subtract inventory still on hand at the end. The remainder is the cost released from the balance sheet into the income statement.\u003c\/p\u003e\n      \u003cp\u003eCOGS is not the same as total operating expense. It generally includes costs directly connected to acquiring or producing inventory, while selling, administrative, financing, and many general overhead costs are reported elsewhere. The exact boundary depends on the business, its accounting framework, and its consistently applied inventory policy.\u003c\/p\u003e\n\n      \u003ch2\u003eHow to enter each field\u003c\/h2\u003e\n      \u003ch3\u003eBeginning inventory\u003c\/h3\u003e\n      \u003cp\u003eEnter the carrying value of inventory at the first day of the reporting period. For a continuous set of accounts, this should normally match the previous period's ending inventory. Use a non-negative dollar amount. A higher beginning balance increases goods available for sale and, all else equal, increases COGS. A common mistake is mixing a quantity count with a monetary value or using a balance from a different valuation method.\u003c\/p\u003e\n      \u003ch3\u003ePurchases\u003c\/h3\u003e\n      \u003cp\u003eEnter inventory acquired or produced during the same period. Depending on the accounting policy, this may include purchase price, direct labor, inbound freight, and allocated production overhead, net of returns, discounts, and allowances. Use the net cost added to inventory, not sales revenue. Higher purchases increase goods available and usually increase COGS unless the added inventory remains in ending stock.\u003c\/p\u003e\n      \u003ch3\u003eEnding inventory\u003c\/h3\u003e\n      \u003cp\u003eEnter the carrying value of unsold inventory at the close of the period. This value is subtracted because it remains an asset rather than becoming current-period expense. A higher ending balance lowers COGS; a lower ending balance raises COGS. Ending inventory should not exceed beginning inventory plus purchases unless the records omit a transfer, production addition, revaluation, or other adjustment.\u003c\/p\u003e\n\n      \u003ch2\u003eFormula and practical interpretation\u003c\/h2\u003e\n      \u003cdiv class=\"cogs-equation\"\u003eCOGS = Beginning inventory + Purchases − Ending inventory\u003c\/div\u003e\n      \u003cp\u003eThe first two terms create \u003cstrong\u003egoods available for sale\u003c\/strong\u003e. The final subtraction divides that pool into two destinations: cost recognized for items sold and inventory retained for future periods. For the initial example, $10,000 of beginning inventory plus $25,000 of purchases creates $35,000 available. Subtracting $8,000 of ending inventory produces $27,000 of COGS.\u003c\/p\u003e\n      \u003cp\u003eThe calculator also displays two proportions. \u003cstrong\u003eInventory cost released\u003c\/strong\u003e is COGS divided by goods available. It indicates how much of the available inventory cost moved to expense during the period. \u003cstrong\u003eEnding inventory share\u003c\/strong\u003e is ending inventory divided by goods available. The two percentages should add to 100% when the bridge is valid.\u003c\/p\u003e\n\n      \u003ch2\u003eHow to read the chart and table\u003c\/h2\u003e\n      \u003cp\u003eThe bar chart compares four amounts on one scale: beginning inventory, purchases, COGS, and ending inventory. It is a comparison chart rather than a pie chart, so the bars are not intended to add to one combined total. The legend reports each exact amount, while the accessible summary exposes the same values to screen readers.\u003c\/p\u003e\n      \u003cp\u003eThe calculation table follows the accounting bridge line by line. Beginning inventory and purchases are additions. Goods available is their subtotal. Ending inventory is the deduction. The final row is COGS. The percentage column uses goods available as the common denominator, making it easier to see how much cost was sold versus retained.\u003c\/p\u003e\n\n      \u003ch2\u003eWhat drives a high or low COGS result\u003c\/h2\u003e\n      \u003cul\u003e\n        \u003cli\u003e\n\u003cstrong\u003eHigher beginning inventory or purchases:\u003c\/strong\u003e raises the cost pool and generally raises COGS unless ending inventory rises by the same amount.\u003c\/li\u003e\n        \u003cli\u003e\n\u003cstrong\u003eHigher ending inventory:\u003c\/strong\u003e lowers current-period COGS because more cost remains on the balance sheet.\u003c\/li\u003e\n        \u003cli\u003e\n\u003cstrong\u003eZero goods available:\u003c\/strong\u003e produces zero COGS and no meaningful percentage ratios.\u003c\/li\u003e\n        \u003cli\u003e\n\u003cstrong\u003eEnding inventory above goods available:\u003c\/strong\u003e signals inconsistent inputs; the calculator suppresses the negative result and asks you to correct the data.\u003c\/li\u003e\n      \u003c\/ul\u003e\n      \u003cp\u003eA high COGS is not automatically bad. It can reflect higher sales volume, input inflation, a low-margin product mix, or inventory write-downs. A low COGS can reflect lower volume, favorable sourcing, more ending inventory, or a change in product mix. COGS is best interpreted alongside revenue, gross profit, unit volume, inventory turnover, and a consistent period-over-period accounting policy.\u003c\/p\u003e\n\n      \u003ch2\u003eCommon mistakes and accounting cautions\u003c\/h2\u003e\n      \u003cp\u003eUse the same time period for all three inputs. Do not combine monthly beginning inventory with annual purchases and quarterly ending inventory. Avoid mixing FIFO, LIFO, weighted-average, standard-cost, or specific-identification values within one bridge. Confirm whether freight-in, purchase discounts, returns, production overhead, obsolete inventory, and shrinkage are included consistently.\u003c\/p\u003e\n      \u003cp\u003eInventory accounting and tax treatment can vary by jurisdiction and entity type. For additional context, review the \u003ca href=\"https:\/\/www.irs.gov\/publications\/p538\" target=\"_blank\" rel=\"noopener noreferrer\"\u003eIRS guidance on accounting periods and methods\u003c\/a\u003e, the \u003ca href=\"https:\/\/www.irs.gov\/publications\/p334\" target=\"_blank\" rel=\"noopener noreferrer\"\u003eIRS Tax Guide for Small Business\u003c\/a\u003e, the \u003ca href=\"https:\/\/www.sec.gov\/oiea\/investor-alerts-and-bulletins\/ib_financialstatements\" target=\"_blank\" rel=\"noopener noreferrer\"\u003eSEC introduction to financial statements\u003c\/a\u003e, and the \u003ca href=\"https:\/\/www.investopedia.com\/terms\/c\/cogs.asp\" target=\"_blank\" rel=\"noopener noreferrer\"\u003eInvestopedia overview of COGS\u003c\/a\u003e.\u003c\/p\u003e\n      \u003cp class=\"cogs-disclaimer\"\u003eThis calculator is an educational planning tool. It does not replace professional accounting, tax, audit, or legal advice, and it does not determine which costs your reporting framework permits in inventory.\u003c\/p\u003e\n    \u003c\/div\u003e\n  \u003c\/section\u003e\n\u003c\/div\u003e","brand":"FinancialModelsLab","offers":[{"title":"Default Title","offer_id":49909482291443,"sku":"cogs","price":0.0,"currency_code":"USD","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0522\/6191\/2762\/files\/cogs.webp?v=1783935407","url":"https:\/\/financialmodelslab.com\/products\/cogs","provider":"Financial Models Lab","version":"1.0","type":"link"}