{"id":64534,"date":"2024-12-04T09:35:59","date_gmt":"2024-12-04T09:35:59","guid":{"rendered":"https:\/\/www.hashmicro.com\/blog\/?p=64534"},"modified":"2025-07-23T08:43:17","modified_gmt":"2025-07-23T08:43:17","slug":"safety-stock-formula","status":"publish","type":"post","link":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/","title":{"rendered":"Understanding Safety Stock Formula for Better Inventory Control"},"content":{"rendered":"<p><span style=\"font-weight: 400;\">The safety stock formula helps businesses maintain extra inventory to prevent stockouts due to unexpected demand or delivery delays. This ensures that you have enough products on hand, without overstocking, to balance supply and demand effectively.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Managing safety stock is essential for smooth business operations. <\/span><a href=\"https:\/\/www.hashmicro.com\/inventory\"><span style=\"font-weight: 400;\">Inventory management software <\/span><\/a><span style=\"font-weight: 400;\">makes it easier to calculate and track safety stock in real-time. Therefore, businesses can ensure accurate inventory management while minimizing stockouts or excess inventory.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Thus, in this article, we will discuss what safety stock is, safety stock formula example, how to calculate it, and how HashMicro can optimize your inventory. Additionally, we\u2019ll explore the importance of safety stock, the reorder point formula, and the risks of holding too much inventory.<\/span><\/p>\n<table style=\"border-collapse: collapse; background-color: #fffacd; border-radius: 25px 25px 25px 25px;\" width=\"100%\">\n<tbody>\n<tr>\n<td style=\"padding: 15px; border: none;\">\n<h3 style=\"margin-bottom: 10px;\"><span style=\"background-color: #990000; color: #ffffff; padding: 5px;\"><b>Key Takeaways<\/b><\/span><\/h3>\n<ul>\n<li><span style=\"font-weight: 400;\">The <a href=\"#ssf\">safety stock formula<\/a> calculates the additional inventory required to prevent stockouts due to changes in demand or delays in delivery.<\/span><\/li>\n<li><span style=\"font-weight: 400;\"><a href=\"#lt\">Lead time<\/a> demand is the total quantity of a product anticipated to be sold or consumed during the lead time, which is the time between ordering and receiving the products.<\/span><\/li>\n<li><span style=\"font-weight: 400;\">You can use different methods to <a href=\"#calculate\">calculate safety stock<\/a> to prevent stockouts and optimise inventory levels.<\/span><\/li>\n<li><span style=\"font-weight: 400;\">Safety stock <a href=\"#important\">is important<\/a> for ensuring smooth operations and fulfilling customer demand, even during unforeseen circumstances.<\/span><\/li>\n<li><span style=\"font-weight: 400;\">Use the <a href=\"#rop\">reorder point (ROP)<\/a> formula to determine the right moment to replenish your inventory to avoid stockouts<\/span><\/li>\n<li><span style=\"font-weight: 400;\">Although safety stock is important for avoiding stockouts, excessive inventory can create <a href=\"#risk\">various risks<\/a>.<\/span><\/li>\n<li><span style=\"font-weight: 400;\">HashMicro <\/span><a href=\"https:\/\/www.hashmicro.com\/inventory\"><span style=\"font-weight: 400;\">Inventory Management Software<\/span><\/a><span style=\"font-weight: 400;\"> is the best solution to automate safety stock calculation, optimize inventory management, and mitigate risks.<br \/>\n<style>\r\n.button-cta-custom {\r\n    background-color: #8a0e19;\r\n    color: #fff !important;\r\n    -webkit-transition: all .3s ease;\r\n    transition: all .3s ease;\r\n    padding: 8px 24px;\r\n    display: inline-block;\r\n    border-radius: 8px;\r\n    font-size: 16px;\r\n    font-weight: bold;\r\n}\r\n.button-cta-custom:hover{\r\n\tbackground-color:#991b26\t\t\r\n}\r\n<\/style>\r\n<a class=\"button-cta-custom\" href=\"https:\/\/www.hashmicro.com\/free-product-tour\/?medium=cta-button\" target=\"_blank\">Click Here to Get the Free Demo!<\/a><br \/>\n<\/span><\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><span style=\"font-weight: 400;\"><!-- <div id=\"toc_group_article\" style=''>\r\n\t<p style='font-size:25px;font-weight:bold; margin-bottom:0px'>\r\n\t\tTable of Content:\r\n\t<\/p>\r\n\t<ul id=\"list_toc\" class='list_toc'><\/ul>\r\n<\/div> -->\r\n\r\n<!-- <div class=\"dropdown-fixed-top\" id=\"dropdown-fixed-top\">\r\n\t<div class=\"row\">\r\n\t\t<p id=\"pilihDaftarIsi\">Table of Content<\/p>\r\n\t\t<p><i class=\"td-icon-menu-down\"><\/i><\/p>\r\n\t<\/div>\r\n\t\r\n\t<div>\r\n\t\t<ul id=\"list_toc_top\" class='list_toc'><\/ul>\r\n\t<\/div>\r\n<\/div> -->\r\n\r\n<div id=\"placeholder-toc\"><\/div>\r\n<div id=\"toc\">\r\n    <div class=\"header\">\r\n\t<span class=\"toc-title\" id=\"toc-title\">Table of Content<\/span>\t\r\n\t <i class=\"toc-icon\">\r\n        <svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"30\" height=\"30\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"#000\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"header-icon\">\r\n          <path d=\"m6 9 6 6 6-6\" \/>\r\n        <\/svg>\r\n      <\/i>\r\n\t<\/div>\r\n    <div class=\"list\">\r\n      <ul id=\"toc-list\"><\/ul>\r\n    <\/div>\r\n <\/div>\r\n\r\n<style>\r\n\t@media (max-width: 992px) {\r\n\t\t#toc_group_article {\r\n\t\t\tpadding-top: 24px;\r\n\t\t}\r\n\t}\r\n\t\r\n\t#list_toc_float {\r\n\t\tmax-height: calc(100vh - 250px);\r\n\t\toverflow-y: auto;\r\n\t}\r\n\t\r\n\t#list_toc_top {\r\n\t\tdisplay: none;\r\n\t\tbackground: #fff;\r\n\t\tmargin-bottom: 4px;\r\n\t}\r\n\t\r\n\t#list_toc_top li {\r\n\t\tdisplay: block;\r\n\t\tmargin-left: 0;\r\n\t\tlist-style: none;\r\n\t}\r\n\t\r\n\t#list_toc_top a {\r\n\t\tpadding: 5px;\r\n\t\tdisplay: block;\r\n\t}\r\n\t\r\n\t#list_toc_top.show {\r\n\t\tdisplay: block;\r\n\t}\r\n\r\n\t#list_toc_top a {\r\n\t\tcolor: #434343;\r\n\t\tborder-bottom: 1px solid #bbb;\r\n\t}\r\n\t\r\n\t.dropdown-fixed-top {\r\n\t\tposition: fixed;\r\n\t\ttop: 59px;\r\n\t\twidth: 100%;\r\n\t\tz-index: 99;\r\n\t\tborder-bottom: 2px solid #9c171e;\r\n\t\tpadding: 12px;\r\n\t\tbackground: #fff;\r\n\t\twidth: 100%;\r\n\t\tcursor: pointer;\r\n\t\tdisplay: none;\r\n\t\tleft: 0;\r\n\t\tbox-shadow: 0 -2px 7px 6px rgba(0, 0, 0, 0.17);\r\n\t}\r\n\t\r\n\t#dropdown-fixed-top.show {\r\n\t\tanimation: showAnim 0.5s ease;\r\n\t\tdisplay: block;\r\n\t\topacity: 1;\r\n\t}\r\n\t\r\n\t@keyframes showAnim {\r\n\t\tfrom {\r\n\t\t\tdisplay: none;\r\n\t\t\topacity: 0;\r\n\t\t}\r\n\t\tto {\r\n\t\t\tdisplay: block;\r\n\t\t\topacity: 1;\r\n\t\t}\r\n\t}\r\n\t\r\n\t.dropdown-fixed-top #list_toc_top {\r\n\t\tmax-height: calc(50vh - 110px);\r\n\t\toverflow-y: scroll;\r\n\t}\r\n\t\r\n\t.dropdown-fixed-top .row {\r\n\t\tdisplay: flex;\r\n\t\tjustify-content: space-between\r\n\t}\r\n\t\r\n\t.dropdown-fixed-top .row p {\r\n\t\tmargin-bottom: 0;\r\n\t}\r\n\t\r\n\t#pilihDaftarIsi {\r\n\t\tmax-width: 100%;\r\n\t\toverflow: hidden;\r\n\t\twhite-space: nowrap;\r\n\t}\r\n\t\r\n\t@media (min-width: 1018px) {\r\n\t\t.dropdown-fixed-top {\r\n\t\t\tdisplay: none;\r\n\t\t}\r\n\t}\r\n\t\r\n\t#list_toc li {margin-bottom: 0;margin-top: 5px;}\r\n\t#list_toc > li > ul {padding-left: 20px;margin-bottom: 0;}\r\n\t#list_toc{height:max-content;transition:ease-in-out}\r\n\t#list_toc li {margin-bottom: 0;margin-top: 5px;}\r\n\t#list_toc_float li.active > a {color:#b1252d;background: #ffe1e3;}\r\n\t#list_toc_top li.active > a {color:#b1252d;background: #ffe1e3;}\r\n\t#list_toc_float li a {padding:3px 7px}\r\n\t#list_toc_float li a {\r\n\t\tdisplay: block;\r\n\t\tcolor: #000;\r\n\t\tmargin-bottom: 6px;\r\n\t\tpadding-top: 2px;\r\n\t\tpadding-bottom: 2px;\r\n\t\ttransition: all 0.2s ease-in-out;\r\n\t\tfont-size: 15px;\r\n\t\tline-height: 18px;\r\n\t}\r\n\t#list_toc_float li{list-style:none;list-style-position:inside; margin-left:0;}\r\n\t#list_toc_float a:hover{color:#b1252d;}\r\n\t\r\n\t#toc_group_float{\r\n\t\tline-height: 24px;\r\n\t\tmax-height: calc(100vh - 100px);\r\n\t\toverflow: auto;\r\n\t\tz-index: 99;\r\n\t\tdisplay:none!important;\r\n\t\tbackground:#fff;\r\n\t\ttransition:all 0.5s linear\r\n\t}\r\n\t\r\n\t@media (min-width:1019px){\r\n\t\t#toc_group_float {\r\n\t\t\tdisplay:block!important;\r\n\t\t\t}\r\n\t\t\t\t#toc_group_article {\r\n\t\t\tdisplay:none;\r\n\t\t}\r\n\t}\r\n\r\n<\/style>\r\n\r\n<!-- ToC styling  -->\r\n<style>\r\n\t\/* Simple styling for the TOC *\/\r\n\t\r\n\t#toc ul li:last-child {\r\n    padding-bottom: 16px; \/* Adjust the value as needed *\/\r\n}\r\n\r\n.td-fix-index {\r\n\t transform: unset !important;\r\n     -webkit-transform: unset !important; \r\n}\r\n.footer-contact .td-fix-index {\r\n\t transform: translateZ(0) !important;\r\n     -webkit-transform: translateZ(0) !important; \r\n}\r\n\t.tdb_single_content .tdb-block-inner.td-fix-index{\r\n\t\tposition: static;\r\n\t}\r\n\t\r\n\r\n\t\r\n#toc {\r\n  background-color: #FFF;\r\n\tpadding: 17px 24px 0px 24px !important;\r\n  margin-bottom: 20px;\r\n\/*   border: 1px solid #9C171E; *\/\r\n  border-radius: 6px;\r\n\tdisplay: none;\r\n  max-width: 100%;\r\n  transition: .4s ease height;\r\n\tmargin-left: 0;\r\n\toverflow: hidden;\r\n}\r\n\r\n#toc .header{\r\n  display: flex;\r\n  align-items: center;\r\n  justify-content: space-between;\r\n\tbackground-color: transparent;\r\n}\r\n\t\r\n\t#toc.sticky .header{\r\n\t\tpadding: 4px 0;\r\n\t}\r\n\t\r\n.header p{\r\n  font-size: 18px !important;\r\n  font-weight: 600 !important;\r\n  color: #393939;\r\n   margin-bottom: 0;\r\n  \/* margin-top: 20px; *\/\r\n}\r\n\r\n.toc-icon{\r\n  float: right;\r\n\/*   visibility: hidden; *\/\r\n}\r\n\r\n\t.toc-title{\r\n\t\tmargin-right: auto;\r\n\/* \t\tpadding-left: 20px; *\/\r\n\t\tfont-weight: 600;\r\n\t\talign-self: center;\t}\t\r\n\r\n#toc ul {\r\n  list-style-type: none;\r\n  padding-left: 0;\r\n}\r\n\t\r\n#toc.sticky ul{\r\n\toverflow-y: auto;\r\n\tmax-height: 250px;\r\n\tmargin-top: 0px;\r\n\tpadding-top: 20px;\r\n\/* \tborder-top: 1px solid #d3d3d3; *\/\r\n}\r\n\t\r\n#toc ul li {\r\n\/*   margin-bottom: 10px; *\/\r\n  margin-bottom: 10px;\r\n\tmargin-left: 0;\r\n\ttransition: .2s ease;\r\n\tcursor: pointer;\r\n}\r\n\t\r\n\t#toc.sticky ul li {\r\n\t  margin-right: 10px;\r\n\t}\r\n\t\r\n.td-post-content #toc-list li a:hover, .td-post-content #toc-list a.active{\r\n\tbackground-color: #FFF;\r\n\/* \tpadding: 8px 16px 8px 16px; *\/\r\n\tpadding: 4px 16px 4px 16px;\r\n\tborder-radius: 6px;\r\n\tcolor: #9c171e !important;\r\n\tfont-weight: 600 !important;\r\n}\r\n\t\r\n\t.td-post-content #toc-list li:hover a, .td-post-content #toc-list a.active{\r\n\t\tcolor: #9C171E !important;\r\n\t\tfont-weight: 600 !important;\r\n\t}\r\n\t\r\n.td-post-content #toc-list a.active{\r\n\tfont-weight: bold !important;\r\n\tcolor: #9C171E !important;\r\n}\r\n\t\r\n#toc a, .td-post-content #toc-list a {\r\n  text-decoration: none;\r\n  color: #ea1717 !important;\r\n  transition: .2s ease;\r\n\tfont-weight: 400 !important;\r\n\tdisplay: block;\r\n\t\r\n\tpadding: 4px 16px 4px 0;\r\n}\r\n\r\n#toc.sticky {\r\n  position: fixed;\r\n\/*   top: 73px; *\/\r\n\tbottom: 0;\r\n  z-index: 100; \r\n  box-shadow: 0 2px 5px rgba(0,0,0,0.1); \r\n\twidth: 100%; \r\n\tbackground-color: #FFF;\r\n\/* \tbackground-color: #FFF1F1; *\/\r\n\tborder-bottom: 1px solid #ea1717;\r\n\/*   border: 1px solid #393939; *\/\r\n  box-shadow: 0px 0px 14px 0px #00000040;\r\n  cursor: pointer;\r\n\tanimation: fadein .3s ease;\r\n\tpadding: 12px 16px !important;\r\n}\r\n\t\r\n\t.fadein{\r\n\t\tanimation: fadein .3s ease;\r\n\t}\r\n\t\r\n\t.fadeout{\r\n\t\tanimation: fadeout .3s ease;\r\n\t}\r\n\t\r\n\t\r\n\t@keyframes fadein{\r\n\t\t0% {\r\n\t\t\topacity: 0;\r\n\t\t}\r\n\t\t100%{\r\n\t\t\topacity: 1;\r\n\t\t}\r\n\t}\r\n\t\r\n\t@keyframes fadeout{\r\n\t\t0% {\r\n\t\t\topacity: 1;\r\n\t\t}\r\n\t\t100%{\r\n\t\t\topacity: 0;\r\n\t\t}\r\n\t}\r\n\r\n\t\r\n#toc.sticky .header p{\r\n\tmargin-bottom: 10px;\r\n\tmargin-top: 10px;\r\n}\r\n\r\n#toc.sticky .toc-icon{\r\n  visibility: visible;\r\n\/* \ttransition: 0.4s ease; *\/\r\n}\r\n\t\r\n\t.toc-icon{\r\n\t\talign-items: center;\r\n    \tdisplay: flex;\r\n\t}\r\n\t\r\n\tsvg.header-icon{\r\n\/* \t\tbackground-color: #9c171e; *\/\r\n\t\tbackground-color: #FFF;\r\n\t\tborder-radius: 30px;\r\n\t\tpadding: 5px;\r\n\t}\r\n\r\n#toc.sticky .list{\r\n\/*   max-height: 0; *\/\r\n  transition: height 0.4s ease;\r\n}\r\n\t\r\n\t#toc .list{\r\n\/*   max-height: 0; *\/\r\n  transition: height 0.4s ease;\r\n}\r\n\r\n#toc .header.active .toc-icon{\r\n\ttransform: rotate(0deg); \r\n\topacity: 1;\r\n}\r\n\r\n\t#toc .header.active + .list {\r\n\t  max-height: 200px; \/* Adjust this value as needed *\/\r\n\t  opacity: 1;\r\n\t}\r\n\t\r\n\t#placeholder-toc{\r\n\/* \t\tdisplay: none; *\/\r\n\t}\r\n\t\r\n\t@media (min-width: 768px) and (max-width: 991px){\r\n\t\t#toc.sticky{\r\n\/* \t\t\ttop: 104px; *\/\r\n\t\t\tbottom: 0px;\r\n\t\t}\r\n\t\t\r\n\t\t#toc{\r\n\t\t\twidth: unset !important;\r\n\t\t}\r\n\t}\r\n\t\r\n\t@media (max-width: 767px){\r\n\t\t#toc{\r\n\t\t\twidth: 100% !important;\r\n\t\t\tdisplay: inline-block;\r\n\t\t}\r\n\t\t\r\n\t\t#toc.sticky{\r\n\t\t\twidth: 90% !important;\r\n\/* \t\t\ttop: 81px; *\/\r\n\t\t\tbottom: 60px;\r\n\t\t\tmargin-left: auto;\r\n\t\t\tmargin-right: auto;\r\n\t\t\tpadding: 0 16px;\r\n\t\t\tright: 5%;\r\n\t\t}\r\n\t}\r\n\t\r\n\t<\/style>\r\n\r\n<!-- ToC List for mobile -->\r\n<script>\r\n \/\/ Generate TOC based on headings\r\ndocument.addEventListener(\"DOMContentLoaded\", function() {\r\n  \/\/ Get the element that will contain the TOC\r\n  const tocList = document.getElementById('toc-list');\r\n\r\n  \/\/ Get the element with the ID 'article-left'\r\n  const article = document.querySelector('.td-post-content');\r\n\r\n  \/\/ Find all h2 elements within 'myarticle'\r\n  const headers = article.getElementsByTagName('h2');\r\n\r\n  \/\/ Loop through the h2 elements and create a list item for each one\r\n  for (let i = 0; i < headers.length; i++) {\r\n    const header = headers[i];\r\n    const headerText = header.textContent;\r\n\/\/     const headerId = 'header-' + i;\r\n    const headerId = headerText\r\n    .toLowerCase()\r\n    .trim()\r\n    .replace(\/[^\\w\\s-]\/g, '')  \/\/ hapus tanda baca\r\n    .replace(\/\\s+\/g, '-'); \/\/ ganti spasi jadi \"-\"\r\n\r\n    \/\/ Set an ID for the header if it doesn't have one\r\n    header.setAttribute('id', headerId);\r\n\r\n    \/\/ Create a list item for the TOC\r\n    const listItem = document.createElement('li');\r\n\r\n    \/\/ Create a link for the list item\r\n    const link = document.createElement('a');\r\n    link.setAttribute('href', '#' + headerId);\r\n    link.textContent = headerText;\r\n\r\n    \/\/ Append the link to the list item\r\n    listItem.appendChild(link);\r\n\r\n    \/\/ Append the list item to the TOC list\r\n    tocList.appendChild(listItem);\r\n  }\r\n});\r\n\r\n\/\/ Keep height and placement of content using placeholder in place of TOC\r\ndocument.addEventListener(\"DOMContentLoaded\", function() {\r\n  const toc = document.querySelector('#toc');\r\n  const placeholderToc = document.querySelector('#placeholder-toc');\r\n\r\n  function setPlaceholderHeight() {\r\n    placeholderToc.style.height = `${toc.offsetHeight}px`;\r\n  }\r\n\r\n  \/\/ Set the initial height of the placeholder\r\n  setPlaceholderHeight();\r\n\r\n  \/\/ Update the height on window resize\r\n  window.addEventListener('resize', setPlaceholderHeight);\r\n});\r\n  const tocTitle = document.querySelector('#toc-title'); \/\/ Assuming header-faq is the element for TOC title\r\n\r\n\/\/ Sticky TOC and update heading\r\ndocument.addEventListener(\"DOMContentLoaded\", function() {\r\n  const toc = document.querySelector('#toc');\r\n  const footer = document.querySelector('.td-footer-template-wrap');\r\n  const tocParent = toc.parentElement;\r\n  const divTop = tocParent.getBoundingClientRect().top + window.pageYOffset;\r\n  const tocHeight = toc.offsetHeight;\r\n  const triggerPoint = divTop + tocHeight + 700;\r\n  const footerHeight = footer.offsetHeight;\r\n  const triggerFooterPoint = footer.getBoundingClientRect().top + window.pageYOffset - footerHeight - footerHeight - footerHeight;\r\n  const phtoc = document.querySelector('#placeholder-toc');\r\n  const headers = document.querySelectorAll('.td-post-content h2');\r\n  const navLinks = document.querySelectorAll('#toc-list a');\r\n\t\r\n\tconst panel2 = document.querySelector(\"#toc .list\");\r\n\tvar icon = document.querySelector(\".toc-icon\");\r\n\r\n  let activeLink = null; \/\/ Declare activeLink outside the loop\r\n\t\r\n  \/\/ Function to handle scroll and add\/remove .sticky class\r\n  function handleScroll() {\r\n    const windowTop = window.pageYOffset || document.documentElement.scrollTop;\r\n    let currentHeader = '';\r\n\r\n    \/\/ Highlight user progress as the heading comes\r\n    headers.forEach(header => {\r\n\t\tconst headerTop = header.offsetTop;\r\n\t\tconst headerHeight = header.clientHeight;\r\n\t\tif (window.scrollY >= (headerTop - headerHeight + 700)) {\r\n\t\t\tconst currentHeaderId = header.getAttribute('id');\r\n\t\t\tconst currentHeaderText = document.getElementById(currentHeaderId).textContent;\r\n\/\/ \t\t\tconsole.log(\"current header text:\", currentHeaderText);\r\n\t\t\ttocTitle.textContent = currentHeaderText;\r\n\t\t\tcurrentHeader = currentHeaderId;\r\n\t\t\t\r\n\t\t\tif(window.innerWidth < 767){\r\n\t\t\t\ttocTitle.textContent = 'Table of Content';\r\n\t\t\t}\r\n\t\t}\r\n\t});\r\n\r\n    navLinks.forEach(link => {\r\n      link.classList.remove('active');\r\n      if(currentHeader != '') {\r\n\t\t  if (link.getAttribute('href').includes(currentHeader)) {\r\n\t\t\t  link.classList.add('active');\r\n\t\t  }\r\n\t  }\r\n    });\r\n\/\/     if (windowTop < triggerFooterPoint) {\r\n\/\/         toc.style.display = 'block';\r\n\/\/ \t}else{\r\n\/\/         toc.style.display = 'none';\r\n\/\/ \t}\r\n    \/\/ Update TOC title if sticky\r\n    if (windowTop > triggerPoint) {\r\n      if (!toc.classList.contains('sticky')) {\r\n        phtoc.style.display = \"block\";\r\n        toc.classList.add('sticky');\r\n        toc.style.width = `${tocParent.offsetWidth}px`; \/\/ Set width to match the parent element\r\n        toc.setAttribute('style', 'width: ' + tocParent.offsetWidth + 'px !important;');\r\n        toc.style.backgroundColor = \"#FFF\";\r\n\t\tpanel2.style.height = '0px';\r\n\t\t  icon.style.transform = \"rotate(180deg)\";\r\n\t\t  if(window.innerWidth < 767){\r\n\/\/ \t\t\t  const tocs = document.querySelector('#toc.sticky');\r\n\t\t\t  tocTitle.textContent = 'Table of Content'; \/\/ Reset title\r\n       \t\t  toc.style.width = '150px'; \/\/ Set width to match the parent element\r\n\t\t  }\r\n      }\r\n      if (currentHeader) {\r\n\/\/         console.log(\"activeLink:\", activeLink);\r\n        if (activeLink) {\r\n\/\/           tocTitle.textContent = activeLink.textContent; \/\/ Update TOC title\r\n          tocTitle.textContent = activeLink ? activeLink.textContent : \"\"; \/\/ Update title only if activeLink exists\r\n        }\r\n      }\r\n    } else {\r\n      toc.classList.remove('sticky');\r\n      phtoc.style.display = \"none\";\r\n      toc.style.width = 'unset'; \/\/ Reset to original width\r\n      toc.style.backgroundColor = \"#FFF\";\r\n      tocTitle.textContent = 'Table of Content'; \/\/ Reset title\r\n\t\tpanel2.style.height = panel2.scrollHeight + \"px\";\r\n\t\ticon.style.transform = \"rotate(180deg)\";\r\n    }\r\n  }\r\n\r\n    \/\/ Attach the scroll event listener to the window\r\n    window.addEventListener('scroll', handleScroll);\r\n\r\n    \/\/ Initial call to handleScroll to set the correct state on load\r\n    handleScroll();\r\n});\r\n\t\r\n\t\/\/ Open toggle TOC\r\n\t  document.addEventListener(\"DOMContentLoaded\", function() {\r\n\t\tvar tocHeader = document.querySelector(\"#toc .header\");\r\n\t\tvar toc = document.querySelector(\"#toc\");\r\n\t\tvar icon = document.querySelector(\".toc-icon\");\r\n\t\tconst tocTitle = document.querySelector('#toc-title');\r\n\t\tconst tocs = document.querySelector('#toc.sticky');\r\n \t\tconst tocParent = toc.parentElement;\t\t  \r\n\r\n\t\t  tocHeader.addEventListener(\"click\", function() {\r\n\t\t\tvar panel = this.nextElementSibling;\r\n\t\t\tif (panel.style.height !== '0px') { \/\/ Check if height is not 0px\r\n\t\t\t  panel.style.height = '0px'; \/\/ Set height to 0 for full collapse\r\n\t\t\t  icon.style.transform = \"rotate(180deg)\";\r\n\/\/ \t\t\t\ttoc.style.paddingBottom = '6px'; \r\n\t\t\t\tif(window.innerWidth > 768){\r\n\t\t\t\t\tif(!toc.classList.contains('sticky')){\r\n\t\t\t\t\t\ttoc.style.width = \"unset\";\r\n\/\/ \t\t\t\t\t\ttoc.setAttribute('style', 'width: ' + tocParent.offsetWidth + 'px !important;');\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (toc.classList.contains('sticky')){\r\n\t\t\t\t\t\ttoc.style.width = '${tocParent.offsetWidth}px';\r\n\t\t\t\t\t\ttoc.setAttribute('style', 'width: ' + tocParent.offsetWidth + 'px !important;');\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tif(window.innerWidth < 767){\r\n\t\t\t\t\ttoc.style.width = \"unset\"; \/\/ Reset width\r\n\t\t\t\t}\r\n\t\t\t\ttoc.style.backgroundColor = \"#FFF1F1\";\r\n\t\t\t} else {\r\n\t\t\t  panel.style.height = panel.scrollHeight + \"px\";\r\n\t\t\t  icon.style.transform = \"rotate(0deg)\";\r\n\t\t\t  toc.style.backgroundColor = \"#FFF\";\r\n\t\t\t  tocTitle.textContent = 'Table of Content'; \/\/ Reset title\r\n\t\t\t\ttoc.style.paddingBottom = '24px';\r\n\t\t\t \tif(window.innerWidth < 767){\r\n\t\t\t\t\ttoc.style.width = `${tocParent.offsetWidth}px`; \/\/ Set width to match the parent element\r\n\t\t\t\t\ttoc.setAttribute('style', 'width: ' + tocParent.offsetWidth + 'px !important;');\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t  });\r\n\r\n\t\t  \/\/ Close TOC when a link inside it is clicked\r\n\t\t  var tocLinks = document.querySelectorAll(\"#toc .list a\");\r\n\t\t  tocLinks.forEach(function(link) {\r\n\t\t\tlink.addEventListener(\"click\", function() {\r\n\t\t\t  var panel = document.querySelector(\"#toc .list\");\r\n\t\t\t  panel.style.height = '0px'; \/\/ Set height to 0 for full collapse\r\n\t\t\t  icon.style.transform = \"rotate(180deg)\";\r\n\t\t\t  toc.style.backgroundColor = \"#FFF\";\r\n\t\t\t});\r\n\t\t  });\r\n\t\t});\r\n\r\n\r\n\r\n\t\r\n\/\/ \tmake the heading at the center of the viewport\r\n\/\/ \tdocument.addEventListener('DOMContentLoaded', function() {\r\n\/\/     \/\/ Add click event listener to all links in the TOC list\r\n\/\/     document.querySelectorAll('#toc-list a').forEach(anchor => {\r\n\/\/         anchor.addEventListener('click', function (e) {\r\n\/\/             e.preventDefault(); \/\/ Prevent the default behavior of jumping to the anchor\r\n\/\/ \/\/ \t\t\tconsole.log(\"prevent default\");\r\n\/\/             const targetId = this.getAttribute('href').substring(1); \/\/ Get the ID of the target element\r\n\/\/             const targetElement = document.getElementById(targetId); \/\/ Get the target element\r\n\r\n\/\/             if (targetElement) {\r\n\/\/                 const headerHeight = document.querySelector('#toc .header').offsetHeight; \/\/ Get the height of the fixed header\r\n\/\/                 const windowHeight = window.innerHeight; \/\/ Get the height of the viewport\r\n\/\/                 const targetOffset = targetElement.offsetTop; \/\/ Get the top offset of the target element\r\n\/\/                 const scrollTo = targetOffset + (windowHeight \/ 2) + (headerHeight); \/\/ Calculate the scroll position to center the target element\r\n\r\n\/\/                 \/\/ Scroll to the calculated position smoothly\r\n\/\/                 window.scrollTo({\r\n\/\/                     top: scrollTo,\r\n\/\/                     behavior: 'smooth'\r\n\/\/                 });\r\n\/\/             }\r\n\/\/         });\r\n\/\/     });\r\n\/\/ });\r\n<\/script>\r\n\r\n<!-- START script lama -->\r\n<!-- <script>\r\n\/\/ \tvar pilihDaftarIsi = document.getElementById('pilihDaftarIsi');\r\n\t\r\n\/\/ \tdocument.addEventListener('DOMContentLoaded', function() {\r\n\/\/ \t\tvar dropdownFixedTop = document.querySelector('.dropdown-fixed-top');\r\n\r\n\/\/ \t\tdropdownFixedTop.addEventListener('click', function() {\r\n\/\/ \t\t\tvar dropdownContent = this.querySelector('.list_toc');\r\n\/\/ \t\t\tdropdownContent.classList.toggle('show');\r\n\/\/ \t\t});\r\n\r\n\/\/ \t\twindow.addEventListener('click', function(event) {\r\n\/\/ \t\t\tvar listTocTop = document.getElementById('list_toc_top');\r\n\r\n\/\/ \t\t\tif (!dropdownFixedTop.contains(event.target)) {\r\n\/\/ \t\t\t\tlistTocTop.classList.remove('show');\r\n\/\/ \t\t\t}\r\n\/\/ \t\t});\r\n\/\/ \t});\r\n\t\r\n\/\/ \tvar daftarIsiContainer = document.getElementById('toc_group_article');\r\n\/\/ \tvar dropdownFixedTop = document.getElementById('dropdown-fixed-top');\r\n\/\/     var triggered = false; \/\/ Flag to keep track of whether the function has been triggered\r\n\r\n\/\/     window.addEventListener('scroll', function() {\r\n\/\/         if (!triggered && isCompletelyScrolledPast(daftarIsiContainer)) {\r\n\/\/             showSectionDropdownFixedTop(false);\r\n\/\/             triggered = true;\r\n\/\/         } else if (triggered && !isCompletelyScrolledPast(daftarIsiContainer)) {\r\n\/\/             showSectionDropdownFixedTop(true);\r\n\/\/             triggered = false;\r\n\/\/         }\r\n\/\/     });\r\n\r\n\/\/     function isCompletelyScrolledPast(element) {\r\n\/\/         var elementTop = element.getBoundingClientRect().top;\r\n\/\/         var elementBottom = element.getBoundingClientRect().bottom;\r\n\/\/         return elementTop < 0 && elementBottom < 0;\r\n\/\/     }\r\n\r\n\/\/     function showSectionDropdownFixedTop(show) {\r\n\/\/ \t\tif (show) {\r\n\/\/ \t\t\tdropdownFixedTop.classList.remove(\"show\");\r\n\/\/ \t\t} else {\r\n\/\/ \t\t\tdropdownFixedTop.classList.add(\"show\");\r\n\/\/ \t\t}\r\n\/\/     }\r\n<\/script> -->\r\n<!-- <script>\r\n    \/\/ Scrollspy function to highlight the active TOC item based on the scroll position\r\n  function scrollSpy(tocClass) {\r\n    const scrollPosition = window.scrollY;\r\n\r\n    \/\/ Find the active h2 and h3 headings based on their position in the corresponding TOC\r\n    let activeH2 = null;\r\n    let activeH3 = null;\r\n\r\n    const tocItems = document.querySelectorAll(`.${tocClass} li`);\r\n    tocItems.forEach(item => {\r\n      const a = item.querySelector('a');\r\n      if (!a) return;\r\n      const href = a.getAttribute('href');\r\n      const targetId = href.substring(1); \/\/ Remove the '#' from the href to get the target ID\r\n      const targetElement = document.getElementById(targetId);\r\n      if (!targetElement) return;\r\n\r\n      const targetTop = targetElement.getBoundingClientRect().top + scrollPosition;\r\n      const nextItem = item.nextElementSibling;\r\n      const nextTop = nextItem ? nextItem.getBoundingClientRect().top + scrollPosition : Infinity;\r\n\r\n      if (targetTop <= scrollPosition + 150) {\r\n        if (a.parentElement.parentElement === tocItems) {\r\n          \/\/ The h2 heading is at the root level of the TOC\r\n          activeH2 = { id: targetId, level: 'h2' };\r\n        } else {\r\n          \/\/ The h3 heading is nested under an h2 heading\r\n          const parentH2 = a.parentElement.parentElement.previousElementSibling;\r\n          if (parentH2) {\r\n            const h2Link = parentH2.querySelector('a');\r\n            if (h2Link) {\r\n              const h2Href = h2Link.getAttribute('href');\r\n              const h2Id = h2Href.substring(1);\r\n              activeH2 = { id: h2Id, level: 'h2' };\r\n            }\r\n          }\r\n          activeH3 = { id: targetId, level: 'h3' };\r\n        }\r\n      }\r\n\r\n      if (targetTop > scrollPosition + 150 && nextTop > scrollPosition + 150 && !activeH3) {\r\n        \/\/ Reset the activeH2 when there are no more active h3 headings\r\n        activeH2 = null;\r\n      }\r\n    });\r\n\r\n    \/\/ Update the active state for the TOC items\r\n    tocItems.forEach(item => {\r\n      item.classList.remove('active');\r\n      const a = item.querySelector('a');\r\n      if (a) {\r\n        const href = a.getAttribute('href');\r\n        const targetId = href.substring(1);\r\n        if ((activeH2 && activeH2.id === targetId) || (activeH3 && activeH3.id === targetId)) {\r\n          item.classList.add('active');\r\n\t\t  pilihDaftarIsi.innerHTML = a.textContent;\r\n        }\r\n      }\r\n    });\r\n  }\r\n\r\n  \/\/ Call scrollSpy for each TOC on window scroll\r\n  const tocClasses = ['list_toc', 'list_toc_float', 'list_toc_top']; \/\/ Add other TOC class names here if you have more than two instances\r\n  tocClasses.forEach(tocClass => {\r\n    window.addEventListener('scroll', () => scrollSpy(tocClass));\r\n  });\r\n<\/script> -->\r\n<!-- END script lama -->\r\n\t\r\n<script>\r\n    \/\/ Scrollspy function to highlight the active TOC item based on the scroll position\r\n  function scrollSpy(tocClass) {\r\n    const scrollPosition = window.scrollY;\r\n\r\n    \/\/ Find the active h2 and h3 headings based on their position in the corresponding TOC\r\n    let activeH2 = null;\r\n    let activeH3 = null;\r\n\r\n    const tocItems = document.querySelectorAll(`.${tocClass} li`);\r\n    tocItems.forEach(item => {\r\n      const a = item.querySelector('a');\r\n      if (!a) return;\r\n      const href = a.getAttribute('href');\r\n      const targetId = href.substring(1); \/\/ Remove the '#' from the href to get the target ID\r\n      const targetElement = document.getElementById(targetId);\r\n      if (!targetElement) return;\r\n\r\n      const targetTop = targetElement.getBoundingClientRect().top + scrollPosition;\r\n      const nextItem = item.nextElementSibling;\r\n      const nextTop = nextItem ? nextItem.getBoundingClientRect().top + scrollPosition : Infinity;\r\n\r\n      if (targetTop <= scrollPosition + 150) {\r\n        if (a.parentElement.parentElement === tocItems) {\r\n          \/\/ The h2 heading is at the root level of the TOC\r\n          activeH2 = { id: targetId, level: 'h2' };\r\n        } else {\r\n          \/\/ The h3 heading is nested under an h2 heading\r\n          const parentH2 = a.parentElement.parentElement.previousElementSibling;\r\n          if (parentH2) {\r\n            const h2Link = parentH2.querySelector('a');\r\n            if (h2Link) {\r\n              const h2Href = h2Link.getAttribute('href');\r\n              const h2Id = h2Href.substring(1);\r\n              activeH2 = { id: h2Id, level: 'h2' };\r\n            }\r\n          }\r\n          activeH3 = { id: targetId, level: 'h3' };\r\n        }\r\n      }\r\n\r\n      if (targetTop > scrollPosition + 150 && nextTop > scrollPosition + 150 && !activeH3) {\r\n        \/\/ Reset the activeH2 when there are no more active h3 headings\r\n        activeH2 = null;\r\n      }\r\n    });\r\n\r\n    \/\/ Update the active state for the TOC items\r\n    tocItems.forEach(item => {\r\n      item.classList.remove('active');\r\n      const a = item.querySelector('a');\r\n      if (a) {\r\n        const href = a.getAttribute('href');\r\n        const targetId = href.substring(1);\r\n        if ((activeH2 && activeH2.id === targetId) || (activeH3 && activeH3.id === targetId)) {\r\n          item.classList.add('active');\r\n        }\r\n      }\r\n    });\r\n  }\r\n\r\n  \/\/ Call scrollSpy for each TOC on window scroll\r\n  const tocClasses = ['list_toc', 'list_toc_float']; \/\/ Add other TOC class names here if you have more than two instances\r\n  tocClasses.forEach(tocClass => {\r\n    window.addEventListener('scroll', () => scrollSpy(tocClass));\r\n  });\r\n<\/script>\r\n\t\r\n\r\n<!-- ToC List for desktop side bar, diganti jadi inject by php, di code snippet \"Sidebar Accordion\" -->\r\n<!--  <script>\r\n\tdocument.addEventListener(\"DOMContentLoaded\", function() {\r\nToC List for desktop side bar, diganti jadi inject by php, di code snippet \"Sidebar Accordion\"\r\n        Fungsi untuk mengubah teks menjadi format id\r\n        function formatId(text) {\r\n            return text.trim().replace(\/[^\\w\\d]+\/g, '_');\r\n        }\r\n\r\n        \/\/ Fungsi untuk membuat nested list\r\n        function createNestedList(parentNode, children) {\r\n            if (children.length === 0) return;\r\n\r\n            const nestedUl = document.createElement('ul');\r\n            children.forEach(child => {\r\n                const nestedLi = document.createElement('li');\r\n                const nestedA = document.createElement('a');\r\n                nestedA.textContent = child.title;\r\n                nestedA.href = `#${child.id}`;\r\n                nestedLi.appendChild(nestedA);\r\n                nestedUl.appendChild(nestedLi);\r\n\r\n                if (child.children.length > 0) {\r\n                    createNestedList(nestedLi, child.children);\r\n                }\r\n            });\r\n\r\n            parentNode.appendChild(nestedUl);\r\n        }\r\n\r\n        \/\/ Membuat objek untuk menyimpan daftar h2 dan h3 beserta judulnya\r\n        const headings = [];\r\n\r\n           \/\/ Mengambil semua elemen h2 dan h3\r\n        const elements = document.querySelectorAll('.td-post-content h2');\r\n\t\t\t\/\/, .td-post-content h3\r\n\r\n        elements.forEach(element => {\r\n            if (element.tagName === 'H2') {\r\n                const id = formatId(element.textContent);\r\n                element.id = id;\r\n\t\t\t\tif (element.textContent.toLowerCase() === \"key takeaways\") {return;} \/\/ Kalau Key Takeaways, jangan dimasukin\r\n                headings.push({ level: 'h2', id: id, title: element.textContent, children: [] });\r\n            } else if (element.tagName === 'H3') {\r\n                const id = formatId(element.textContent);\r\n                element.id = id;\r\n                if (headings.length > 0) {\r\n                    headings[headings.length - 1].children.push({ level: 'h3', id: id, title: element.textContent, children: [] });\r\n                }\r\n            }\r\n        });\r\n\r\n        \/\/ Membuat list HTML dari objek headings\r\n        const ul = document.getElementById('list_toc');\r\n        let currentUl = ul;\r\n        headings.forEach(heading => {\r\n            const li = document.createElement('li');\r\n            const a = document.createElement('a');\r\n            a.textContent = heading.title;\r\n            a.href = `#${heading.id}`;\r\n            li.appendChild(a);\r\n\r\n            if (heading.level === 'h2') {\r\n                \/\/ Menyimpan ul saat ini untuk menambahkan nested ul\r\n                currentUl = li;\r\n                ul.appendChild(li);\r\n            } else if (heading.level === 'h3') {\r\n                if (!currentUl.lastElementChild || currentUl.lastElementChild.tagName !== 'UL') {\r\n                    \/\/ Jika belum ada nested ul, buat satu\r\n                    const nestedUl = document.createElement('ul');\r\n                    currentUl.appendChild(nestedUl);\r\n                    currentUl = nestedUl;\r\n                }\r\n                currentUl.appendChild(li);\r\n            }\r\n\r\n            createNestedList(li, heading.children);\r\n        });\r\n\t\tDapatkan elemen ul dengan id 'list_toc_float'\r\nconst ulFloat = document.getElementById('list_toc');\r\nconst ulJourney = document.getElementById('list_journey');\r\n\r\nDapatkan isi (child elements) dari ul dengan id 'list_toc_float'\r\n\tif (ulFloat !== null) {\r\n\t\tconst clonedChildren = ulFloat.cloneNode(true).children;\r\n\t\tconst ulToc = document.getElementById('list_toc_float');\r\n\t\tconst ulTocTop = document.getElementById('list_toc_top');\r\n\t\tif ((ulToc !== null || ulToc !== undefined) && window.innerWidth > 1018){\r\n\t\t\tulToc.append(...clonedChildren);\r\n\t\t} else {\r\n\t\t\tulTocTop.append(...clonedChildren);\r\n\t\t}\r\n\t} \r\n\r\n\tif (ulJourney !== null) {\r\n\t\tconst clonedChildrenJourney = ulJourney.cloneNode(true).children;\r\n\t\tconst ulTocJourney = document.getElementById('list_toc_journey');\r\n\t\tulTocJourney.append(...clonedChildrenJourney);\r\n\t} \r\n\t\r\n        Fungsi untuk mengambil tinggi navbar\r\n        function getNavbarHeight() {\r\n            const navbar = document.getElementById('tdi_34');\r\n            return navbar ? navbar.offsetHeight : 0;\r\n        }\r\n\r\n        \/\/ Fungsi untuk menambahkan offset posisi scroll\r\n        function scrollToElementWithOffset(elementId) {\r\n            const element = document.getElementById(elementId);\r\n            if (element) {\r\n                const offset = getNavbarHeight();\r\n                const elementPosition = element.getBoundingClientRect().top;\r\n                const offsetPosition = elementPosition - offset-40;\r\n\r\n                window.scrollBy({\r\n                    top: offsetPosition,\r\n                    behavior: 'smooth'\r\n                });\r\n            }\r\n        }\r\n\r\n        \/\/ Fungsi untuk menangani klik pada tautan judul\r\n        function handleTitleClick(event) {\r\n            event.preventDefault();\r\n            const href = event.target.getAttribute('href').substr(1);\r\n            scrollToElementWithOffset(href);\r\n        }\r\n\r\n        \/\/ Tambahkan event listener untuk semua tautan judul\r\n        const titleLinks = document.querySelectorAll('a[href^=\"#\"]');\r\n        titleLinks.forEach(link => {\r\n            link.addEventListener('click', handleTitleClick);\r\n        });\r\n\t});\r\n    <\/script> -->\r\n <a href=\"https:\/\/www.hashmicro.com\/free-product-tour\/?medium=free-product-tour\" target=\"_blank\"><img decoding=\"async\" loading=\"lazy\" width=\"712\" src=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2025\/11\/Free-Product-Tour-resized.webp\" alt=\"Free Demo\"><\/a><\/span><\/p>\n<h2><b><span id=\"ssf\">What is the Safety Stock Formula?<\/span><\/b><\/h2>\n<p><span style=\"font-weight: 400;\">The safety stock formula helps determine how much extra inventory is needed to avoid stockouts caused by demand fluctuations or delivery delays. It ensures that you have enough stock to cover unexpected events while avoiding overstocking. A common formula is:<\/span><\/p>\n<p style=\"text-align: center;\"><b><i>Safety Stock = Zscore \u00d7 \u03c3LT\u200b<\/i><\/b><\/p>\n<p><span style=\"font-weight: 400;\">Where:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\"><b>Z-score<\/b><span style=\"font-weight: 400;\"> is the number that corresponds to your desired service level (e.g., for a 95% service level, Z = 1.65).<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>\u03c3LT\u200b<\/b><span style=\"font-weight: 400;\"> is the standard deviation of demand during lead time, which reflects the variability in demand during the time it takes to receive new stock.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">This formula helps businesses maintain the right balance of inventory, ensuring they can meet customer needs without tying up too much capital in excess stock.<\/span><\/p>\n<h2><b><span id=\"lt\">What is Lead Time Demand?<\/span><\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Lead time demand refers to the total amount of product expected to be sold or used during the lead time, which is the period between placing an order and receiving the products. It helps businesses understand how much inventory they need during this waiting period.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">By calculating lead time demand, companies can predict their inventory needs more accurately, ensuring they don\u2019t run out of stock while waiting for the next delivery. This is crucial for avoiding stockouts and maintaining smooth operations.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Accurately forecasting lead time demand and applying the lead time safety stock formula helps businesses manage inventory effectively. It ensures that products are available when customers need them, regardless of demand variability or lead time fluctuations.<\/span><\/p>\n<h2><b><span id=\"calculate\">How to Calculate Safety Stock<\/span><\/b><\/h2>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-67573\" src=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock.webp\" alt=\"Calculate safety stock \" width=\"1200\" height=\"675\" srcset=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock.webp 1200w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-300x169.webp 300w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-1024x576.webp 1024w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-768x432.webp 768w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-747x420.webp 747w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-150x84.webp 150w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-696x392.webp 696w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/How-to-Calculate-stock-1068x601.webp 1068w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/p>\n<p><span style=\"font-weight: 400;\">Calculating <\/span><a href=\"https:\/\/www.hashmicro.com\/blog\/safety-stock\/\"><span style=\"font-weight: 400;\">safety stock<\/span><\/a><span style=\"font-weight: 400;\"> is key to preventing stockouts and optimizing inventory levels. The Z-score method offers a precise approach by accounting for demand fluctuations and the desired service level, while the simplified method provides a quicker, less complex solution.<\/span><\/p>\n<h3><b>Z-Score Method<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">The Z-score method helps you calculate the right amount of extra stock needed to prevent stockouts, factoring in demand variability and the desired service level. It uses the safety stock formula with service level to ensure adequate inventory, even during unexpected situations.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">To calculate safety stock using the <\/span><b>Z-score method<\/b><span style=\"font-weight: 400;\">, you need the following information:<\/span><\/p>\n<ol>\n<li style=\"font-weight: 400;\"><b>Z-score<\/b><span style=\"font-weight: 400;\">: This value corresponds to the desired service level. For example, for a 95% service level, the Z-score is typically <\/span><b>1.65<\/b><span style=\"font-weight: 400;\">. The Z-score increases as you want a higher level of confidence in avoiding stockouts.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Standard Deviation of Lead Time Demand (\u03c3LT\u200b)<\/b><span style=\"font-weight: 400;\">: This reflects the variability in demand during the lead time. You can calculate it by finding the standard deviation of past demand during the lead time period.<\/span><\/li>\n<\/ol>\n<p><span style=\"font-weight: 400;\">Steps to Calculate Safety Stock:<\/span><\/p>\n<ol>\n<li style=\"font-weight: 400;\"><b>Determine the z-score<\/b><span style=\"font-weight: 400;\">: Based on your desired service level:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">90% service level = Z-score of <\/span><b>1.28<\/b><\/li>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">95% service level = Z-score of <\/span><b>1.65<\/b><\/li>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">99% service level = Z-score of <\/span><b>2.33<\/b><\/li>\n<\/ul>\n<\/li>\n<li style=\"font-weight: 400;\"><b>Calculate the \u03c3LT\u200b<\/b><span style=\"font-weight: 400;\">:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">This is based on historical data. You need to calculate how much the demand fluctuates during the lead time period. If you have data for past orders, calculate the standard deviation of the demand during the lead time period.<\/span><\/li>\n<\/ul>\n<\/li>\n<li style=\"font-weight: 400;\"><b>Use the formula<\/b><span style=\"font-weight: 400;\">: Once you have the Z-score and the standard deviation of lead time demand, you can calculate safety stock using this formula:<\/span><\/li>\n<\/ol>\n<p style=\"text-align: center;\"><b><i>Safety Stock = Z score \u00d7 \u03c3LT\u200b\u200b<\/i><\/b><\/p>\n<p>Example:<\/p>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Desired service level: 95% (Z-score = 1.65)<\/span><\/li>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">The standard deviation of demand during lead time: 50 units<\/span><\/li>\n<\/ul>\n<p style=\"text-align: center;\"><b><i>Safety Stock = 1.65 \u00d7 50 = 82.5 units<\/i><\/b><\/p>\n<p><span style=\"font-weight: 400;\">In this example, you would need approximately <\/span><b>83 units<\/b><span style=\"font-weight: 400;\"> of safety stock to maintain a 95% service level.<\/span><\/p>\n<h3><b>Simplified Method<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">The simplified method for calculating safety stock is quick and easy but lacks the precision of the Z-score method. It uses average demand and lead time, with a safety factor to cover potential uncertainties in supply and demand, but doesn\u2019t account for actual demand variability.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">While it&#8217;s easier to implement, this approach doesn\u2019t fully capture fluctuations in demand, making it less accurate for businesses with high variability. However, it remains useful for companies seeking a faster, less complex solution.<\/span><\/p>\n<p>Formula:<\/p>\n<p style=\"text-align: center;\"><b><i>Safety Stock = (Average Demand \u00d7 Lead Time) \u00d7 Safety Factor<\/i><\/b><\/p>\n<p>Steps to Calculate Safety Stock:<\/p>\n<ol>\n<li style=\"font-weight: 400;\"><b>Determine the average demand<\/b><span style=\"font-weight: 400;\">:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Calculate the average number of units sold or used per day (or any time period you\u2019re measuring) based on historical data.<\/span><\/li>\n<\/ul>\n<\/li>\n<li style=\"font-weight: 400;\"><b>Determine the lead time<\/b><span style=\"font-weight: 400;\">:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Lead time is the number of days (or another time unit) it takes from placing an order to receiving the products.<\/span><\/li>\n<\/ul>\n<\/li>\n<li style=\"font-weight: 400;\"><b>Choose a safety factor<\/b><span style=\"font-weight: 400;\">:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">The safety factor is a multiplier that adjusts for variability in both demand and lead time. The value typically ranges from <\/span><b>1 to 2<\/b><span style=\"font-weight: 400;\">, depending on the level of uncertainty or desired service level. For example:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Low uncertainty = <\/span><b>1<\/b><\/li>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Moderate uncertainty = <\/span><b>1.5<\/b><\/li>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">High uncertainty = <\/span><b>2<\/b><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li style=\"font-weight: 400;\"><b>Apply the formula<\/b><span style=\"font-weight: 400;\">:<\/span>\n<ul>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Multiply the average demand by the lead time to get the total demand during the lead time.<\/span><\/li>\n<li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">Multiply the result by the safety factor to calculate safety stock.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<p>Example:<\/p>\n<ul>\n<li style=\"font-weight: 400;\"><b>Average demand per day<\/b><span style=\"font-weight: 400;\">: 20 units<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Lead time<\/b><span style=\"font-weight: 400;\">: 10 days<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Safety factor<\/b><span style=\"font-weight: 400;\">: 1.5 (for moderate uncertainty)<\/span><\/li>\n<\/ul>\n<p style=\"text-align: center;\"><b><i>Safety Stock = (20 units \u00d7 10 days) \u00d7 1.5<\/i><\/b><\/p>\n<p style=\"text-align: center;\"><b><i>Safety Stock = 200 \u00d7 1.5 = 300 units<\/i><\/b><\/p>\n<p><span style=\"font-weight: 400;\">In this example, you would need <\/span><b>300 units<\/b><span style=\"font-weight: 400;\"> of safety stock to cover variability in demand and supply during the lead time.<\/span><\/p>\n<h2><b><span id=\"important\">Importance of Safety Stock<\/span><\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Safety stock is crucial for maintaining smooth operations and meeting customer demand, even when unexpected events occur. It acts as a buffer stock against supply chain disruptions and demand fluctuations. Here\u2019s why safety stock matters:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\"><b>Handles demand spikes: <\/b><span style=\"font-weight: 400;\">Unpredictable increases in customer orders can lead to stockouts. Safety stock ensures you can fulfill these orders without losing sales or damaging customer trust.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Prevents stockouts from shipping delays: <\/b><span style=\"font-weight: 400;\">Delays in receiving inventory from suppliers are common. Safety stock helps you avoid disruptions when shipments are delayed, keeping your operations running smoothly.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Meets seasonal demand: <\/b><span style=\"font-weight: 400;\">Businesses often face higher demand during certain seasons. Safety stock ensures that you can meet this surge without running out of inventory, helping you make the most of peak sales periods.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Covers inventory losses: <\/b><span style=\"font-weight: 400;\">Products can get damaged, lost, or stolen. Safety stock helps replace these items quickly, ensuring that your business doesn\u2019t suffer from lost inventory.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">While safety stock is essential for smooth operations, an effective <\/span><a href=\"https:\/\/www.hashmicro.com\/blog\/inventory-management-system\/\"><span style=\"font-weight: 400;\">inventory management system<\/span><\/a><span style=\"font-weight: 400;\"> optimizes it further. With real-time tracking and automation, it ensures your stock aligns with safety needs, monitors demand patterns, and manages lead times.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Discover the <\/span><a href=\"https:\/\/www.hashmicro.com\/blog\/inventory-management-software-singapore\/\"><span style=\"font-weight: 400;\">best inventory management solution in Singapore<\/span><\/a><span style=\"font-weight: 400;\"> and optimize your stock levels with real-time tracking and automated updates.<\/span><\/p>\n<h2><b><span id=\"rop\">Safety Stock and the Reorder Point Formula<\/span><\/b><\/h2>\n<p><span style=\"font-weight: 400;\">The reorder point (ROP) formula helps businesses determine the right moment to reorder stock to avoid running out of inventory. It takes both lead time demand and safety stock into account, ensuring there\u2019s enough inventory on hand to cover demand until new stock arrives.<\/span><\/p>\n<p><strong>Reorder Point Formula:<\/strong><\/p>\n<p style=\"text-align: center;\"><b><i>ROP = (Average Demand \u00d7 Lead Time) + Safety Stock<\/i><\/b><\/p>\n<ul>\n<li style=\"font-weight: 400;\"><b>Average demand x lead time<\/b><span style=\"font-weight: 400;\">: This represents the expected demand during the lead time, which is the time it takes for a new order to arrive.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Safety stock<\/b><span style=\"font-weight: 400;\">: This extra inventory ensures that even if demand spikes or there are delays in delivery, you can continue to meet customer needs without running out of stock.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">By combining both elements, the reorder point ensures that inventory is ordered at the right time to maintain a steady supply without excess stock. When stock reaches the reorder point, it&#8217;s time to place a new order, minimizing the risk of stockouts while optimizing inventory levels.<\/span><\/p>\n<h2><b><span id=\"risk\">Risks Related to Safety Stock<\/span><\/b><\/h2>\n<p><span style=\"font-weight: 400;\">While safety stock is essential for preventing stockouts, holding too much inventory can lead to several risks. It&#8217;s important to find the right balance. Here are the key risks associated with safety stock:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\"><b>Excess inventory costs<\/b><span style=\"font-weight: 400;\"> \u2013 Holding too much safety stock ties up valuable capital in unused goods. This increases storage costs, including warehouse space, insurance, and the risk of product obsolescence.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Obsolescence and spoilage<\/b><span style=\"font-weight: 400;\"> \u2013 For businesses dealing with perishable goods or products with limited lifespans, excess stock can lead to spoilage or obsolescence. This can result in significant losses, especially if the items are not sold before their expiry.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Inventory mismanagement<\/b><span style=\"font-weight: 400;\"> \u2013 Maintaining high levels of safety stock may encourage poor inventory management practices. Companies might focus too much on stock quantity rather than on demand forecasting and efficient supply chain management.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Cash flow issues<\/b><span style=\"font-weight: 400;\"> \u2013 Overstocking can strain cash flow by investing too much capital in inventory that is not immediately needed. This can limit your ability to invest in other areas of the business, such as marketing or expansion.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">While safety stock helps mitigate risks like stockouts, it&#8217;s essential to manage it effectively to avoid issues like overstocking or high storage costs. With a reliable inventory software, you can automate calculations and optimize stock levels effortlessly.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">If you\u2019re interested in streamlining your inventory management, click the banner below to explore our pricing and discover the best plan tailored to your business needs.<\/span><\/p>\n<p><span style=\"font-weight: 400;\"><style>\r\n.cta-in-article-image .desktop-banner{\r\n    display: none;\r\n    text-align: center;\r\n}\r\n.cta-in-article-image .desktop-mobile{\r\n    display: block;\r\n    text-align: center;\r\n    width: 100%;\r\n}\r\n@media (min-width: 650px) {\r\n    .cta-in-article-image .desktop-banner {\r\n        display: block!important;\r\n    }\r\n}\r\n@media (min-width: 650px) {\r\n   .cta-in-article-image .desktop-mobile {\r\n        display: none!important;\r\n    }\r\n}\r\n<\/style>\r\n<div class=\"cta-in-article-image\">\r\n\t<a href=\"https:\/\/www.hashmicro.com\/grants?utm_source=blog&medium=banner-article\" target=\"_blank\" rel=\"noopener\">\r\n\t\t<div id=\"desktop-banner-container\">\r\n\t\t\t<div class=\"desktop-banner\">\r\n<!-- \tnew CTC Grants Banner\t\t -->\r\n\t\t\t\t<img decoding=\"async\" width='696' height='189' src=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2025\/07\/CTC-Grants-scaled.webp\" alt=\"download skema harga software erp\">\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t\t<div id=\"mobile-banner-container\">\r\n\t\t\t<div class=\"desktop-mobile\">\r\n\t\t\t\t<img decoding=\"async\" width='450' height='497' src=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2023\/11\/EDG-Banner-Mobile.png.webp\" alt=\"download skema harga software erp\">\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t<\/a>\r\n<\/div>\r\n\r\n\r\n<\/span><\/p>\n<h2><b>Maximize Inventory Efficiency with HashMicro Software<\/b><\/h2>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-61416\" src=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1.webp\" alt=\"inventory software\" width=\"782\" height=\"479\" srcset=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1.webp 782w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1-300x184.webp 300w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1-768x470.webp 768w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1-686x420.webp 686w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1-150x92.webp 150w, https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/08\/Managemen-Inventoris-1-696x426.webp 696w\" sizes=\"auto, (max-width: 782px) 100vw, 782px\" \/><\/p>\n<p><span style=\"font-weight: 400;\">HashMicro <\/span><a href=\"https:\/\/www.hashmicro.com\/inventory\"><span style=\"font-weight: 400;\">Inventory Management Software<\/span><\/a><span style=\"font-weight: 400;\"> simplifies safety stock calculations and streamlines overall inventory management. With real-time tracking and automated processes, it helps you maintain optimal stock levels, minimizing both stockouts and excess inventory.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">By seamlessly integrating into your operations, HashMicro ensures precise safety stock calculations using real-time data. It analyzes demand patterns and lead times to provide the right buffer against uncertainties in supply and demand.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Explore how HashMicro can enhance your business with a <\/span><a href=\"https:\/\/www.hashmicro.com\/free-product-tour\/\"><span style=\"font-weight: 400;\">free product tour and consultation<\/span><\/a><span style=\"font-weight: 400;\">. This gives you the opportunity to make an informed decision and implement a solution that streamlines inventory management and optimizes safety stock levels.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Key features of HashMicro Inventory Software:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\"><b>Automated safety stock calculation<\/b><span style=\"font-weight: 400;\">: The software automatically calculates the safety stock you need, reducing stockouts and ensuring you maintain optimal inventory levels.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Stock movement tracking<\/b><span style=\"font-weight: 400;\">: HashMicro uses RFID and barcode scanning to track stock movement accurately, helping maintain up-to-date data for safety stock decisions.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Demand forecasting<\/b><span style=\"font-weight: 400;\">: It forecasts demand based on historical data, enabling you to adjust safety stock for seasonal changes and market trends.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Real-time reporting<\/b><span style=\"font-weight: 400;\">: Gain real-time insights into inventory status, stock levels, and movements, enabling quick adjustments to your safety stock calculations.<\/span><\/li>\n<li style=\"font-weight: 400;\"><b>Multi-location support<\/b><span style=\"font-weight: 400;\">: Manage inventory across multiple locations with ease. HashMicro keeps safety stock calculations consistent across all sites in real-time.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">Trusted by industry leaders like McDonald&#8217;s and Brinks, HashMicro\u2019s software is designed to optimize your inventory management.\u00a0<\/span><\/p>\n<h2><b>Conclusion<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">In conclusion, safety stock is essential for preventing stockouts and ensuring smooth business operations. By accurately calculating safety stock, businesses can avoid disruptions caused by demand fluctuations or delays in delivery while meeting customer needs efficiently.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">HashMicro<\/span><a href=\"https:\/\/www.hashmicro.com\/inventory\"><span style=\"font-weight: 400;\"> Inventory Management Software<\/span><\/a><span style=\"font-weight: 400;\"> helps businesses optimize their inventory management. With real-time tracking, automated safety stock calculations, and demand forecasting, HashMicro ensures companies maintain the right balance of stock, minimizing risks and improving operational efficiency.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">To experience how HashMicro can benefit your business, try our <\/span><a href=\"https:\/\/www.hashmicro.com\/free-product-tour\/\"><span style=\"font-weight: 400;\">free demo<\/span><\/a><span style=\"font-weight: 400;\"> and consultation. Explore the software&#8217;s features and discover how it can help you manage your inventory with ease, making informed decisions to improve your inventory processes.<\/span><\/p>\n<p><span style=\"font-weight: 400;\"><a href=\"https:\/\/www.hashmicro.com\/inventory?medium=moneysite-banner\" target=\"_blank\"><img decoding=\"async\" loading=\"lazy\" width=\"712\" src=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2025\/06\/Inventory.webp\" alt=\"Inventory Management\"><\/a><\/span><\/p>\n<h2><strong>Frequently Asked Questions about Safety Stock Formula<\/strong><\/h2>\n<ul class=\"bottom_faq\">\n<li>\n<details>\n<summary><strong>How do you calculate safety stock?<\/strong><\/summary>\n<p>To calculate safety stock, you can use formulas like the Z-score method, EOQ, or the Simplified method, each helping determine the right buffer based on factors like demand variability and order sizes.<\/p>\n<\/details>\n<\/li>\n<li>\n<details>\n<summary><strong>What is the 50% rule of safety stock?<\/strong><\/summary>\n<p>The 50% rule of safety stock is a simple approach that suggests setting safety stock equal to 50% of the average demand during lead time. This rule is often used for businesses with relatively stable demand, but it can be less accurate compared to more advanced methods.<\/p>\n<\/details>\n<\/li>\n<li>\n<details>\n<summary><strong>How to find z value for service level?<\/strong><\/summary>\n<p>To find the Z value for a specific service level, refer to a Z-table or use statistical software. For example, a 90% service level corresponds to a Z-value of 1.28, 95% to 1.65, and 99% to 2.33. These values represent the number of standard deviations needed to meet the desired service level.<\/p>\n<p>{<br \/>\n&#8220;@context&#8221;: &#8220;https:\/\/schema.org&#8221;,<br \/>\n&#8220;@type&#8221;: &#8220;FAQPage&#8221;,<br \/>\n&#8220;mainEntity&#8221;: [{<br \/>\n&#8220;@type&#8221;: &#8220;Question&#8221;,<br \/>\n&#8220;name&#8221;: &#8220;How do you calculate safety stock?&#8221;,<br \/>\n&#8220;acceptedAnswer&#8221;: {<br \/>\n&#8220;@type&#8221;: &#8220;Answer&#8221;,<br \/>\n&#8220;text&#8221;: &#8220;To calculate safety stock, you can use formulas like the Z-score method, EOQ, or the Simplified method, each helping determine the right buffer based on factors like demand variability and order sizes.&#8221;<br \/>\n}<br \/>\n},{<br \/>\n&#8220;@type&#8221;: &#8220;Question&#8221;,<br \/>\n&#8220;name&#8221;: &#8220;What is the 50% rule of safety stock?&#8221;,<br \/>\n&#8220;acceptedAnswer&#8221;: {<br \/>\n&#8220;@type&#8221;: &#8220;Answer&#8221;,<br \/>\n&#8220;text&#8221;: &#8220;The 50% rule of safety stock is a simple approach that suggests setting safety stock equal to 50% of the average demand during lead time. This rule is often used for businesses with relatively stable demand, but it can be less accurate compared to more advanced methods.&#8221;<br \/>\n}<br \/>\n},{<br \/>\n&#8220;@type&#8221;: &#8220;Question&#8221;,<br \/>\n&#8220;name&#8221;: &#8220;How to find z value for service level?&#8221;,<br \/>\n&#8220;acceptedAnswer&#8221;: {<br \/>\n&#8220;@type&#8221;: &#8220;Answer&#8221;,<br \/>\n&#8220;text&#8221;: &#8220;To find the Z value for a specific service level, refer to a Z-table or use statistical software. For example, a 90% service level corresponds to a Z-value of 1.28, 95% to 1.65, and 99% to 2.33. These values represent the number of standard deviations needed to meet the desired service level.&#8221;<br \/>\n}<br \/>\n}]<br \/>\n}<\/p>\n<\/details>\n<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The safety stock formula helps businesses maintain extra inventory to prevent stockouts due to unexpected demand or delivery delays. This ensures that you have enough products on hand, without overstocking, to balance supply and demand effectively. Managing safety stock is essential for smooth business operations. Inventory management software makes it easier to calculate and track [&hellip;]<\/p>\n","protected":false},"author":153,"featured_media":67574,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[88],"tags":[],"class_list":{"0":"post-64534","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-inventory"},"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v26.6 (Yoast SEO v26.6) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Understanding Safety Stock Formula for Better Inventory Control<\/title>\n<meta name=\"description\" content=\"Learn how the safety stock formula prevents stockouts and overstocking, and how HashMicro optimizes inventory management for better control.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Understanding Safety Stock Formula for Better Inventory Control\" \/>\n<meta property=\"og:description\" content=\"Learn how the safety stock formula prevents stockouts and overstocking, and how HashMicro optimizes inventory management for better control.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\" \/>\n<meta property=\"og:site_name\" content=\"BusinessTech\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/web.facebook.com\/hashmicro\/\" \/>\n<meta property=\"article:published_time\" content=\"2024-12-04T09:35:59+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-07-23T08:43:17+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"675\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/webp\" \/>\n<meta name=\"author\" content=\"Chandra Natsir\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@hashmicro\" \/>\n<meta name=\"twitter:site\" content=\"@hashmicro\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Chandra Natsir\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"12 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\"},\"author\":{\"name\":\"Chandra Natsir\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#\/schema\/person\/f17501aef487b92b4ffc58a7ef7ab97b\"},\"headline\":\"Understanding Safety Stock Formula for Better Inventory Control\",\"datePublished\":\"2024-12-04T09:35:59+00:00\",\"dateModified\":\"2025-07-23T08:43:17+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\"},\"wordCount\":2381,\"publisher\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp\",\"articleSection\":[\"Inventory\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\",\"name\":\"Understanding Safety Stock Formula for Better Inventory Control\",\"isPartOf\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp\",\"datePublished\":\"2024-12-04T09:35:59+00:00\",\"dateModified\":\"2025-07-23T08:43:17+00:00\",\"description\":\"Learn how the safety stock formula prevents stockouts and overstocking, and how HashMicro optimizes inventory management for better control.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp\",\"contentUrl\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp\",\"width\":1200,\"height\":675},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.hashmicro.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Understanding Safety Stock Formula for Better Inventory Control\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#website\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/\",\"name\":\"BusinessTech\",\"description\":\"Business Management Blog\",\"publisher\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.hashmicro.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#organization\",\"name\":\"HashMicro\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2016\/02\/bt_logo-1.png\",\"contentUrl\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2016\/02\/bt_logo-1.png\",\"width\":334,\"height\":51,\"caption\":\"HashMicro\"},\"image\":{\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/web.facebook.com\/hashmicro\/\",\"https:\/\/x.com\/hashmicro\",\"https:\/\/www.linkedin.com\/company\/hashmicro\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#\/schema\/person\/f17501aef487b92b4ffc58a7ef7ab97b\",\"name\":\"Chandra Natsir\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.hashmicro.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2023\/02\/cropped-DALL\u00b7E-2023-02-13-16.32.57-a-real-photo-of-asian-man-1-1-96x96.png\",\"contentUrl\":\"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2023\/02\/cropped-DALL\u00b7E-2023-02-13-16.32.57-a-real-photo-of-asian-man-1-1-96x96.png\",\"caption\":\"Chandra Natsir\"},\"description\":\"A content writer with a strong interest in writing and technology. Chandra is dedicated to writing useful, entertaining, and relevant information for readers, and he continues to develop content that connects and inspires them.\",\"url\":\"https:\/\/www.hashmicro.com\/blog\/author\/chandra-natsir\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Understanding Safety Stock Formula for Better Inventory Control","description":"Learn how the safety stock formula prevents stockouts and overstocking, and how HashMicro optimizes inventory management for better control.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/","og_locale":"en_US","og_type":"article","og_title":"Understanding Safety Stock Formula for Better Inventory Control","og_description":"Learn how the safety stock formula prevents stockouts and overstocking, and how HashMicro optimizes inventory management for better control.","og_url":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/","og_site_name":"BusinessTech","article_publisher":"https:\/\/web.facebook.com\/hashmicro\/","article_published_time":"2024-12-04T09:35:59+00:00","article_modified_time":"2025-07-23T08:43:17+00:00","og_image":[{"width":1200,"height":675,"url":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp","type":"image\/webp"}],"author":"Chandra Natsir","twitter_card":"summary_large_image","twitter_creator":"@hashmicro","twitter_site":"@hashmicro","twitter_misc":{"Written by":"Chandra Natsir","Est. reading time":"12 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#article","isPartOf":{"@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/"},"author":{"name":"Chandra Natsir","@id":"https:\/\/www.hashmicro.com\/blog\/#\/schema\/person\/f17501aef487b92b4ffc58a7ef7ab97b"},"headline":"Understanding Safety Stock Formula for Better Inventory Control","datePublished":"2024-12-04T09:35:59+00:00","dateModified":"2025-07-23T08:43:17+00:00","mainEntityOfPage":{"@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/"},"wordCount":2381,"publisher":{"@id":"https:\/\/www.hashmicro.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage"},"thumbnailUrl":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp","articleSection":["Inventory"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/","url":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/","name":"Understanding Safety Stock Formula for Better Inventory Control","isPartOf":{"@id":"https:\/\/www.hashmicro.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage"},"image":{"@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage"},"thumbnailUrl":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp","datePublished":"2024-12-04T09:35:59+00:00","dateModified":"2025-07-23T08:43:17+00:00","description":"Learn how the safety stock formula prevents stockouts and overstocking, and how HashMicro optimizes inventory management for better control.","breadcrumb":{"@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#primaryimage","url":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp","contentUrl":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2024\/12\/Stock-management.webp","width":1200,"height":675},{"@type":"BreadcrumbList","@id":"https:\/\/www.hashmicro.com\/blog\/safety-stock-formula\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.hashmicro.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Understanding Safety Stock Formula for Better Inventory Control"}]},{"@type":"WebSite","@id":"https:\/\/www.hashmicro.com\/blog\/#website","url":"https:\/\/www.hashmicro.com\/blog\/","name":"BusinessTech","description":"Business Management Blog","publisher":{"@id":"https:\/\/www.hashmicro.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.hashmicro.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.hashmicro.com\/blog\/#organization","name":"HashMicro","url":"https:\/\/www.hashmicro.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hashmicro.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2016\/02\/bt_logo-1.png","contentUrl":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2016\/02\/bt_logo-1.png","width":334,"height":51,"caption":"HashMicro"},"image":{"@id":"https:\/\/www.hashmicro.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/web.facebook.com\/hashmicro\/","https:\/\/x.com\/hashmicro","https:\/\/www.linkedin.com\/company\/hashmicro"]},{"@type":"Person","@id":"https:\/\/www.hashmicro.com\/blog\/#\/schema\/person\/f17501aef487b92b4ffc58a7ef7ab97b","name":"Chandra Natsir","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hashmicro.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2023\/02\/cropped-DALL\u00b7E-2023-02-13-16.32.57-a-real-photo-of-asian-man-1-1-96x96.png","contentUrl":"https:\/\/www.hashmicro.com\/blog\/wp-content\/uploads\/2023\/02\/cropped-DALL\u00b7E-2023-02-13-16.32.57-a-real-photo-of-asian-man-1-1-96x96.png","caption":"Chandra Natsir"},"description":"A content writer with a strong interest in writing and technology. Chandra is dedicated to writing useful, entertaining, and relevant information for readers, and he continues to develop content that connects and inspires them.","url":"https:\/\/www.hashmicro.com\/blog\/author\/chandra-natsir\/"}]}},"order_j":"","_links":{"self":[{"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/posts\/64534","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/users\/153"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/comments?post=64534"}],"version-history":[{"count":4,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/posts\/64534\/revisions"}],"predecessor-version":[{"id":74101,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/posts\/64534\/revisions\/74101"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/media\/67574"}],"wp:attachment":[{"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/media?parent=64534"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/categories?post=64534"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hashmicro.com\/blog\/wp-json\/wp\/v2\/tags?post=64534"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}