<?xml version="1.0" encoding="UTF-8"?>

<!--XBRL Document Created with the Workiva Platform-->
<!--Copyright 2024 Workiva-->
<!--r:de6c1181-8a91-4197-99f3-7587c00d1afc,g:6c97d235-6675-4792-aafb-694fdf0c6bf8-->
<link:linkbase xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd">
  <link:roleRef roleURI="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFINCOME" xlink:type="simple" xlink:href="hsy-20240929.xsd#CONSOLIDATEDSTATEMENTSOFINCOME"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFINCOME" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_2e056214-06ce-4d39-82a1-1b8bbb135f11" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingIncomeLoss_55e05f32-112b-41a4-a797-530276203796" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_2e056214-06ce-4d39-82a1-1b8bbb135f11" xlink:to="loc_us-gaap_OperatingIncomeLoss_55e05f32-112b-41a4-a797-530276203796" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_db27c3bf-45c0-45a9-a08f-65e286c70565" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_2e056214-06ce-4d39-82a1-1b8bbb135f11" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_db27c3bf-45c0-45a9-a08f-65e286c70565" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_335fd0c2-4314-4765-b457-31d108bdab7c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherNonoperatingIncomeExpense"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_2e056214-06ce-4d39-82a1-1b8bbb135f11" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_335fd0c2-4314-4765-b457-31d108bdab7c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingIncomeLoss_a57d79d0-90ff-4a80-bfc4-eddd5476f5a9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GrossProfit_c849c7b1-eae7-4595-962f-97d3f7ee0668" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GrossProfit"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_a57d79d0-90ff-4a80-bfc4-eddd5476f5a9" xlink:to="loc_us-gaap_GrossProfit_c849c7b1-eae7-4595-962f-97d3f7ee0668" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_5d5ea9ce-d5ac-488d-9fbc-5723f0f9bfda" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SellingGeneralAndAdministrativeExpense"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_a57d79d0-90ff-4a80-bfc4-eddd5476f5a9" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_5d5ea9ce-d5ac-488d-9fbc-5723f0f9bfda" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_RestructuringChargesBusinessRealignment_901b1048-8784-456f-88bc-2cd4183ebf7e" xlink:href="hsy-20240929.xsd#hsy_RestructuringChargesBusinessRealignment"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_a57d79d0-90ff-4a80-bfc4-eddd5476f5a9" xlink:to="loc_hsy_RestructuringChargesBusinessRealignment_901b1048-8784-456f-88bc-2cd4183ebf7e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GrossProfit_0d78bac5-7fd0-49f1-8a0f-59bff6f0a618" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GrossProfit"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_9a72c7b1-8cce-4ea3-855d-8e8fae753c53" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GrossProfit_0d78bac5-7fd0-49f1-8a0f-59bff6f0a618" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_9a72c7b1-8cce-4ea3-855d-8e8fae753c53" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_e32a753c-3cd1-45e6-aeb0-932a9182f761" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CostOfGoodsAndServicesSold"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GrossProfit_0d78bac5-7fd0-49f1-8a0f-59bff6f0a618" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_e32a753c-3cd1-45e6-aeb0-932a9182f761" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_7888009a-d35a-47b9-b3cd-47ca83a549a4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_e403d135-dc54-4600-8df8-96f6bba3a7fb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeTaxExpenseBenefit"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_7888009a-d35a-47b9-b3cd-47ca83a549a4" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_e403d135-dc54-4600-8df8-96f6bba3a7fb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_bb35e7c5-057d-409e-b2ec-34c9d28d5bc4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_7888009a-d35a-47b9-b3cd-47ca83a549a4" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_bb35e7c5-057d-409e-b2ec-34c9d28d5bc4" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOME" xlink:type="simple" xlink:href="hsy-20240929.xsd#CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOME"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOME" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax_ca98babb-6296-48db-971b-7c2e73003398" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossBeforeTax_416a063f-2543-4627-b4f0-60c2de17ec3d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossBeforeTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax_ca98babb-6296-48db-971b-7c2e73003398" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossBeforeTax_416a063f-2543-4627-b4f0-60c2de17ec3d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossTax_4f27b6c6-78e1-4986-999b-86a9aa5162d6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax_ca98babb-6296-48db-971b-7c2e73003398" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossTax_4f27b6c6-78e1-4986-999b-86a9aa5162d6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossTax_b19d5281-8a2a-4144-9b72-4579b9bbbf19" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentTax_993883f7-19d5-47ec-816d-148fccf97a41" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTax_b19d5281-8a2a-4144-9b72-4579b9bbbf19" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentTax_993883f7-19d5-47ec-816d-148fccf97a41" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodTax_3feb3b1b-e097-480f-a8d1-8533367f3a80" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTax_b19d5281-8a2a-4144-9b72-4579b9bbbf19" xlink:to="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodTax_3feb3b1b-e097-480f-a8d1-8533367f3a80" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossTax_8e28e883-60da-458f-bcfc-4364f9dd39d7" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossTax"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTax_b19d5281-8a2a-4144-9b72-4579b9bbbf19" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossTax_8e28e883-60da-458f-bcfc-4364f9dd39d7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationTax_91e0c938-466f-4b3f-b246-49a9784824a5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationTax"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTax_b19d5281-8a2a-4144-9b72-4579b9bbbf19" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationTax_91e0c938-466f-4b3f-b246-49a9784824a5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax_68b17b4d-0838-47a8-a59b-341d82cd0570" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTax_b19d5281-8a2a-4144-9b72-4579b9bbbf19" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax_68b17b4d-0838-47a8-a59b-341d82cd0570" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax_9237bfe2-7d0e-4b55-8971-3bb819301e84" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentBeforeTax_0c78a401-26c3-495c-8895-2173490c44c8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentBeforeTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax_9237bfe2-7d0e-4b55-8971-3bb819301e84" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentBeforeTax_0c78a401-26c3-495c-8895-2173490c44c8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentTax_f2673b40-ec3e-4562-8e54-4b0bb3203a76" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax_9237bfe2-7d0e-4b55-8971-3bb819301e84" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentTax_f2673b40-ec3e-4562-8e54-4b0bb3203a76" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_10395d6f-03dd-418f-9edb-5804c39cda22" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax_fd294269-53cd-4440-8de4-13d52ae593f8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_10395d6f-03dd-418f-9edb-5804c39cda22" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax_fd294269-53cd-4440-8de4-13d52ae593f8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationTax_e354cbb2-4f8a-4db5-a5f7-d408e4925aa4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_10395d6f-03dd-418f-9edb-5804c39cda22" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationTax_e354cbb2-4f8a-4db5-a5f7-d408e4925aa4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_218570f5-1d5c-4e83-b3d8-b5ffc8418167" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossBeforeTax_a01c3a09-9a8b-4d31-8133-cbf333001337" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossBeforeTax"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_218570f5-1d5c-4e83-b3d8-b5ffc8418167" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossBeforeTax_a01c3a09-9a8b-4d31-8133-cbf333001337" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentBeforeTax_269a0997-622d-4695-92e3-e31bf3f0d8aa" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentBeforeTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_218570f5-1d5c-4e83-b3d8-b5ffc8418167" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentBeforeTax_269a0997-622d-4695-92e3-e31bf3f0d8aa" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax_8ff08385-1f8c-470f-8882-f437c06d3ee9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_218570f5-1d5c-4e83-b3d8-b5ffc8418167" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax_8ff08385-1f8c-470f-8882-f437c06d3ee9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationBeforeTax_169fe16b-bb65-4ae7-8d62-6e6c6252199a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationBeforeTax"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_218570f5-1d5c-4e83-b3d8-b5ffc8418167" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationBeforeTax_169fe16b-bb65-4ae7-8d62-6e6c6252199a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansNetUnamortizedGainLossArisingDuringPeriodBeforeTax_40c2691f-39a4-4d0b-83ac-f9e0719bc3f4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansNetUnamortizedGainLossArisingDuringPeriodBeforeTax"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_218570f5-1d5c-4e83-b3d8-b5ffc8418167" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansNetUnamortizedGainLossArisingDuringPeriodBeforeTax_40c2691f-39a4-4d0b-83ac-f9e0719bc3f4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ComprehensiveIncomeNetOfTax_48bcfc40-dc12-4103-a39b-60bd0e6a7a92" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ComprehensiveIncomeNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_5dd04fde-379e-4a5e-9d0b-c870260b0822" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_48bcfc40-dc12-4103-a39b-60bd0e6a7a92" xlink:to="loc_us-gaap_NetIncomeLoss_5dd04fde-379e-4a5e-9d0b-c870260b0822" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_7735b7de-1bb1-4f15-a44f-0b9f3a49de0e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_48bcfc40-dc12-4103-a39b-60bd0e6a7a92" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_7735b7de-1bb1-4f15-a44f-0b9f3a49de0e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_ec24be61-a0de-42fa-bacd-fc1db313760d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_7c601dea-15b3-4ae9-bcf2-6674c8ad7814" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_ec24be61-a0de-42fa-bacd-fc1db313760d" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTax_7c601dea-15b3-4ae9-bcf2-6674c8ad7814" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossTax_d7c921d7-20bf-41eb-b2d2-0aa0aca91bbb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_ec24be61-a0de-42fa-bacd-fc1db313760d" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossTax_d7c921d7-20bf-41eb-b2d2-0aa0aca91bbb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_72be78de-2f4e-4c5c-8219-0290dec02c91" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationBeforeTax_7ef61e49-dd61-42af-a235-892cb7a5c904" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationBeforeTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_72be78de-2f4e-4c5c-8219-0290dec02c91" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationBeforeTax_7ef61e49-dd61-42af-a235-892cb7a5c904" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax_61baab99-d05c-458a-bd4e-1e3a69a28bcd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_72be78de-2f4e-4c5c-8219-0290dec02c91" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax_61baab99-d05c-458a-bd4e-1e3a69a28bcd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax_c880f600-fea9-465f-9d89-2e8cf8b54568" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodTax_0f7cfe9b-dd54-45ff-9f45-3c78323b6b36" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodTax"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax_c880f600-fea9-465f-9d89-2e8cf8b54568" xlink:to="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodTax_0f7cfe9b-dd54-45ff-9f45-3c78323b6b36" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansNetUnamortizedGainLossArisingDuringPeriodBeforeTax_23de1f2e-685f-4af3-93e5-12192504c5f7" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansNetUnamortizedGainLossArisingDuringPeriodBeforeTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax_c880f600-fea9-465f-9d89-2e8cf8b54568" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansNetUnamortizedGainLossArisingDuringPeriodBeforeTax_23de1f2e-685f-4af3-93e5-12192504c5f7" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOME_1" xlink:type="simple" xlink:href="hsy-20240929.xsd#CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOME_1"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOME_1" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_12629813-92aa-4f03-b5df-971e9e5ba7d0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax_d42e1ca6-a79a-476f-8e3e-f9dbdb3ee7e6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_12629813-92aa-4f03-b5df-971e9e5ba7d0" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossForeignCurrencyTransactionAndTranslationAdjustmentNetOfTax_d42e1ca6-a79a-476f-8e3e-f9dbdb3ee7e6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax_cacefe93-34bf-4d5a-bc74-f1163d8a7777" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_12629813-92aa-4f03-b5df-971e9e5ba7d0" xlink:to="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansNetUnamortizedGainLossArisingDuringPeriodNetOfTax_cacefe93-34bf-4d5a-bc74-f1163d8a7777" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_06d3ecad-8e00-4018-b33e-2ccfe7d83a5a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_12629813-92aa-4f03-b5df-971e9e5ba7d0" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_06d3ecad-8e00-4018-b33e-2ccfe7d83a5a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_ff9d50b5-78f2-4e5f-a541-40a232599f2b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_12629813-92aa-4f03-b5df-971e9e5ba7d0" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_ff9d50b5-78f2-4e5f-a541-40a232599f2b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax_d604a9d0-ece7-40a5-a82e-2635b6aba61b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_12629813-92aa-4f03-b5df-971e9e5ba7d0" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIPensionAndOtherPostretirementBenefitPlansForNetGainLossNetOfTax_d604a9d0-ece7-40a5-a82e-2635b6aba61b" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/CONSOLIDATEDBALANCESHEETS" xlink:type="simple" xlink:href="hsy-20240929.xsd#CONSOLIDATEDBALANCESHEETS"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/CONSOLIDATEDBALANCESHEETS" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsCurrent_5e26cb4a-fe0b-43d2-add0-706582cd909b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AssetsCurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_1c04fe74-445f-44f7-8ed0-16f6f91bc0d9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_5e26cb4a-fe0b-43d2-add0-706582cd909b" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_1c04fe74-445f-44f7-8ed0-16f6f91bc0d9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsReceivableNetCurrent_d394e6c0-a107-434e-be6b-bcad9e8ec3ea" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccountsReceivableNetCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_5e26cb4a-fe0b-43d2-add0-706582cd909b" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_d394e6c0-a107-434e-be6b-bcad9e8ec3ea" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryNet_2ce0d8c4-1e94-4ae1-b10e-6b8ab1b2299e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InventoryNet"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_5e26cb4a-fe0b-43d2-add0-706582cd909b" xlink:to="loc_us-gaap_InventoryNet_2ce0d8c4-1e94-4ae1-b10e-6b8ab1b2299e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_4ed02e28-240e-4bcd-a46d-956ee22fd060" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PrepaidExpenseAndOtherAssetsCurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_5e26cb4a-fe0b-43d2-add0-706582cd909b" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_4ed02e28-240e-4bcd-a46d-956ee22fd060" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Assets"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsCurrent_34d63998-8e78-440e-8f90-3c4a3f3507b4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AssetsCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:to="loc_us-gaap_AssetsCurrent_34d63998-8e78-440e-8f90-3c4a3f3507b4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_bbb8af3f-4d31-4e4c-b467-d19d5b1da6a8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PropertyPlantAndEquipmentNet"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_bbb8af3f-4d31-4e4c-b467-d19d5b1da6a8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Goodwill_0ddd2a6a-c065-43c2-8db1-c7908ff8e8cb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Goodwill"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:to="loc_us-gaap_Goodwill_0ddd2a6a-c065-43c2-8db1-c7908ff8e8cb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_435190a5-5be7-4fa4-b5ef-156ed7bc42c5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_435190a5-5be7-4fa4-b5ef-156ed7bc42c5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_d93c8dc6-5e0d-4bfd-9ed2-12327471ca67" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherAssetsNoncurrent"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_d93c8dc6-5e0d-4bfd-9ed2-12327471ca67" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxAssetsNet_f293123f-5431-4150-9298-88d8c621415d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DeferredIncomeTaxAssetsNet"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_3d7b5a19-bd9d-4c1b-ad6c-5205b8c15a02" xlink:to="loc_us-gaap_DeferredIncomeTaxAssetsNet_f293123f-5431-4150-9298-88d8c621415d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_f92155e5-ee4f-4365-9ac5-227e71758494" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LiabilitiesAndStockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_637b15aa-38c2-4721-9b12-ba9475d0d32d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Liabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_f92155e5-ee4f-4365-9ac5-227e71758494" xlink:to="loc_us-gaap_Liabilities_637b15aa-38c2-4721-9b12-ba9475d0d32d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_9c23dbe5-5b99-4c35-a1b0-0b1590b3d1af" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_f92155e5-ee4f-4365-9ac5-227e71758494" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_9c23dbe5-5b99-4c35-a1b0-0b1590b3d1af" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AdditionalPaidInCapital_5e97de57-1599-466d-a7a8-5ba1fa251241" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AdditionalPaidInCapital"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:to="loc_us-gaap_AdditionalPaidInCapital_5e97de57-1599-466d-a7a8-5ba1fa251241" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommonStockValue_0bdebc94-5dc8-426b-89fd-5e2eaaa620af" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CommonStockValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:to="loc_us-gaap_CommonStockValue_0bdebc94-5dc8-426b-89fd-5e2eaaa620af" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_TreasuryStockCommonValue_44cfb9df-29fc-4788-8939-fb20fcfb51fc" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_TreasuryStockCommonValue"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:to="loc_us-gaap_TreasuryStockCommonValue_44cfb9df-29fc-4788-8939-fb20fcfb51fc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PreferredStockValue_c01e5fa5-6283-4832-97bb-b1aca7db383e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PreferredStockValue"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:to="loc_us-gaap_PreferredStockValue_c01e5fa5-6283-4832-97bb-b1aca7db383e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_85f2da5f-6831-4238-8a6a-bad64805bf76" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RetainedEarningsAccumulatedDeficit"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_85f2da5f-6831-4238-8a6a-bad64805bf76" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_6ee5fc29-3864-48db-8f24-80518e1c4e44" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_801d49ce-67e4-4dcd-8a71-c7b5eb9d6f32" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_6ee5fc29-3864-48db-8f24-80518e1c4e44" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesCurrent_9583cfc8-6aaa-4790-9b4c-2fb47d57e73f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LiabilitiesCurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableCurrent_aa1f67bd-d0c6-4963-aa14-6b7d9dfdcb86" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccountsPayableCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_9583cfc8-6aaa-4790-9b4c-2fb47d57e73f" xlink:to="loc_us-gaap_AccountsPayableCurrent_aa1f67bd-d0c6-4963-aa14-6b7d9dfdcb86" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_fc56398b-9383-4ba8-9b9a-2af5f67603e2" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccruedLiabilitiesCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_9583cfc8-6aaa-4790-9b4c-2fb47d57e73f" xlink:to="loc_us-gaap_AccruedLiabilitiesCurrent_fc56398b-9383-4ba8-9b9a-2af5f67603e2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedIncomeTaxesCurrent_99de1840-f841-4bd1-9940-7e55ba8ec9c0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccruedIncomeTaxesCurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_9583cfc8-6aaa-4790-9b4c-2fb47d57e73f" xlink:to="loc_us-gaap_AccruedIncomeTaxesCurrent_99de1840-f841-4bd1-9940-7e55ba8ec9c0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ShortTermBorrowings_92cd898c-18ca-48ec-915b-e093dfcacada" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ShortTermBorrowings"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_9583cfc8-6aaa-4790-9b4c-2fb47d57e73f" xlink:to="loc_us-gaap_ShortTermBorrowings_92cd898c-18ca-48ec-915b-e093dfcacada" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtCurrent_960f6c74-2695-4be2-b705-3677a21a20d3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebtCurrent"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_9583cfc8-6aaa-4790-9b4c-2fb47d57e73f" xlink:to="loc_us-gaap_LongTermDebtCurrent_960f6c74-2695-4be2-b705-3677a21a20d3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_12b903f7-cb66-468a-9cff-fb1933dcf1fd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Liabilities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesCurrent_9ced9f1e-d4a2-4c7c-9813-fec51e0d2b68" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LiabilitiesCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_12b903f7-cb66-468a-9cff-fb1933dcf1fd" xlink:to="loc_us-gaap_LiabilitiesCurrent_9ced9f1e-d4a2-4c7c-9813-fec51e0d2b68" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_44851bbc-347c-4ae0-a15e-69783072d84c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebtAndCapitalLeaseObligations"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_12b903f7-cb66-468a-9cff-fb1933dcf1fd" xlink:to="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_44851bbc-347c-4ae0-a15e-69783072d84c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_62f8cdb9-51fc-49ec-9c0e-7464f8835e32" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherLiabilitiesNoncurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_12b903f7-cb66-468a-9cff-fb1933dcf1fd" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_62f8cdb9-51fc-49ec-9c0e-7464f8835e32" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_08c7171c-ca3e-47a2-85c5-fc6cdcfad20e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DeferredIncomeTaxLiabilitiesNet"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_12b903f7-cb66-468a-9cff-fb1933dcf1fd" xlink:to="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_08c7171c-ca3e-47a2-85c5-fc6cdcfad20e" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFCASHFLOWS" xlink:type="simple" xlink:href="hsy-20240929.xsd#CONSOLIDATEDSTATEMENTSOFCASHFLOWS"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/CONSOLIDATEDSTATEMENTSOFCASHFLOWS" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_a8b79051-896c-48a9-acfe-5cfa7fee6688" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_922e939f-1df6-472c-ab33-859d06dc1211" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_a8b79051-896c-48a9-acfe-5cfa7fee6688" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_922e939f-1df6-472c-ab33-859d06dc1211" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_c51b0f5f-e44c-43de-b643-fa1eb35dd6fe" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_a8b79051-896c-48a9-acfe-5cfa7fee6688" xlink:to="loc_us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_c51b0f5f-e44c-43de-b643-fa1eb35dd6fe" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_b1a0cb7e-b7e1-42b8-bb1e-99a28e09b7eb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_a8b79051-896c-48a9-acfe-5cfa7fee6688" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_b1a0cb7e-b7e1-42b8-bb1e-99a28e09b7eb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_26c68b05-ee3c-4c54-9e3a-11621b3a7e87" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_a8b79051-896c-48a9-acfe-5cfa7fee6688" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_26c68b05-ee3c-4c54-9e3a-11621b3a7e87" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_02c3f8bf-350e-4942-b5fa-cc0b62c901fa" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_NetIncomeLoss_02c3f8bf-350e-4942-b5fa-cc0b62c901fa" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_6648d16d-bbdf-4f69-95ee-082c8f250380" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DepreciationDepletionAndAmortization"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_6648d16d-bbdf-4f69-95ee-082c8f250380" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ShareBasedCompensation_8e7ce63b-5741-4d0f-b2f2-8ce3d0b51c9c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ShareBasedCompensation"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_ShareBasedCompensation_8e7ce63b-5741-4d0f-b2f2-8ce3d0b51c9c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxesAndTaxCredits_d54661fc-ae65-4f25-bd2e-81aff337aa1d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DeferredIncomeTaxesAndTaxCredits"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_DeferredIncomeTaxesAndTaxCredits_d54661fc-ae65-4f25-bd2e-81aff337aa1d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_18a64a56-9da3-4907-8ef5-cf2b1facacbd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_18a64a56-9da3-4907-8ef5-cf2b1facacbd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_UnrealizedGainLossOnDerivativesAndCommodityContracts_28242434-900f-4f5c-a504-5237d8ef3f1d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_UnrealizedGainLossOnDerivativesAndCommodityContracts"/>
    <link:calculationArc order="6" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_UnrealizedGainLossOnDerivativesAndCommodityContracts_28242434-900f-4f5c-a504-5237d8ef3f1d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherOperatingActivitiesCashFlowStatement_397096b8-2949-4435-ae56-eb9d5846cf2c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherOperatingActivitiesCashFlowStatement"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_OtherOperatingActivitiesCashFlowStatement_397096b8-2949-4435-ae56-eb9d5846cf2c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_5f1501e8-9840-4e1f-9aee-7f27b0390a2e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncreaseDecreaseInAccountsReceivable"/>
    <link:calculationArc order="8" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_5f1501e8-9840-4e1f-9aee-7f27b0390a2e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInInventories_8b1ca5c6-ddf1-4ac3-80b6-f198020c9c16" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncreaseDecreaseInInventories"/>
    <link:calculationArc order="9" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_IncreaseDecreaseInInventories_8b1ca5c6-ddf1-4ac3-80b6-f198020c9c16" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_22847656-851d-41b3-ba4f-12ce7db8dc39" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets"/>
    <link:calculationArc order="10" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_22847656-851d-41b3-ba4f-12ce7db8dc39" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsPayableAndAccruedLiabilities_bb3f3dac-514e-4cde-8985-4e849b49ed99" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncreaseDecreaseInAccountsPayableAndAccruedLiabilities"/>
    <link:calculationArc order="11" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsPayableAndAccruedLiabilities_bb3f3dac-514e-4cde-8985-4e849b49ed99" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedTaxesPayable_48395abd-1f82-4e52-b976-44d6c3487c2f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncreaseDecreaseInAccruedTaxesPayable"/>
    <link:calculationArc order="12" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedTaxesPayable_48395abd-1f82-4e52-b976-44d6c3487c2f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PensionAndOtherPostretirementBenefitContributions_e9fd57ba-2615-43bc-a341-91c6ee59312f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PensionAndOtherPostretirementBenefitContributions"/>
    <link:calculationArc order="13" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_PensionAndOtherPostretirementBenefitContributions_e9fd57ba-2615-43bc-a341-91c6ee59312f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInOtherOperatingCapitalNet_22863460-d095-4f63-91d9-a001559553e5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncreaseDecreaseInOtherOperatingCapitalNet"/>
    <link:calculationArc order="14" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_94813417-a48d-475c-a260-a86e0b10b483" xlink:to="loc_us-gaap_IncreaseDecreaseInOtherOperatingCapitalNet_22863460-d095-4f63-91d9-a001559553e5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromStockOptionsExercised_d016cf84-1cf2-4fc5-88af-c187a6eb4a33" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromStockOptionsExercised"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_ProceedsFromStockOptionsExercised_d016cf84-1cf2-4fc5-88af-c187a6eb4a33" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation_8250e7d0-5d4d-4516-954b-42409789dae3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation_8250e7d0-5d4d-4516-954b-42409789dae3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsOfDividendsCommonStock_daa6452c-f678-4336-9f85-04daddf6de1c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsOfDividendsCommonStock"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_PaymentsOfDividendsCommonStock_daa6452c-f678-4336-9f85-04daddf6de1c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_bd472a2b-1047-4bd4-850f-8a4896321747" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsForRepurchaseOfCommonStock"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_bd472a2b-1047-4bd4-850f-8a4896321747" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RepaymentsOfLongTermDebt_c78a279e-e570-45c0-9057-4612cbb0b90b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RepaymentsOfLongTermDebt"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_RepaymentsOfLongTermDebt_c78a279e-e570-45c0-9057-4612cbb0b90b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromRepaymentsOfShortTermDebt_2eb21c03-423f-4333-9384-caa091d566e4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromRepaymentsOfShortTermDebt"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_ProceedsFromRepaymentsOfShortTermDebt_2eb21c03-423f-4333-9384-caa091d566e4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfLongTermDebt_c24cc79e-6a68-4d91-8bd1-d4fe9baf9aac" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromIssuanceOfLongTermDebt"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_8f0365b6-ce5d-4106-b4b4-1fd104e7bb9c" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfLongTermDebt_c24cc79e-6a68-4d91-8bd1-d4fe9baf9aac" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_ba97c792-082a-4974-ac91-329ff6090c2f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForProceedsFromOtherInvestingActivities_315b032e-859e-4093-8a10-22ef8fa83be3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsForProceedsFromOtherInvestingActivities"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_ba97c792-082a-4974-ac91-329ff6090c2f" xlink:to="loc_us-gaap_PaymentsForProceedsFromOtherInvestingActivities_315b032e-859e-4093-8a10-22ef8fa83be3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireBusinessesNetOfCashAcquired_22895b06-d0b5-4561-a24c-b679cce6f89d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsToAcquireBusinessesNetOfCashAcquired"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_ba97c792-082a-4974-ac91-329ff6090c2f" xlink:to="loc_us-gaap_PaymentsToAcquireBusinessesNetOfCashAcquired_22895b06-d0b5-4561-a24c-b679cce6f89d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireEquityMethodInvestments_6622444a-9b71-430b-b2ea-75f5b783349d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsToAcquireEquityMethodInvestments"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_ba97c792-082a-4974-ac91-329ff6090c2f" xlink:to="loc_us-gaap_PaymentsToAcquireEquityMethodInvestments_6622444a-9b71-430b-b2ea-75f5b783349d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_efc82578-10c5-4309-8ce2-efe5c21e8f59" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsToAcquirePropertyPlantAndEquipment"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_ba97c792-082a-4974-ac91-329ff6090c2f" xlink:to="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_efc82578-10c5-4309-8ce2-efe5c21e8f59" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/SHORTANDLONGTERMDEBTSCHEDULEOFLONGTERMDEBTINSTRUMENTSDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#SHORTANDLONGTERMDEBTSCHEDULEOFLONGTERMDEBTINSTRUMENTSDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/SHORTANDLONGTERMDEBTSCHEDULEOFLONGTERMDEBTINSTRUMENTSDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebt_5714badc-25ff-4b72-b0cd-8c6b1f14c3c3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebt"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtCurrent_a31f43d9-adc1-4f26-acbc-106fd7e1610b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebtCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_5714badc-25ff-4b72-b0cd-8c6b1f14c3c3" xlink:to="loc_us-gaap_LongTermDebtCurrent_a31f43d9-adc1-4f26-acbc-106fd7e1610b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_4d676bba-08ae-40fc-9032-22038ae35aff" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebtNoncurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_5714badc-25ff-4b72-b0cd-8c6b1f14c3c3" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_4d676bba-08ae-40fc-9032-22038ae35aff" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/SHORTANDLONGTERMDEBTSCHEDULEOFNETINTERESTEXPENSEDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#SHORTANDLONGTERMDEBTSCHEDULEOFNETINTERESTEXPENSEDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/SHORTANDLONGTERMDEBTSCHEDULEOFNETINTERESTEXPENSEDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpense_334dea22-d937-414b-a983-499e05f62742" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseDebt_f1e323a6-abc7-428d-a080-32baa9c9f154" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpenseDebt"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestExpense_334dea22-d937-414b-a983-499e05f62742" xlink:to="loc_us-gaap_InterestExpenseDebt_f1e323a6-abc7-428d-a080-32baa9c9f154" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestCostsCapitalizedAdjustment_f5e30fcd-0800-4ba8-a281-49c3564fad63" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestCostsCapitalizedAdjustment"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestExpense_334dea22-d937-414b-a983-499e05f62742" xlink:to="loc_us-gaap_InterestCostsCapitalizedAdjustment_f5e30fcd-0800-4ba8-a281-49c3564fad63" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_7302d5f7-cd54-4088-a094-2cc515f634c1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpense_91e0ffc4-3809-4780-b49a-20d6c4523bd1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpense"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_7302d5f7-cd54-4088-a094-2cc515f634c1" xlink:to="loc_us-gaap_InterestExpense_91e0ffc4-3809-4780-b49a-20d6c4523bd1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InvestmentIncomeInterest_17b408f9-310b-4429-8f3d-19954bcad61b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InvestmentIncomeInterest"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_7302d5f7-cd54-4088-a094-2cc515f634c1" xlink:to="loc_us-gaap_InvestmentIncomeInterest_17b408f9-310b-4429-8f3d-19954bcad61b" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/FAIRVALUEMEASUREMENTSSCHEDULEOFFAIRVALUESANDCARRYINGVALUESOFLONGTERMDEBTDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#FAIRVALUEMEASUREMENTSSCHEDULEOFFAIRVALUESANDCARRYINGVALUESOFLONGTERMDEBTDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/FAIRVALUEMEASUREMENTSSCHEDULEOFFAIRVALUESANDCARRYINGVALUESOFLONGTERMDEBTDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtFairValue_42ee4735-a8da-4f6c-9bd4-9508b610d122" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebtFairValue"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_afb1312b-5176-410c-ba16-9e2e62dfff2e" xlink:href="hsy-20240929.xsd#hsy_LongtermDebtCurrentMaturitiesFairValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtFairValue_42ee4735-a8da-4f6c-9bd4-9508b610d122" xlink:to="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_afb1312b-5176-410c-ba16-9e2e62dfff2e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_d7f8888e-fc34-45f3-8186-aecef9b89ea0" xlink:href="hsy-20240929.xsd#hsy_LongtermDebtExcludingCurrentMaturitiesFairValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtFairValue_42ee4735-a8da-4f6c-9bd4-9508b610d122" xlink:to="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_d7f8888e-fc34-45f3-8186-aecef9b89ea0" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/LEASESSCHEDULEOFCOMPONENETSOFLEASEEXPENSEDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#LEASESSCHEDULEOFCOMPONENETSOFLEASEEXPENSEDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/LEASESSCHEDULEOFCOMPONENETSOFLEASEEXPENSEDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LeaseCost_e5419887-6137-49e2-89e3-ab14920773c8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LeaseCost"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseCost_ef7e3b5d-3a08-48c3-a098-6bca3fb3e711" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseCost"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LeaseCost_e5419887-6137-49e2-89e3-ab14920773c8" xlink:to="loc_us-gaap_OperatingLeaseCost_ef7e3b5d-3a08-48c3-a098-6bca3fb3e711" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseRightOfUseAssetAmortization_4c985467-8f10-4984-ac98-e09660070a3a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseRightOfUseAssetAmortization"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LeaseCost_e5419887-6137-49e2-89e3-ab14920773c8" xlink:to="loc_us-gaap_FinanceLeaseRightOfUseAssetAmortization_4c985467-8f10-4984-ac98-e09660070a3a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseInterestExpense_8b37120a-788e-40f3-9c27-8b75cec32beb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseInterestExpense"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LeaseCost_e5419887-6137-49e2-89e3-ab14920773c8" xlink:to="loc_us-gaap_FinanceLeaseInterestExpense_8b37120a-788e-40f3-9c27-8b75cec32beb" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/LEASESSUPPLEMENTALBALANCESHEETINFORMATIONRELATEDTOLEASESDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#LEASESSUPPLEMENTALBALANCESHEETINFORMATIONRELATEDTOLEASESDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/LEASESSUPPLEMENTALBALANCESHEETINFORMATIONRELATEDTOLEASESDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LeaseLiability_5f72b399-904e-48e0-bbce-fd661e5e468f" xlink:href="hsy-20240929.xsd#hsy_LeaseLiability"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityCurrent_372396c4-7fef-43f5-87e5-d4602a8596d2" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseLiabilityCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LeaseLiability_5f72b399-904e-48e0-bbce-fd661e5e468f" xlink:to="loc_us-gaap_OperatingLeaseLiabilityCurrent_372396c4-7fef-43f5-87e5-d4602a8596d2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityCurrent_40dd7463-fe20-4e67-8452-d05a1969ca27" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LeaseLiability_5f72b399-904e-48e0-bbce-fd661e5e468f" xlink:to="loc_us-gaap_FinanceLeaseLiabilityCurrent_40dd7463-fe20-4e67-8452-d05a1969ca27" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_e2e75f48-d563-43ff-9d80-cec1b6bdea02" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseLiabilityNoncurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LeaseLiability_5f72b399-904e-48e0-bbce-fd661e5e468f" xlink:to="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_e2e75f48-d563-43ff-9d80-cec1b6bdea02" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityNoncurrent_dbbc85de-a7da-4423-89cb-384d4a9eec11" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityNoncurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LeaseLiability_5f72b399-904e-48e0-bbce-fd661e5e468f" xlink:to="loc_us-gaap_FinanceLeaseLiabilityNoncurrent_dbbc85de-a7da-4423-89cb-384d4a9eec11" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LeaseRightofUseAsset_b7448ef5-3e54-4c2b-8ca2-11fecf8d2b70" xlink:href="hsy-20240929.xsd#hsy_LeaseRightofUseAsset"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseRightOfUseAsset_75baf2b7-3371-475f-a817-e29e4d07c5f3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseRightOfUseAsset"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LeaseRightofUseAsset_b7448ef5-3e54-4c2b-8ca2-11fecf8d2b70" xlink:to="loc_us-gaap_FinanceLeaseRightOfUseAsset_75baf2b7-3371-475f-a817-e29e4d07c5f3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_a19f99ea-f312-4ed2-9717-2de6c46b74eb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseRightOfUseAsset"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LeaseRightofUseAsset_b7448ef5-3e54-4c2b-8ca2-11fecf8d2b70" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_a19f99ea-f312-4ed2-9717-2de6c46b74eb" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/LEASESSCHEDULEOFMATURITIESOFLEASELIABILITIESDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#LEASESSCHEDULEOFMATURITIESOFLEASELIABILITIESDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/LEASESSCHEDULEOFMATURITIESOFLEASELIABILITIESDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearTwo_7baaf811-c974-41c4-99ad-6fd0f2738d95" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearTwo"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:to="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearTwo_7baaf811-c974-41c4-99ad-6fd0f2738d95" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearThree_be01df6a-5acb-499d-a263-2bec96c94919" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearThree"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:to="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearThree_be01df6a-5acb-499d-a263-2bec96c94919" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidRemainderOfFiscalYear_c4e55338-89e1-49a5-89e9-964285df56cd" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidRemainderOfFiscalYear"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:to="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidRemainderOfFiscalYear_c4e55338-89e1-49a5-89e9-964285df56cd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidAfterYearFour_ea528aa8-6f62-4147-969a-fa60cf37f27e" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidAfterYearFour"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:to="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidAfterYearFour_ea528aa8-6f62-4147-969a-fa60cf37f27e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearFour_d805e79a-2751-42ef-bdcb-55179106343a" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearFour"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:to="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearFour_d805e79a-2751-42ef-bdcb-55179106343a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearOne_319ebd1e-28cf-4865-ad84-9bbd94de8ad2" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearOne"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_LesseeOperatingandFinancingLeaseLiabilityPaymentsDue_1272201d-22fc-40af-aadc-04373e4c3d49" xlink:to="loc_hsy_LesseeOperatingAndFinancingLeaseLiabilityToBePaidYearOne_319ebd1e-28cf-4865-ad84-9bbd94de8ad2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear_22fe3694-e575-406f-8bb4-e91dd423d568" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear_22fe3694-e575-406f-8bb4-e91dd423d568" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths_8a166479-b7c0-4617-b10d-5fc640b53c30" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths_8a166479-b7c0-4617-b10d-5fc640b53c30" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo_59ac1c4a-844d-4ef0-bc9c-17a5182be6c1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo_59ac1c4a-844d-4ef0-bc9c-17a5182be6c1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree_e132068c-e5cd-4304-b9e7-8a0ef9668eda" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree_e132068c-e5cd-4304-b9e7-8a0ef9668eda" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour_d484bb2e-8c55-4455-a41a-85b941fab62d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour_d484bb2e-8c55-4455-a41a-85b941fab62d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_LesseeOperatingLeaseLiabilityToBePaidAfterYearFour_974c94c4-2e30-478b-9f8f-90e21291d76f" xlink:href="hsy-20240929.xsd#hsy_LesseeOperatingLeaseLiabilityToBePaidAfterYearFour"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_34f755bd-a92f-4c07-9323-65a4ce8a1710" xlink:to="loc_hsy_LesseeOperatingLeaseLiabilityToBePaidAfterYearFour_974c94c4-2e30-478b-9f8f-90e21291d76f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityPaymentsDue"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityPaymentsRemainderOfFiscalYear_0bdb3c64-9bfd-401a-9155-3d9b823b882f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityPaymentsRemainderOfFiscalYear"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:to="loc_us-gaap_FinanceLeaseLiabilityPaymentsRemainderOfFiscalYear_0bdb3c64-9bfd-401a-9155-3d9b823b882f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueNextTwelveMonths_cf557989-eaea-4fdc-b04c-53cc7ec40e68" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityPaymentsDueNextTwelveMonths"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:to="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueNextTwelveMonths_cf557989-eaea-4fdc-b04c-53cc7ec40e68" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueYearTwo_80292929-c476-4634-87c5-38459b53683a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityPaymentsDueYearTwo"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:to="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueYearTwo_80292929-c476-4634-87c5-38459b53683a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueYearThree_b0ca9ff2-3d63-4bed-9ee4-c437922d4fa2" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityPaymentsDueYearThree"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:to="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueYearThree_b0ca9ff2-3d63-4bed-9ee4-c437922d4fa2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueYearFour_1b4e70cf-cbff-4714-843c-0fe158b9d21e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinanceLeaseLiabilityPaymentsDueYearFour"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:to="loc_us-gaap_FinanceLeaseLiabilityPaymentsDueYearFour_1b4e70cf-cbff-4714-843c-0fe158b9d21e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_FinancingLeaseLiabilityToBePaidAfterYearFour_5fcd566d-da68-422e-adcc-505d063168ce" xlink:href="hsy-20240929.xsd#hsy_FinancingLeaseLiabilityToBePaidAfterYearFour"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinanceLeaseLiabilityPaymentsDue_e7c9eb13-2638-4bb4-a147-e82934b5ecf9" xlink:to="loc_hsy_FinancingLeaseLiabilityToBePaidAfterYearFour_5fcd566d-da68-422e-adcc-505d063168ce" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/PENSIONANDOTHERPOSTRETIREMENTBENEFITPLANSSCHEDULEOFCOMPONENTSOFNETPERIODICBENEFITCOSTDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#PENSIONANDOTHERPOSTRETIREMENTBENEFITPLANSSCHEDULEOFCOMPONENTSOFNETPERIODICBENEFITCOSTDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/PENSIONANDOTHERPOSTRETIREMENTBENEFITPLANSSCHEDULEOFCOMPONENTSOFNETPERIODICBENEFITCOSTDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_8df2320e-c49c-448d-94fe-735ae828b05d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanInterestCost"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_8df2320e-c49c-448d-94fe-735ae828b05d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_9ebd8af1-0fbf-4f30-9d9b-79bfe3cc023b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_9ebd8af1-0fbf-4f30-9d9b-79bfe3cc023b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_cfc50bf7-ba84-42c0-839c-06935a2f4263" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_cfc50bf7-ba84-42c0-839c-06935a2f4263" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_e2c92e7e-51a1-4bba-95f1-761e9f8b1b94" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanServiceCost"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_e2c92e7e-51a1-4bba-95f1-761e9f8b1b94" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_5e09edcb-6ffe-4921-9d2a-97e51aaea33b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_5e09edcb-6ffe-4921-9d2a-97e51aaea33b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_b9b62a49-e42f-4a3c-8437-6829c682a356" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1"/>
    <link:calculationArc order="6" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_b58d02b7-57bd-4d07-9021-d5a8d4549200" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_b9b62a49-e42f-4a3c-8437-6829c682a356" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/TREASURYSTOCKACTIVITYSCHEDULEOFTREASURYSTOCKACTIVITYDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#TREASURYSTOCKACTIVITYSCHEDULEOFTREASURYSTOCKACTIVITYDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/TREASURYSTOCKACTIVITYSCHEDULEOFTREASURYSTOCKACTIVITYDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_hsy_TreasuryStockValueExcludingExciseTax_c1bddcce-c7e5-45cd-92b3-ca3c6c9265d8" xlink:href="hsy-20240929.xsd#hsy_TreasuryStockValueExcludingExciseTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueShareBasedCompensationGross_ebb01121-2977-4d44-9555-eecf4a7eb59b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_StockIssuedDuringPeriodValueShareBasedCompensationGross"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_TreasuryStockValueExcludingExciseTax_c1bddcce-c7e5-45cd-92b3-ca3c6c9265d8" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueShareBasedCompensationGross_ebb01121-2977-4d44-9555-eecf4a7eb59b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockRepurchasedDuringPeriodValue_46665018-f33b-4b45-bc42-62dfb0ef5cfc" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_StockRepurchasedDuringPeriodValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_TreasuryStockValueExcludingExciseTax_c1bddcce-c7e5-45cd-92b3-ca3c6c9265d8" xlink:to="loc_us-gaap_StockRepurchasedDuringPeriodValue_46665018-f33b-4b45-bc42-62dfb0ef5cfc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_TreasuryStockSharesExcludingExciseTax_cd2029bb-d77e-4ce6-9776-cad7f52afbca" xlink:href="hsy-20240929.xsd#hsy_TreasuryStockSharesExcludingExciseTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_TreasuryStockSharesExciseTax_5185c447-2cfb-4bdb-8676-48d0f3e4a89a" xlink:href="hsy-20240929.xsd#hsy_TreasuryStockSharesExciseTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_TreasuryStockSharesExcludingExciseTax_cd2029bb-d77e-4ce6-9776-cad7f52afbca" xlink:to="loc_hsy_TreasuryStockSharesExciseTax_5185c447-2cfb-4bdb-8676-48d0f3e4a89a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_TreasuryStockSharesNetChangeDuringPeriod_ba47e4e2-e646-4a85-a43d-9d1f835190dd" xlink:href="hsy-20240929.xsd#hsy_TreasuryStockSharesNetChangeDuringPeriod"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_TreasuryStockSharesExcludingExciseTax_cd2029bb-d77e-4ce6-9776-cad7f52afbca" xlink:to="loc_hsy_TreasuryStockSharesNetChangeDuringPeriod_ba47e4e2-e646-4a85-a43d-9d1f835190dd" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/EARNINGSPERSHARESCHEDULEOFBASICANDDILUTEDEARNINGSPERSHAREDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#EARNINGSPERSHARESCHEDULEOFBASICANDDILUTEDEARNINGSPERSHAREDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/EARNINGSPERSHARESCHEDULEOFBASICANDDILUTEDEARNINGSPERSHAREDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_09490601-d2a7-4ebf-ba6a-b858951e444d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_e1ffc21b-c477-467d-89ec-d087a6f26e08" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_09490601-d2a7-4ebf-ba6a-b858951e444d" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_e1ffc21b-c477-467d-89ec-d087a6f26e08" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Dividends_5646fb27-3288-41b8-9aeb-3e997d0b5cff" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Dividends"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_09490601-d2a7-4ebf-ba6a-b858951e444d" xlink:to="loc_us-gaap_Dividends_5646fb27-3288-41b8-9aeb-3e997d0b5cff" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_b6782e86-43af-4362-919c-3c99df5cc10f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_ffb2448a-4baa-48c1-b46a-199f4a6811e9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_b6782e86-43af-4362-919c-3c99df5cc10f" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_ffb2448a-4baa-48c1-b46a-199f4a6811e9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_e108a13c-7963-4ad9-8320-f35302509840" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_b6782e86-43af-4362-919c-3c99df5cc10f" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_e108a13c-7963-4ad9-8320-f35302509840" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DistributedEarnings_a8601999-3beb-4215-b037-5124f6aa6a63" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DistributedEarnings"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_b6782e86-43af-4362-919c-3c99df5cc10f" xlink:to="loc_us-gaap_DistributedEarnings_a8601999-3beb-4215-b037-5124f6aa6a63" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/OTHERINCOMEEXPENSENETSCHEDULEOFOTHERINCOMEANDEXPENSENETDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#OTHERINCOMEEXPENSENETSCHEDULEOFOTHERINCOMEANDEXPENSENETDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/OTHERINCOMEEXPENSENETSCHEDULEOFOTHERINCOMEANDEXPENSENETDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_344e0e57-57e9-4bdb-a2f7-aa02c59bbf84" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherNonoperatingIncomeExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_37b3e4c0-bac7-433e-aa21-b1a41b82a601" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherNonoperatingIncomeExpense_344e0e57-57e9-4bdb-a2f7-aa02c59bbf84" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_37b3e4c0-bac7-433e-aa21-b1a41b82a601" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_DefinedBenefitPlanNonServiceCost_8e8b9e88-e6d2-4169-8faf-fd16c92ac100" xlink:href="hsy-20240929.xsd#hsy_DefinedBenefitPlanNonServiceCost"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherNonoperatingIncomeExpense_344e0e57-57e9-4bdb-a2f7-aa02c59bbf84" xlink:to="loc_hsy_DefinedBenefitPlanNonServiceCost_8e8b9e88-e6d2-4169-8faf-fd16c92ac100" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_OtherNonoperatingGainLoss_565a2f07-9d3d-406c-b413-493c754875be" xlink:href="hsy-20240929.xsd#hsy_OtherNonoperatingGainLoss"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherNonoperatingIncomeExpense_344e0e57-57e9-4bdb-a2f7-aa02c59bbf84" xlink:to="loc_hsy_OtherNonoperatingGainLoss_565a2f07-9d3d-406c-b413-493c754875be" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.hersheys.com/role/SUPPLEMENTALBALANCESHEETINFORMATIONSCHEDULEOFSUPPLEMENTALBALANCESHEETINFORMATIONDetails" xlink:type="simple" xlink:href="hsy-20240929.xsd#SUPPLEMENTALBALANCESHEETINFORMATIONSCHEDULEOFSUPPLEMENTALBALANCESHEETINFORMATIONDetails"/>
  <link:calculationLink xlink:role="http://www.hersheys.com/role/SUPPLEMENTALBALANCESHEETINFORMATIONSCHEDULEOFSUPPLEMENTALBALANCESHEETINFORMATIONDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_ad9bee12-bf5d-448c-8caa-f29d9343a8e1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentNetOfTax_5eff9f74-5037-4e26-9d11-74fbdc61b8ce" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentNetOfTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_ad9bee12-bf5d-448c-8caa-f29d9343a8e1" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossForeignCurrencyTranslationAdjustmentNetOfTax_5eff9f74-5037-4e26-9d11-74fbdc61b8ce" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_26ff0899-ed37-4528-a13b-cd9957e0966b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_ad9bee12-bf5d-448c-8caa-f29d9343a8e1" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_26ff0899-ed37-4528-a13b-cd9957e0966b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AociLossCashFlowHedgeCumulativeGainLossAfterTax_808f7ee6-21b7-46d0-b8b5-f416b9cc4775" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AociLossCashFlowHedgeCumulativeGainLossAfterTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_ad9bee12-bf5d-448c-8caa-f29d9343a8e1" xlink:to="loc_us-gaap_AociLossCashFlowHedgeCumulativeGainLossAfterTax_808f7ee6-21b7-46d0-b8b5-f416b9cc4775" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_f4988218-97d3-437b-9799-d5f4894c315e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherLiabilitiesNoncurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherPostretirementDefinedBenefitPlanLiabilitiesNoncurrent_428352ab-aa60-49c3-adf6-b2cbbaf35e79" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherPostretirementDefinedBenefitPlanLiabilitiesNoncurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherLiabilitiesNoncurrent_f4988218-97d3-437b-9799-d5f4894c315e" xlink:to="loc_us-gaap_OtherPostretirementDefinedBenefitPlanLiabilitiesNoncurrent_428352ab-aa60-49c3-adf6-b2cbbaf35e79" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPensionPlanLiabilitiesNoncurrent_7c47a7db-02ff-4295-b149-72fabe2abe4c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPensionPlanLiabilitiesNoncurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherLiabilitiesNoncurrent_f4988218-97d3-437b-9799-d5f4894c315e" xlink:to="loc_us-gaap_DefinedBenefitPensionPlanLiabilitiesNoncurrent_7c47a7db-02ff-4295-b149-72fabe2abe4c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_969f80a3-714d-4d12-b64a-01441d1b12ba" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseLiabilityNoncurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherLiabilitiesNoncurrent_f4988218-97d3-437b-9799-d5f4894c315e" xlink:to="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_969f80a3-714d-4d12-b64a-01441d1b12ba" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_OtherMiscellaneousLiabilitiesNonCurrent_6f7882ec-691a-4045-b7bf-90632f7936fd" xlink:href="hsy-20240929.xsd#hsy_OtherMiscellaneousLiabilitiesNonCurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherLiabilitiesNoncurrent_f4988218-97d3-437b-9799-d5f4894c315e" xlink:to="loc_hsy_OtherMiscellaneousLiabilitiesNonCurrent_6f7882ec-691a-4045-b7bf-90632f7936fd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_abadfb03-86d9-45b4-8686-109654774531" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccruedLiabilitiesCurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EmployeeRelatedLiabilitiesCurrent_8be7d6aa-e048-4b16-82e7-148f9ce66d60" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_EmployeeRelatedLiabilitiesCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_abadfb03-86d9-45b4-8686-109654774531" xlink:to="loc_us-gaap_EmployeeRelatedLiabilitiesCurrent_8be7d6aa-e048-4b16-82e7-148f9ce66d60" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedMarketingCostsCurrent_7710ff12-6a5c-4b9f-997c-5f0fa5e9d851" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccruedMarketingCostsCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_abadfb03-86d9-45b4-8686-109654774531" xlink:to="loc_us-gaap_AccruedMarketingCostsCurrent_7710ff12-6a5c-4b9f-997c-5f0fa5e9d851" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityCurrent_766f755e-22e1-4b6c-b895-cc145a643cba" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseLiabilityCurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_abadfb03-86d9-45b4-8686-109654774531" xlink:to="loc_us-gaap_OperatingLeaseLiabilityCurrent_766f755e-22e1-4b6c-b895-cc145a643cba" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAccruedLiabilitiesCurrent_5ff51832-3c67-4471-b5a6-0abd8170e241" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherAccruedLiabilitiesCurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_abadfb03-86d9-45b4-8686-109654774531" xlink:to="loc_us-gaap_OtherAccruedLiabilitiesCurrent_5ff51832-3c67-4471-b5a6-0abd8170e241" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_a1591ede-a323-4b84-9937-f54a18422767" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PropertyPlantAndEquipmentNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentGross_3244b74b-3756-4af6-aaf2-0acfb9528554" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PropertyPlantAndEquipmentGross"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentNet_a1591ede-a323-4b84-9937-f54a18422767" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentGross_3244b74b-3756-4af6-aaf2-0acfb9528554" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment_2405cfff-f8f3-4510-bbfb-4d73ba0c392f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentNet_a1591ede-a323-4b84-9937-f54a18422767" xlink:to="loc_us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment_2405cfff-f8f3-4510-bbfb-4d73ba0c392f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryNet_914605d0-63dc-40e4-9cee-9c60204f0407" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InventoryNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FIFOInventoryAmount_d07515c6-6163-491b-a2fc-e068e352f6eb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FIFOInventoryAmount"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InventoryNet_914605d0-63dc-40e4-9cee-9c60204f0407" xlink:to="loc_us-gaap_FIFOInventoryAmount_d07515c6-6163-491b-a2fc-e068e352f6eb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryLIFOReserve_1f98bafc-91cb-499a-8862-32493bbe99a0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InventoryLIFOReserve"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InventoryNet_914605d0-63dc-40e4-9cee-9c60204f0407" xlink:to="loc_us-gaap_InventoryLIFOReserve_1f98bafc-91cb-499a-8862-32493bbe99a0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_PrepaidExpensesandOther_68feed53-c0d5-44f9-96b4-f4ed4d98ba9a" xlink:href="hsy-20240929.xsd#hsy_PrepaidExpensesandOther"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PrepaidExpenseCurrentAndNoncurrent_333022b3-5814-48d7-b610-6a7cc42399b4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PrepaidExpenseCurrentAndNoncurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_PrepaidExpensesandOther_68feed53-c0d5-44f9-96b4-f4ed4d98ba9a" xlink:to="loc_us-gaap_PrepaidExpenseCurrentAndNoncurrent_333022b3-5814-48d7-b610-6a7cc42399b4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssetsCurrent_53630982-cc8f-4a66-b929-49613d817e53" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherAssetsCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_hsy_PrepaidExpensesandOther_68feed53-c0d5-44f9-96b4-f4ed4d98ba9a" xlink:to="loc_us-gaap_OtherAssetsCurrent_53630982-cc8f-4a66-b929-49613d817e53" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FIFOInventoryAmount_c26327d5-50fc-4b57-b621-a2d13151adae" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FIFOInventoryAmount"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryRawMaterialsNetOfReserves_076bb7b4-6ea1-4a0e-8534-1a59b33e9e81" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InventoryRawMaterialsNetOfReserves"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FIFOInventoryAmount_c26327d5-50fc-4b57-b621-a2d13151adae" xlink:to="loc_us-gaap_InventoryRawMaterialsNetOfReserves_076bb7b4-6ea1-4a0e-8534-1a59b33e9e81" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryWorkInProcessNetOfReserves_130791ac-b79d-4415-84f4-09ed21b96559" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InventoryWorkInProcessNetOfReserves"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FIFOInventoryAmount_c26327d5-50fc-4b57-b621-a2d13151adae" xlink:to="loc_us-gaap_InventoryWorkInProcessNetOfReserves_130791ac-b79d-4415-84f4-09ed21b96559" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryFinishedGoodsNetOfReserves_cef42bae-4471-4dff-9653-b753ca86423d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InventoryFinishedGoodsNetOfReserves"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FIFOInventoryAmount_c26327d5-50fc-4b57-b621-a2d13151adae" xlink:to="loc_us-gaap_InventoryFinishedGoodsNetOfReserves_cef42bae-4471-4dff-9653-b753ca86423d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_93b25b40-2d92-4557-b004-6a2ec43abbfd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherAssetsNoncurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_hsy_OtherMiscellaneousAssetsNonCurrent_a8e2a6f8-6a4f-4963-91c1-b19cb2dec85b" xlink:href="hsy-20240929.xsd#hsy_OtherMiscellaneousAssetsNonCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherAssetsNoncurrent_93b25b40-2d92-4557-b004-6a2ec43abbfd" xlink:to="loc_hsy_OtherMiscellaneousAssetsNonCurrent_a8e2a6f8-6a4f-4963-91c1-b19cb2dec85b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_b6d77877-79c9-4452-b1b1-91d850d3a1f8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherAssetsNoncurrent_93b25b40-2d92-4557-b004-6a2ec43abbfd" xlink:to="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_b6d77877-79c9-4452-b1b1-91d850d3a1f8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_5bb82c0a-4c06-46fd-b9ad-c8243cbc3240" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OperatingLeaseRightOfUseAsset"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherAssetsNoncurrent_93b25b40-2d92-4557-b004-6a2ec43abbfd" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_5bb82c0a-4c06-46fd-b9ad-c8243cbc3240" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InvestmentsInAffiliatesSubsidiariesAssociatesAndJointVenturesFairValueDisclosure_122b26c0-381f-4ae2-8671-3efb3245a186" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InvestmentsInAffiliatesSubsidiariesAssociatesAndJointVenturesFairValueDisclosure"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherAssetsNoncurrent_93b25b40-2d92-4557-b004-6a2ec43abbfd" xlink:to="loc_us-gaap_InvestmentsInAffiliatesSubsidiariesAssociatesAndJointVenturesFairValueDisclosure_122b26c0-381f-4ae2-8671-3efb3245a186" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareNet_76c9c15a-bfba-4aaa-9a68-e555858bbc38" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CapitalizedComputerSoftwareNet"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OtherAssetsNoncurrent_93b25b40-2d92-4557-b004-6a2ec43abbfd" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareNet_76c9c15a-bfba-4aaa-9a68-e555858bbc38" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentGross_1325abfe-40d6-440a-9442-a690f4f83125" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PropertyPlantAndEquipmentGross"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Land_6c051422-299d-4739-a06c-4b8daad53ae9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Land"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentGross_1325abfe-40d6-440a-9442-a690f4f83125" xlink:to="loc_us-gaap_Land_6c051422-299d-4739-a06c-4b8daad53ae9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_BuildingsAndImprovementsGross_932d5691-54d6-4db6-bd0d-f80601339299" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_BuildingsAndImprovementsGross"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentGross_1325abfe-40d6-440a-9442-a690f4f83125" xlink:to="loc_us-gaap_BuildingsAndImprovementsGross_932d5691-54d6-4db6-bd0d-f80601339299" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MachineryAndEquipmentGross_06bea762-5052-485b-90ce-aeb00d6af1c6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MachineryAndEquipmentGross"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentGross_1325abfe-40d6-440a-9442-a690f4f83125" xlink:to="loc_us-gaap_MachineryAndEquipmentGross_06bea762-5052-485b-90ce-aeb00d6af1c6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ConstructionInProgressGross_da061a51-acb3-41ba-a93e-0252fa6a41de" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ConstructionInProgressGross"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentGross_1325abfe-40d6-440a-9442-a690f4f83125" xlink:to="loc_us-gaap_ConstructionInProgressGross_da061a51-acb3-41ba-a93e-0252fa6a41de" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableCurrent_3ba97f6c-bdb6-4907-8f7b-af5125d25781" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccountsPayableCurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableTradeCurrent_d29b1114-2da1-4853-a534-0e4b3cf9d31e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccountsPayableTradeCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccountsPayableCurrent_3ba97f6c-bdb6-4907-8f7b-af5125d25781" xlink:to="loc_us-gaap_AccountsPayableTradeCurrent_d29b1114-2da1-4853-a534-0e4b3cf9d31e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SupplierFinanceProgramObligationCurrent_b456d8c1-0e75-472a-aef6-a38153ebb27d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SupplierFinanceProgramObligationCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccountsPayableCurrent_3ba97f6c-bdb6-4907-8f7b-af5125d25781" xlink:to="loc_us-gaap_SupplierFinanceProgramObligationCurrent_b456d8c1-0e75-472a-aef6-a38153ebb27d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableOtherCurrent_143e1d72-b3d9-4468-9511-a50c64bbd9af" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccountsPayableOtherCurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccountsPayableCurrent_3ba97f6c-bdb6-4907-8f7b-af5125d25781" xlink:to="loc_us-gaap_AccountsPayableOtherCurrent_143e1d72-b3d9-4468-9511-a50c64bbd9af" xlink:type="arc"/>
  </link:calculationLink>
</link:linkbase>
