<XBRL>
<?xml version="1.0" encoding="US-ASCII"?>
<!--XBRL Document Created with Wdesk from Workiva-->
<!-- -->
<link:linkbase xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd" xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xbrldt="http://xbrl.org/2005/xbrldt" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <link:roleRef roleURI="http://www.hersheys.com/role/AssetsHeldForSale" xlink:href="hsy-20191231.xsd#AssetsHeldForSale" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/AssetsHeldForSaleDetails" xlink:href="hsy-20191231.xsd#AssetsHeldForSaleDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/AssetsHeldForSaleTables" xlink:href="hsy-20191231.xsd#AssetsHeldForSaleTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitions" xlink:href="hsy-20191231.xsd#BusinessAcquisitions" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAmplifySnackBrandsIncAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsAmplifySnackBrandsIncAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAmplifySnackBrandsIncNarrativeDetails" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsAmplifySnackBrandsIncNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsOneBrandsLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsOneBrandsLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsOneBrandsLlcNarrativeDetails" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsOneBrandsLlcNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsPirateBrandsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsPirateBrandsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsPirateBrandsNarrativeDetails" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsPirateBrandsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsTables" xlink:href="hsy-20191231.xsd#BusinessAcquisitionsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivities" xlink:href="hsy-20191231.xsd#BusinessRealignmentActivities" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:href="hsy-20191231.xsd#BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:href="hsy-20191231.xsd#BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:href="hsy-20191231.xsd#BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesTables" xlink:href="hsy-20191231.xsd#BusinessRealignmentActivitiesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingencies" xlink:href="hsy-20191231.xsd#CommitmentsAndContingencies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:href="hsy-20191231.xsd#CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:href="hsy-20191231.xsd#CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesTables" xlink:href="hsy-20191231.xsd#CommitmentsAndContingenciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedBalanceSheets" xlink:href="hsy-20191231.xsd#ConsolidatedBalanceSheets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedBalanceSheetsParenthetical" xlink:href="hsy-20191231.xsd#ConsolidatedBalanceSheetsParenthetical" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfCashFlows" xlink:href="hsy-20191231.xsd#ConsolidatedStatementsOfCashFlows" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfComprehensiveIncome" xlink:href="hsy-20191231.xsd#ConsolidatedStatementsOfComprehensiveIncome" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfIncome" xlink:href="hsy-20191231.xsd#ConsolidatedStatementsOfIncome" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquity" xlink:href="hsy-20191231.xsd#ConsolidatedStatementsOfStockholdersEquity" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:href="hsy-20191231.xsd#ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstruments" xlink:href="hsy-20191231.xsd#DerivativeInstruments" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsNarrativeDetails" xlink:href="hsy-20191231.xsd#DerivativeInstrumentsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:href="hsy-20191231.xsd#DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfCumulativeBasisAdjustmentsForInterestRateSwapDerivativesDetails" xlink:href="hsy-20191231.xsd#DerivativeInstrumentsScheduleOfCumulativeBasisAdjustmentsForInterestRateSwapDerivativesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:href="hsy-20191231.xsd#DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsTables" xlink:href="hsy-20191231.xsd#DerivativeInstrumentsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DocumentAndEntityInformationDocument" xlink:href="hsy-20191231.xsd#DocumentAndEntityInformationDocument" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShare" xlink:href="hsy-20191231.xsd#EarningsPerShare" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareEarningsPerShareNarrativeDetails" xlink:href="hsy-20191231.xsd#EarningsPerShareEarningsPerShareNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:href="hsy-20191231.xsd#EarningsPerShareScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareTables" xlink:href="hsy-20191231.xsd#EarningsPerShareTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterest" xlink:href="hsy-20191231.xsd#EquityAndNoncontrollingInterest" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:href="hsy-20191231.xsd#EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:href="hsy-20191231.xsd#EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:href="hsy-20191231.xsd#EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestTables" xlink:href="hsy-20191231.xsd#EquityAndNoncontrollingInterestTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurements" xlink:href="hsy-20191231.xsd#FairValueMeasurementsFairValueMeasurements" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:href="hsy-20191231.xsd#FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsTables" xlink:href="hsy-20191231.xsd#FairValueMeasurementsFairValueMeasurementsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:href="hsy-20191231.xsd#FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:href="hsy-20191231.xsd#FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfImpairmentChargesDetails" xlink:href="hsy-20191231.xsd#FairValueMeasurementsScheduleOfImpairmentChargesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssets" xlink:href="hsy-20191231.xsd#GoodwillAndIntangibleAssets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:href="hsy-20191231.xsd#GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:href="hsy-20191231.xsd#GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:href="hsy-20191231.xsd#GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:href="hsy-20191231.xsd#GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsTables" xlink:href="hsy-20191231.xsd#GoodwillAndIntangibleAssetsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxes" xlink:href="hsy-20191231.xsd#IncomeTaxes" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesIncomeTaxesNarrativeDetails" xlink:href="hsy-20191231.xsd#IncomeTaxesIncomeTaxesNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:href="hsy-20191231.xsd#IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:href="hsy-20191231.xsd#IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:href="hsy-20191231.xsd#IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:href="hsy-20191231.xsd#IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:href="hsy-20191231.xsd#IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesTables" xlink:href="hsy-20191231.xsd#IncomeTaxesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/Leases" xlink:href="hsy-20191231.xsd#Leases" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesScheduleOfComponenetsOfLeaseExpenseDetails" xlink:href="hsy-20191231.xsd#LeasesScheduleOfComponenetsOfLeaseExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesScheduleOfInformationRegardingOurLeaseTermsAndDiscountRatesDetails" xlink:href="hsy-20191231.xsd#LeasesScheduleOfInformationRegardingOurLeaseTermsAndDiscountRatesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesScheduleOfMaturitiesOfLeaseLiabilitiesDetails" xlink:href="hsy-20191231.xsd#LeasesScheduleOfMaturitiesOfLeaseLiabilitiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:href="hsy-20191231.xsd#LeasesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesScheduleOfSupplementalCashFlowInformationRelatedToLeasesDetails" xlink:href="hsy-20191231.xsd#LeasesScheduleOfSupplementalCashFlowInformationRelatedToLeasesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesSupplementalBalanceSheetInformationRelatedToLeasesDetails" xlink:href="hsy-20191231.xsd#LeasesSupplementalBalanceSheetInformationRelatedToLeasesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/LeasesTables" xlink:href="hsy-20191231.xsd#LeasesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:href="hsy-20191231.xsd#OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:href="hsy-20191231.xsd#OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:href="hsy-20191231.xsd#OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlans" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlans" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansTables" xlink:href="hsy-20191231.xsd#PensionAndOtherPostRetirementBenefitPlansTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataTables" xlink:href="hsy-20191231.xsd#QuarterlyDataTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataUnaudited" xlink:href="hsy-20191231.xsd#QuarterlyDataUnaudited" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataUnauditedScheduleOfQuarterlyFinancialInformationDetails" xlink:href="hsy-20191231.xsd#QuarterlyDataUnauditedScheduleOfQuarterlyFinancialInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccounts" xlink:href="hsy-20191231.xsd#ScheduleIiValuationAndQualifyingAccounts" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsDetails" xlink:href="hsy-20191231.xsd#ScheduleIiValuationAndQualifyingAccountsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformation" xlink:href="hsy-20191231.xsd#SegmentInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationNarrativeDetails" xlink:href="hsy-20191231.xsd#SegmentInformationNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfAdditionalProductLineSalesDetails" xlink:href="hsy-20191231.xsd#SegmentInformationScheduleOfAdditionalProductLineSalesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:href="hsy-20191231.xsd#SegmentInformationScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:href="hsy-20191231.xsd#SegmentInformationScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfSegmentInformationByGeographyDetails" xlink:href="hsy-20191231.xsd#SegmentInformationScheduleOfSegmentInformationByGeographyDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:href="hsy-20191231.xsd#SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationTables" xlink:href="hsy-20191231.xsd#SegmentInformationTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebt" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebt" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtTables" xlink:href="hsy-20191231.xsd#ShortAndLongTermDebtTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlans" xlink:href="hsy-20191231.xsd#StockCompensationPlans" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:href="hsy-20191231.xsd#StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansTables" xlink:href="hsy-20191231.xsd#StockCompensationPlansTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPolicies" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:href="hsy-20191231.xsd#SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformation" xlink:href="hsy-20191231.xsd#SupplementalBalanceSheetInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformationScheduleOfSupplementalBalanceSheetInformationDetails" xlink:href="hsy-20191231.xsd#SupplementalBalanceSheetInformationScheduleOfSupplementalBalanceSheetInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformationTables" xlink:href="hsy-20191231.xsd#SupplementalBalanceSheetInformationTables" xlink:type="simple" />
  <link:arcroleRef arcroleURI="http://xbrl.org/int/dim/arcrole/all" xlink:href="http://www.xbrl.org/2005/xbrldt-2005.xsd#all" xlink:type="simple" />
  <link:arcroleRef arcroleURI="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:href="http://www.xbrl.org/2005/xbrldt-2005.xsd#dimension-default" xlink:type="simple" />
  <link:arcroleRef arcroleURI="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:href="http://www.xbrl.org/2005/xbrldt-2005.xsd#dimension-domain" xlink:type="simple" />
  <link:arcroleRef arcroleURI="http://xbrl.org/int/dim/arcrole/domain-member" xlink:href="http://www.xbrl.org/2005/xbrldt-2005.xsd#domain-member" xlink:type="simple" />
  <link:arcroleRef arcroleURI="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:href="http://www.xbrl.org/2005/xbrldt-2005.xsd#hypercube-dimension" xlink:type="simple" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/AssetsHeldForSale" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/AssetsHeldForSaleDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_916ABCE6E3EE42D9FD890C3B449365F0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_916ABCE6E3EE42D9FD890C3B449365F0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_37F5547D2F6370FC8A7D0C3B44949ABD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_916ABCE6E3EE42D9FD890C3B449365F0" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_37F5547D2F6370FC8A7D0C3B44949ABD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_37F5547D2F6370FC8A7D0C3B44949ABD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_916ABCE6E3EE42D9FD890C3B449365F0" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_37F5547D2F6370FC8A7D0C3B44949ABD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_406588327171CD2584290C3B4494D66E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_37F5547D2F6370FC8A7D0C3B44949ABD" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_406588327171CD2584290C3B4494D66E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A19522AFE31B8EE83BD20C3B449409FB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A19522AFE31B8EE83BD20C3B449409FB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_1114A36C689490ADD99C0C3B4494ACA6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A19522AFE31B8EE83BD20C3B449409FB" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_1114A36C689490ADD99C0C3B4494ACA6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_1114A36C689490ADD99C0C3B4494ACA6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A19522AFE31B8EE83BD20C3B449409FB" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_1114A36C689490ADD99C0C3B4494ACA6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LicensingAgreementsMember" xlink:label="loc_us-gaap_LicensingAgreementsMember_EEE70849D7A6152295680C3B4495CC26" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_1114A36C689490ADD99C0C3B4494ACA6" xlink:to="loc_us-gaap_LicensingAgreementsMember_EEE70849D7A6152295680C3B4495CC26" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_ABBB14DDFC544E8C92710C3B449525B6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_ABBB14DDFC544E8C92710C3B449525B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BF1CB81A8D5486E17B840C3B4495E2A2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_ABBB14DDFC544E8C92710C3B449525B6" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BF1CB81A8D5486E17B840C3B4495E2A2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BF1CB81A8D5486E17B840C3B4495E2A2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_ABBB14DDFC544E8C92710C3B449525B6" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BF1CB81A8D5486E17B840C3B4495E2A2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_TyrrellsandShanghaiGoldenMonkeySGMMember" xlink:label="loc_hsy_TyrrellsandShanghaiGoldenMonkeySGMMember_9F2DE33DBB2801DA6F5F0C3B4495B322" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BF1CB81A8D5486E17B840C3B4495E2A2" xlink:to="loc_hsy_TyrrellsandShanghaiGoldenMonkeySGMMember_9F2DE33DBB2801DA6F5F0C3B4495B322" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_894BBF91A68428F843280C3B44964BEC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_894BBF91A68428F843280C3B44964BEC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_9E18872FB14F7554DE510C3B4496B7B8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_894BBF91A68428F843280C3B44964BEC" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_9E18872FB14F7554DE510C3B4496B7B8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_9E18872FB14F7554DE510C3B4496B7B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_894BBF91A68428F843280C3B44964BEC" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_9E18872FB14F7554DE510C3B4496B7B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_2F8572E865A9DD236C590C3B449620BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_9E18872FB14F7554DE510C3B4496B7B8" xlink:to="loc_us-gaap_FacilityClosingMember_2F8572E865A9DD236C590C3B449620BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_4EC42C81FD9CFEC90CCA0C3B449603A0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3507F85446678D28F76E0C3B4493F214" xlink:to="loc_us-gaap_RestructuringPlanAxis_4EC42C81FD9CFEC90CCA0C3B449603A0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_F1BE4A7B4F229A45D4DC0C3B449707FC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_4EC42C81FD9CFEC90CCA0C3B449603A0" xlink:to="loc_us-gaap_RestructuringPlanDomain_F1BE4A7B4F229A45D4DC0C3B449707FC_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_F1BE4A7B4F229A45D4DC0C3B449707FC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_4EC42C81FD9CFEC90CCA0C3B449603A0" xlink:to="loc_us-gaap_RestructuringPlanDomain_F1BE4A7B4F229A45D4DC0C3B449707FC" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_A189F781CF1CB99FFE2B0C3B4497D92A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_F1BE4A7B4F229A45D4DC0C3B449707FC" xlink:to="loc_hsy_OperationalOptimizationProgramMember_A189F781CF1CB99FFE2B0C3B4497D92A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationPropertyPlantAndEquipment" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationPropertyPlantAndEquipment_E4771EAC5CF303A7CE7D0C3B44976A2E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationPropertyPlantAndEquipment_E4771EAC5CF303A7CE7D0C3B44976A2E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation" xlink:label="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_A3007AF1EBF291997CFA0C3B4498C3F7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_A3007AF1EBF291997CFA0C3B4498C3F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationAccountsPayableAndAccruedLiabilities" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationAccountsPayableAndAccruedLiabilities_7508FE0B8018637AA8140C3B44982060" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationAccountsPayableAndAccruedLiabilities_7508FE0B8018637AA8140C3B44982060" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation" xlink:label="loc_us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation_3F48FCE703BB1318E3490C3B44981E55" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation_3F48FCE703BB1318E3490C3B44981E55" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment" xlink:label="loc_us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment_A586E7ACB7E3CCB2DED40C3B4498C129" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment_A586E7ACB7E3CCB2DED40C3B4498C129" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GainLossOnSaleOfProperties" xlink:label="loc_us-gaap_GainLossOnSaleOfProperties_B81CE72615C3B30FEDC80C3B44984641" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_GainLossOnSaleOfProperties_B81CE72615C3B30FEDC80C3B44984641" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ProceedsFromSaleOfIntangibleAssets" xlink:label="loc_us-gaap_ProceedsFromSaleOfIntangibleAssets_87AC398D0A494FA708C00C3B44997939" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_ProceedsFromSaleOfIntangibleAssets_87AC398D0A494FA708C00C3B44997939" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GainLossOnDispositionOfIntangibleAssets" xlink:label="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_CA536C0B2A78433D2B9F0C3B44994912" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_CA536C0B2A78433D2B9F0C3B44994912" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GainLossOnSaleOfPropertyPlantEquipment" xlink:label="loc_us-gaap_GainLossOnSaleOfPropertyPlantEquipment_19C503552FDF9C9C24450C3B44992BD1" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_GainLossOnSaleOfPropertyPlantEquipment_19C503552FDF9C9C24450C3B44992BD1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ProceedsFromDivestitureOfBusinesses" xlink:label="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_B8207E88B4C1F920C33E0C3B4499F4DA" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_B8207E88B4C1F920C33E0C3B4499F4DA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_64C8FCA6A7340F2098F70C3B4499C2DD" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_73C94642FACA8E89E1B10C3B44971765" xlink:to="loc_us-gaap_AssetImpairmentCharges_64C8FCA6A7340F2098F70C3B4499C2DD" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/AssetsHeldForSaleTables" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_5BB46FAD0575F8E079CA0C3B44A0B069" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_CCF7769EABF733AC8A0A0C3B449E437F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_5BB46FAD0575F8E079CA0C3B44A0B069" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_CCF7769EABF733AC8A0A0C3B449E437F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_02ECF86880B9D21395960C3B449FB7BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_CCF7769EABF733AC8A0A0C3B449E437F" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_02ECF86880B9D21395960C3B449FB7BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1692BAC9D91A3DC645A20C3B449FD0AA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_02ECF86880B9D21395960C3B449FB7BC" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1692BAC9D91A3DC645A20C3B449FD0AA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1692BAC9D91A3DC645A20C3B449FD0AA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_02ECF86880B9D21395960C3B449FB7BC" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1692BAC9D91A3DC645A20C3B449FD0AA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupClassificationAxis" xlink:label="loc_us-gaap_DisposalGroupClassificationAxis_C76EF98A5629A9DF1A4B0C3B449F09D7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_CCF7769EABF733AC8A0A0C3B449E437F" xlink:to="loc_us-gaap_DisposalGroupClassificationAxis_C76EF98A5629A9DF1A4B0C3B449F09D7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_91AF11A4D3B5E6CC83830C3B44A00CF6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_C76EF98A5629A9DF1A4B0C3B449F09D7" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_91AF11A4D3B5E6CC83830C3B44A00CF6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_91AF11A4D3B5E6CC83830C3B44A00CF6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_C76EF98A5629A9DF1A4B0C3B449F09D7" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_91AF11A4D3B5E6CC83830C3B44A00CF6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_55D63FE41A4B0054E8840C3B44A0243C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_CCF7769EABF733AC8A0A0C3B449E437F" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_55D63FE41A4B0054E8840C3B44A0243C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_6E04599E6DE8BA3E0B160C3B44A09ECE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_55D63FE41A4B0054E8840C3B44A0243C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_6E04599E6DE8BA3E0B160C3B44A09ECE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_6E04599E6DE8BA3E0B160C3B44A09ECE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_55D63FE41A4B0054E8840C3B44A0243C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_6E04599E6DE8BA3E0B160C3B44A09ECE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDisposalGroupsIncludingDiscontinuedOperationsIncomeStatementBalanceSheetAndAdditionalDisclosuresTextBlock" xlink:label="loc_us-gaap_ScheduleOfDisposalGroupsIncludingDiscontinuedOperationsIncomeStatementBalanceSheetAndAdditionalDisclosuresTextBlock_A358DC1A6B52CC44566E0C3B44A0A88D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_5BB46FAD0575F8E079CA0C3B44A0B069" xlink:to="loc_us-gaap_ScheduleOfDisposalGroupsIncludingDiscontinuedOperationsIncomeStatementBalanceSheetAndAdditionalDisclosuresTextBlock_A358DC1A6B52CC44566E0C3B44A0A88D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitions" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAmplifySnackBrandsIncAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5FBF230A00B78A03448A0C49E117174E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5FBF230A00B78A03448A0C49E117174E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_563A43C3DBBAE2177D370C49E117B376" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5FBF230A00B78A03448A0C49E117174E" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_563A43C3DBBAE2177D370C49E117B376" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8F8DC861CAF52E748A9E0C49E1171559_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_563A43C3DBBAE2177D370C49E117B376" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8F8DC861CAF52E748A9E0C49E1171559_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8F8DC861CAF52E748A9E0C49E1171559" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_563A43C3DBBAE2177D370C49E117B376" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8F8DC861CAF52E748A9E0C49E1171559" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_BCFAA7E375A05B98AB7B0C49E1187BC1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8F8DC861CAF52E748A9E0C49E1171559" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_BCFAA7E375A05B98AB7B0C49E1187BC1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_344B1DB3757481BA9FBE0C49E11AA041" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_344B1DB3757481BA9FBE0C49E11AA041" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssets" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssets_A7C9B298EEE5170E90B80C49E11A5725" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssets_A7C9B298EEE5170E90B80C49E11A5725" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_501A81AB0ED19EE547580C49E11AD274" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_501A81AB0ED19EE547580C49E11AD274" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_D8F24AD01171189BE2BA0C49E11B528E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_D8F24AD01171189BE2BA0C49E11B528E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_E3F7A0D1D0492C45C5320C49E11BE7A2" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_Goodwill_E3F7A0D1D0492C45C5320C49E11BE7A2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_C8F24328773738B366C30C49E11B8183" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_C8F24328773738B366C30C49E11B8183" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentAssets" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentAssets_EAFDDE5FCFD57F5327340C49E11B993C" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentAssets_EAFDDE5FCFD57F5327340C49E11B993C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesAccountsPayable" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesAccountsPayable_C84AB4522F0A3635D1360C49E11B5C12" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesAccountsPayable_C84AB4522F0A3635D1360C49E11B5C12" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities" xlink:label="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_39F4A0DAFC50AC7240F30C49E11B8029" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_39F4A0DAFC50AC7240F30C49E11B8029" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesDebt" xlink:label="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesDebt_A6AE309BD30CD7524BE90C49E11CFD34" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesDebt_A6AE309BD30CD7524BE90C49E11CFD34" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther_A8048D9BD47FA45175200C49E11CE4A8" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther_A8048D9BD47FA45175200C49E11CE4A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilities" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilities_E571401D93A2B44821210C49E11C35B1" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilities_E571401D93A2B44821210C49E11C35B1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilities" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilities_4413E16711C22897B0620C49E11C1DF8" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilities_4413E16711C22897B0620C49E11C1DF8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_FCB0D206F1A19FFCBF4C0C49E11DD45D" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_FD44A9C5B1C80342ED030C49E11A7316" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_FCB0D206F1A19FFCBF4C0C49E11DD45D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAmplifySnackBrandsIncNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_25DCC9DB1B0C48F78E63AD8A58BA50C5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:to="loc_srt_RangeAxis_25DCC9DB1B0C48F78E63AD8A58BA50C5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_74431DB3838E8F5BB85DAD8A58BBD509_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_25DCC9DB1B0C48F78E63AD8A58BA50C5" xlink:to="loc_srt_RangeMember_74431DB3838E8F5BB85DAD8A58BBD509_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_74431DB3838E8F5BB85DAD8A58BBD509" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_25DCC9DB1B0C48F78E63AD8A58BA50C5" xlink:to="loc_srt_RangeMember_74431DB3838E8F5BB85DAD8A58BBD509" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_64533826679549C351FDAD8A58BCB5E2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_74431DB3838E8F5BB85DAD8A58BBD509" xlink:to="loc_srt_MinimumMember_64533826679549C351FDAD8A58BCB5E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_643D77699CA27E7BE578AD8A58BCB36B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_74431DB3838E8F5BB85DAD8A58BBD509" xlink:to="loc_srt_MaximumMember_643D77699CA27E7BE578AD8A58BCB36B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_708F53047C4C5C36D313AD8A58BCEB7E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_708F53047C4C5C36D313AD8A58BCEB7E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_DF9D8A5665CC2E406D65AD8A58BD4831_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_708F53047C4C5C36D313AD8A58BCEB7E" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_DF9D8A5665CC2E406D65AD8A58BD4831_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_DF9D8A5665CC2E406D65AD8A58BD4831" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_708F53047C4C5C36D313AD8A58BCEB7E" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_DF9D8A5665CC2E406D65AD8A58BD4831" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_A8E243D3BF8893DFA4F0AD8A58BD08DD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_DF9D8A5665CC2E406D65AD8A58BD4831" xlink:to="loc_us-gaap_TrademarksMember_A8E243D3BF8893DFA4F0AD8A58BD08DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_DFAD7F68DE79DDD4C5B3AD8A58BD7ED0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_DF9D8A5665CC2E406D65AD8A58BD4831" xlink:to="loc_us-gaap_CustomerRelationshipsMember_DFAD7F68DE79DDD4C5B3AD8A58BD7ED0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_57F44C34EDAC0A88F1DFAD8A58BEFF4E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_57F44C34EDAC0A88F1DFAD8A58BEFF4E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_473C832AF5DE32A2EFFFAD8A58BFD006_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_57F44C34EDAC0A88F1DFAD8A58BEFF4E" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_473C832AF5DE32A2EFFFAD8A58BFD006_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_473C832AF5DE32A2EFFFAD8A58BFD006" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_57F44C34EDAC0A88F1DFAD8A58BEFF4E" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_473C832AF5DE32A2EFFFAD8A58BFD006" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_1C7922551014BD79B652AD8A58BFD6B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_473C832AF5DE32A2EFFFAD8A58BFD006" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_1C7922551014BD79B652AD8A58BFD6B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_342F7235855C0D776EA3AD8A58C0FD48" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_342F7235855C0D776EA3AD8A58C0FD48" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_0AE67E7B27197ED21B21AD8A58C0D1C7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_342F7235855C0D776EA3AD8A58C0FD48" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_0AE67E7B27197ED21B21AD8A58C0D1C7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_0AE67E7B27197ED21B21AD8A58C0D1C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_342F7235855C0D776EA3AD8A58C0FD48" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_0AE67E7B27197ED21B21AD8A58C0D1C7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_E6D77BDB272C1058E88EAD8A58C1E0B4" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:to="loc_srt_OwnershipAxis_E6D77BDB272C1058E88EAD8A58C1E0B4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_AF26D437D569B55938CDAD8A58C18CF8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_E6D77BDB272C1058E88EAD8A58C1E0B4" xlink:to="loc_srt_OwnershipDomain_AF26D437D569B55938CDAD8A58C18CF8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_AF26D437D569B55938CDAD8A58C18CF8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_E6D77BDB272C1058E88EAD8A58C1E0B4" xlink:to="loc_srt_OwnershipDomain_AF26D437D569B55938CDAD8A58C18CF8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_03FCC50430F7AE0FD652AD8A58C168AE" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_87DE5A556503358C606DAD8A58BAADEA" xlink:to="loc_us-gaap_StatementClassOfStockAxis_03FCC50430F7AE0FD652AD8A58C168AE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_B168C5405246AE987353AD8A58C1F009_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_03FCC50430F7AE0FD652AD8A58C168AE" xlink:to="loc_us-gaap_ClassOfStockDomain_B168C5405246AE987353AD8A58C1F009_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_B168C5405246AE987353AD8A58C1F009" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_03FCC50430F7AE0FD652AD8A58C168AE" xlink:to="loc_us-gaap_ClassOfStockDomain_B168C5405246AE987353AD8A58C1F009" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationConsiderationTransferred1" xlink:label="loc_us-gaap_BusinessCombinationConsiderationTransferred1_D078139074485FF80617AD8A58C29695" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_BusinessCombinationConsiderationTransferred1_D078139074485FF80617AD8A58C29695" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionSharePrice" xlink:label="loc_us-gaap_BusinessAcquisitionSharePrice_23DBCAA01475E26E8B04AD8A58C34220" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_BusinessAcquisitionSharePrice_23DBCAA01475E26E8B04AD8A58C34220" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessAcquisitionEquityInterestsReceivedCommonStockValue" xlink:label="loc_hsy_BusinessAcquisitionEquityInterestsReceivedCommonStockValue_3A9AD582B0EAF588DF0DAD8A58C3CE49" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_hsy_BusinessAcquisitionEquityInterestsReceivedCommonStockValue_3A9AD582B0EAF588DF0DAD8A58C3CE49" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedTrademarksGross" xlink:label="loc_us-gaap_FiniteLivedTrademarksGross_EF3452BA949B53B25110AD8A58C303C7" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_FiniteLivedTrademarksGross_EF3452BA949B53B25110AD8A58C303C7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedCustomerRelationshipsGross" xlink:label="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_8A062663EFCA31DCB068AD8A58C48EA3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_8A062663EFCA31DCB068AD8A58C48EA3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_C3E5742032950BA3E557AD8A58C47352" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_C3E5742032950BA3E557AD8A58C47352" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationAcquisitionRelatedCosts" xlink:label="loc_us-gaap_BusinessCombinationAcquisitionRelatedCosts_D7678A8901D97A2D798AAD8A58C4E24A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_CFA248FD7D4DFBDD9098AD8A58C247ED" xlink:to="loc_us-gaap_BusinessCombinationAcquisitionRelatedCosts_D7678A8901D97A2D798AAD8A58C4E24A" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsOneBrandsLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_0D39A953F91AEE069BA60C5298E55AB2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_0D39A953F91AEE069BA60C5298E55AB2" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_262748BEBF126000D9F40C5298E5D518" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_0D39A953F91AEE069BA60C5298E55AB2" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_262748BEBF126000D9F40C5298E5D518" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_269F232844175D6EA77B0C5298E61EA0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_262748BEBF126000D9F40C5298E5D518" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_269F232844175D6EA77B0C5298E61EA0_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_269F232844175D6EA77B0C5298E61EA0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_262748BEBF126000D9F40C5298E5D518" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_269F232844175D6EA77B0C5298E61EA0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ONEBrandsLLCMember" xlink:label="loc_hsy_ONEBrandsLLCMember_5FCF189D61FCBE58EA3C0C5298E612EF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_269F232844175D6EA77B0C5298E61EA0" xlink:to="loc_hsy_ONEBrandsLLCMember_5FCF189D61FCBE58EA3C0C5298E612EF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_5BBD420584FACA0174710C5298E6F73A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_0D39A953F91AEE069BA60C5298E55AB2" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_5BBD420584FACA0174710C5298E6F73A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_43D97CC3D33DCF4FA2EF0C5298E6D27C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_5BBD420584FACA0174710C5298E6F73A" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_43D97CC3D33DCF4FA2EF0C5298E6D27C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_43D97CC3D33DCF4FA2EF0C5298E6D27C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_5BBD420584FACA0174710C5298E6F73A" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_43D97CC3D33DCF4FA2EF0C5298E6D27C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_F63AE808103309CA3FA20C5298E7B9EC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_0D39A953F91AEE069BA60C5298E55AB2" xlink:to="loc_srt_OwnershipAxis_F63AE808103309CA3FA20C5298E7B9EC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_D1538EE91049D11B1DF30C5298E7335C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_F63AE808103309CA3FA20C5298E7B9EC" xlink:to="loc_srt_OwnershipDomain_D1538EE91049D11B1DF30C5298E7335C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_D1538EE91049D11B1DF30C5298E7335C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_F63AE808103309CA3FA20C5298E7B9EC" xlink:to="loc_srt_OwnershipDomain_D1538EE91049D11B1DF30C5298E7335C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_F39A83462CEB9F71D4D60C5298E76C2B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_0D39A953F91AEE069BA60C5298E55AB2" xlink:to="loc_us-gaap_StatementClassOfStockAxis_F39A83462CEB9F71D4D60C5298E76C2B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_E6484AB38E48B1505EF00C5298E75831_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_F39A83462CEB9F71D4D60C5298E76C2B" xlink:to="loc_us-gaap_ClassOfStockDomain_E6484AB38E48B1505EF00C5298E75831_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_E6484AB38E48B1505EF00C5298E75831" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_F39A83462CEB9F71D4D60C5298E76C2B" xlink:to="loc_us-gaap_ClassOfStockDomain_E6484AB38E48B1505EF00C5298E75831" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_8FB5D4D133CD5C16143F0C5298E86955" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_Goodwill_8FB5D4D133CD5C16143F0C5298E86955" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillPurchaseAccountingAdjustments" xlink:label="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_812BC98A8F994A052D440C5298E88E52" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_812BC98A8F994A052D440C5298E88E52" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_D91906596B6DB5B5474D0C5298E81C76" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_D91906596B6DB5B5474D0C5298E81C76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsPurchaseAccountingAdjustments" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsPurchaseAccountingAdjustments_8FE48AD4EDC2C44B32470C5298E81AD2" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsPurchaseAccountingAdjustments_8FE48AD4EDC2C44B32470C5298E81AD2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_0CFB201EA56580E0F0280C5298E85DD3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_0CFB201EA56580E0F0280C5298E85DD3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteCurrentAssetsOther" xlink:label="loc_hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteCurrentAssetsOther_7B0B5D7C97CEBEF87CA70C5298E9EBD9" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteCurrentAssetsOther_7B0B5D7C97CEBEF87CA70C5298E9EBD9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther_D4924F838727D57931050C5298E91D26" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther_D4924F838727D57931050C5298E91D26" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteCurrentLiabilitiesOther" xlink:label="loc_hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteCurrentLiabilitiesOther_330C7956A2856CF0BA260C5298E94609" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteCurrentLiabilitiesOther_330C7956A2856CF0BA260C5298E94609" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_7F43848817782827F21A0C5298E9BB48" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_7F43848817782827F21A0C5298E9BB48" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteAdjustmentNet" xlink:label="loc_hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteAdjustmentNet_E54ACBBA88613C740B2E0C5298E9D98D" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_89D373DBC1B9D8C041130C5298E88C83" xlink:to="loc_hsy_BusinessCombinationProvisionalInformationInitialAccountingIncompleteAdjustmentNet_E54ACBBA88613C740B2E0C5298E9D98D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsOneBrandsLlcNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_8A2864181B5E18CEA773CEDF5CDF7489" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:to="loc_srt_RangeAxis_8A2864181B5E18CEA773CEDF5CDF7489" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_12B744D66C04DE293835CEDF5CDFB093_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_8A2864181B5E18CEA773CEDF5CDF7489" xlink:to="loc_srt_RangeMember_12B744D66C04DE293835CEDF5CDFB093_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_12B744D66C04DE293835CEDF5CDFB093" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_8A2864181B5E18CEA773CEDF5CDF7489" xlink:to="loc_srt_RangeMember_12B744D66C04DE293835CEDF5CDFB093" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_AE033B93618B58B3EFFBCEDF5CE0EED1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_12B744D66C04DE293835CEDF5CDFB093" xlink:to="loc_srt_MinimumMember_AE033B93618B58B3EFFBCEDF5CE0EED1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_5F6B16EF57A9D2D3F681CEDF5CE048B8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_12B744D66C04DE293835CEDF5CDFB093" xlink:to="loc_srt_MaximumMember_5F6B16EF57A9D2D3F681CEDF5CE048B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9BADECEA1754DEF5A148CEDF5CE04228" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9BADECEA1754DEF5A148CEDF5CE04228" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9BADECEA1754DEF5A148CEDF5CE04228" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9BADECEA1754DEF5A148CEDF5CE04228" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_24075A7AC8F44C94B63DCEDF5CE06D5B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105" xlink:to="loc_us-gaap_TrademarksMember_24075A7AC8F44C94B63DCEDF5CE06D5B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_1CC01CBC93DAF27082DBCEDF5CE11008" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105" xlink:to="loc_us-gaap_CustomerRelationshipsMember_1CC01CBC93DAF27082DBCEDF5CE11008" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NoncompeteAgreementsMember" xlink:label="loc_us-gaap_NoncompeteAgreementsMember_19AA495F52FDC4B054F8CEDF5CE139B8" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_45D0CF13E126179A4FF1CEDF5CE08105" xlink:to="loc_us-gaap_NoncompeteAgreementsMember_19AA495F52FDC4B054F8CEDF5CE139B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_D9A1197DA9EE4F86401ECEDF5CE18911" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_D9A1197DA9EE4F86401ECEDF5CE18911" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_27677CD888729333F63ECEDF5CE1403E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_D9A1197DA9EE4F86401ECEDF5CE18911" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_27677CD888729333F63ECEDF5CE1403E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_27677CD888729333F63ECEDF5CE1403E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_D9A1197DA9EE4F86401ECEDF5CE18911" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_27677CD888729333F63ECEDF5CE1403E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ONEBrandsLLCMember" xlink:label="loc_hsy_ONEBrandsLLCMember_39465DC42FF58E1BB539CEDF5CE198C0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_27677CD888729333F63ECEDF5CE1403E" xlink:to="loc_hsy_ONEBrandsLLCMember_39465DC42FF58E1BB539CEDF5CE198C0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_304364A450AA624A39FBCEDF5CE2F199" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_304364A450AA624A39FBCEDF5CE2F199" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_2622757C3599E7E148F9CEDF5CE23DC6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_304364A450AA624A39FBCEDF5CE2F199" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_2622757C3599E7E148F9CEDF5CE23DC6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_2622757C3599E7E148F9CEDF5CE23DC6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_304364A450AA624A39FBCEDF5CE2F199" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_2622757C3599E7E148F9CEDF5CE23DC6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_413934598782EB3A61A5CEDF5CE29066" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:to="loc_srt_OwnershipAxis_413934598782EB3A61A5CEDF5CE29066" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_4ABBCAB5287AEDE7F967CEDF5CE2615E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_413934598782EB3A61A5CEDF5CE29066" xlink:to="loc_srt_OwnershipDomain_4ABBCAB5287AEDE7F967CEDF5CE2615E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_4ABBCAB5287AEDE7F967CEDF5CE2615E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_413934598782EB3A61A5CEDF5CE29066" xlink:to="loc_srt_OwnershipDomain_4ABBCAB5287AEDE7F967CEDF5CE2615E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_E6E11B459673822141BFCEDF5CE39898" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_EFB07AAE6AB13173FB5FCEDF5CDF2F6F" xlink:to="loc_us-gaap_StatementClassOfStockAxis_E6E11B459673822141BFCEDF5CE39898" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BD4285D3470CC35D8C84CEDF5CE3767F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_E6E11B459673822141BFCEDF5CE39898" xlink:to="loc_us-gaap_ClassOfStockDomain_BD4285D3470CC35D8C84CEDF5CE3767F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BD4285D3470CC35D8C84CEDF5CE3767F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_E6E11B459673822141BFCEDF5CE39898" xlink:to="loc_us-gaap_ClassOfStockDomain_BD4285D3470CC35D8C84CEDF5CE3767F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationConsiderationTransferred1" xlink:label="loc_us-gaap_BusinessCombinationConsiderationTransferred1_8127153A767EED173DDCCEDF5CE3615D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:to="loc_us-gaap_BusinessCombinationConsiderationTransferred1_8127153A767EED173DDCCEDF5CE3615D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedTrademarksGross" xlink:label="loc_us-gaap_FiniteLivedTrademarksGross_736F474E94CED482C6BCCEDF5CE3A6CF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:to="loc_us-gaap_FiniteLivedTrademarksGross_736F474E94CED482C6BCCEDF5CE3A6CF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedCustomerRelationshipsGross" xlink:label="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_9FBF248B38DAF97E5E33CEDF5CE4970B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:to="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_9FBF248B38DAF97E5E33CEDF5CE4970B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedNoncompeteAgreementsGross" xlink:label="loc_us-gaap_FiniteLivedNoncompeteAgreementsGross_77600B1DFC97906F8F49CEDF5CE4A1C2" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:to="loc_us-gaap_FiniteLivedNoncompeteAgreementsGross_77600B1DFC97906F8F49CEDF5CE4A1C2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_FD5492A054DA5BD14793CEDF5CE44803" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9B9E27F9997EA245E719CEDF5CE30025" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_FD5492A054DA5BD14793CEDF5CE44803" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsPirateBrandsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7FAF2D57E23DCD91B8540C49B5853AAD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7FAF2D57E23DCD91B8540C49B5853AAD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_55CA9C26EFDF7C3BA7C60C49B585F731" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7FAF2D57E23DCD91B8540C49B5853AAD" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_55CA9C26EFDF7C3BA7C60C49B585F731" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_94EED03F25894AAAC67B0C49B585B011_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_55CA9C26EFDF7C3BA7C60C49B585F731" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_94EED03F25894AAAC67B0C49B585B011_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_94EED03F25894AAAC67B0C49B585B011" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_55CA9C26EFDF7C3BA7C60C49B585F731" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_94EED03F25894AAAC67B0C49B585B011" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PirateBrandsMember" xlink:label="loc_hsy_PirateBrandsMember_8BA5C6FB346D08C011D80C49B58534EE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_94EED03F25894AAAC67B0C49B585B011" xlink:to="loc_hsy_PirateBrandsMember_8BA5C6FB346D08C011D80C49B58534EE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedInventory" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedInventory_00FCE75EAA91FCEF9D410C49B5863A1D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedInventory_00FCE75EAA91FCEF9D410C49B5863A1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_D5C07B015A636410B7A50C49B586D731" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_D5C07B015A636410B7A50C49B586D731" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_F540C4E11A8D9D52D9470C49B58662FE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_us-gaap_Goodwill_F540C4E11A8D9D52D9470C49B58662FE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_844A49A088A29FBBF5090C49B586F377" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_844A49A088A29FBBF5090C49B586F377" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities" xlink:label="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_97A11D7E6E05BB222CAA0C49B58787C0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_97A11D7E6E05BB222CAA0C49B58787C0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_1B978322A1FEFDCF65D50C49B58747EB" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_6CEB4FB97EC37260C50D0C49B58548DA" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_1B978322A1FEFDCF65D50C49B58747EB" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsPirateBrandsNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_F8D49F5571B2A5D3D33CAD8A4C913A1F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F8D49F5571B2A5D3D33CAD8A4C913A1F" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_StatementScenarioAxis" xlink:label="loc_srt_StatementScenarioAxis_F726E35C12F7E3113D43AD8A4C8C01AB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_srt_StatementScenarioAxis_F726E35C12F7E3113D43AD8A4C8C01AB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_71092E4133588D7E19D5AD8A4C8C1CEF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_StatementScenarioAxis_F726E35C12F7E3113D43AD8A4C8C01AB" xlink:to="loc_srt_ScenarioUnspecifiedDomain_71092E4133588D7E19D5AD8A4C8C1CEF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_71092E4133588D7E19D5AD8A4C8C1CEF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_StatementScenarioAxis_F726E35C12F7E3113D43AD8A4C8C01AB" xlink:to="loc_srt_ScenarioUnspecifiedDomain_71092E4133588D7E19D5AD8A4C8C1CEF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_2FE0BBD8251E55E01DB1AD8A4C8D874B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_srt_RangeAxis_2FE0BBD8251E55E01DB1AD8A4C8D874B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_255DD783124C2BE7B9FFAD8A4C8D132D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_2FE0BBD8251E55E01DB1AD8A4C8D874B" xlink:to="loc_srt_RangeMember_255DD783124C2BE7B9FFAD8A4C8D132D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_255DD783124C2BE7B9FFAD8A4C8D132D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_2FE0BBD8251E55E01DB1AD8A4C8D874B" xlink:to="loc_srt_RangeMember_255DD783124C2BE7B9FFAD8A4C8D132D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_C2723F3A91F6D857F331AD8A4C8D8434" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_255DD783124C2BE7B9FFAD8A4C8D132D" xlink:to="loc_srt_MinimumMember_C2723F3A91F6D857F331AD8A4C8D8434" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_A3ED0DFF178D549A03F4AD8A4C8E1FAA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_255DD783124C2BE7B9FFAD8A4C8D132D" xlink:to="loc_srt_MaximumMember_A3ED0DFF178D549A03F4AD8A4C8E1FAA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_F956CF43290388774308AD8A4C8E842C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_F956CF43290388774308AD8A4C8E842C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_9A32FA46233068A34133AD8A4C8E1318_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_F956CF43290388774308AD8A4C8E842C" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_9A32FA46233068A34133AD8A4C8E1318_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_9A32FA46233068A34133AD8A4C8E1318" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_F956CF43290388774308AD8A4C8E842C" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_9A32FA46233068A34133AD8A4C8E1318" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_2387704F0FD062EB3A9FAD8A4C8EF08B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_9A32FA46233068A34133AD8A4C8E1318" xlink:to="loc_us-gaap_TrademarksMember_2387704F0FD062EB3A9FAD8A4C8EF08B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_2E5EC1FDA645DD404392AD8A4C8FD1A4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_9A32FA46233068A34133AD8A4C8E1318" xlink:to="loc_us-gaap_CustomerRelationshipsMember_2E5EC1FDA645DD404392AD8A4C8FD1A4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_26359C767B927BD0B2A0AD8A4C8F50B8" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_26359C767B927BD0B2A0AD8A4C8F50B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_29DB6833EBB17B6B388CAD8A4C8F3C70_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_26359C767B927BD0B2A0AD8A4C8F50B8" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_29DB6833EBB17B6B388CAD8A4C8F3C70_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_29DB6833EBB17B6B388CAD8A4C8F3C70" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_26359C767B927BD0B2A0AD8A4C8F50B8" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_29DB6833EBB17B6B388CAD8A4C8F3C70" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PirateBrandsMember" xlink:label="loc_hsy_PirateBrandsMember_9923BBC5D5B222ADD0A1AD8A4C9072ED" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_29DB6833EBB17B6B388CAD8A4C8F3C70" xlink:to="loc_hsy_PirateBrandsMember_9923BBC5D5B222ADD0A1AD8A4C9072ED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_EAFF79CCD2F5BED49BE6AD8A4C905534" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_EAFF79CCD2F5BED49BE6AD8A4C905534" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_7A8A3F34A1C5082C2824AD8A4C906A4C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_EAFF79CCD2F5BED49BE6AD8A4C905534" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_7A8A3F34A1C5082C2824AD8A4C906A4C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_7A8A3F34A1C5082C2824AD8A4C906A4C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_EAFF79CCD2F5BED49BE6AD8A4C905534" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_7A8A3F34A1C5082C2824AD8A4C906A4C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_28B30960A5D8E20032BEAD8A4C90ADFD" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_srt_OwnershipAxis_28B30960A5D8E20032BEAD8A4C90ADFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_2C30603FD77E3F5E27A3AD8A4C916412_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_28B30960A5D8E20032BEAD8A4C90ADFD" xlink:to="loc_srt_OwnershipDomain_2C30603FD77E3F5E27A3AD8A4C916412_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_2C30603FD77E3F5E27A3AD8A4C916412" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_28B30960A5D8E20032BEAD8A4C90ADFD" xlink:to="loc_srt_OwnershipDomain_2C30603FD77E3F5E27A3AD8A4C916412" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_D5E9D57273DF545F2BE7AD8A4C91C2DE" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_6AAAF92396582B643EF7AD8A4C8C9EE0" xlink:to="loc_us-gaap_StatementClassOfStockAxis_D5E9D57273DF545F2BE7AD8A4C91C2DE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_C5DD5E305F4F79700F8EAD8A4C913429_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_D5E9D57273DF545F2BE7AD8A4C91C2DE" xlink:to="loc_us-gaap_ClassOfStockDomain_C5DD5E305F4F79700F8EAD8A4C913429_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_C5DD5E305F4F79700F8EAD8A4C913429" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_D5E9D57273DF545F2BE7AD8A4C91C2DE" xlink:to="loc_us-gaap_ClassOfStockDomain_C5DD5E305F4F79700F8EAD8A4C913429" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationConsiderationTransferred1" xlink:label="loc_us-gaap_BusinessCombinationConsiderationTransferred1_989F6B2049AC7CB6AD77AD8A4C92DD1A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F8D49F5571B2A5D3D33CAD8A4C913A1F" xlink:to="loc_us-gaap_BusinessCombinationConsiderationTransferred1_989F6B2049AC7CB6AD77AD8A4C92DD1A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedTrademarksGross" xlink:label="loc_us-gaap_FiniteLivedTrademarksGross_36557D33D2A45BD6A5EEAD8A4C926C78" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F8D49F5571B2A5D3D33CAD8A4C913A1F" xlink:to="loc_us-gaap_FiniteLivedTrademarksGross_36557D33D2A45BD6A5EEAD8A4C926C78" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedCustomerRelationshipsGross" xlink:label="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_59C80A3E87AD1B41B4DEAD8A4C928D31" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F8D49F5571B2A5D3D33CAD8A4C913A1F" xlink:to="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_59C80A3E87AD1B41B4DEAD8A4C928D31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_04F481C2180106E25388AD8A4C92635A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F8D49F5571B2A5D3D33CAD8A4C913A1F" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_04F481C2180106E25388AD8A4C92635A" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsTables" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_F0AB8E2191BC0958A36DDDBC8159CC09" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_9F6658405D731EFC6410DDBC8157598C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F0AB8E2191BC0958A36DDDBC8159CC09" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_9F6658405D731EFC6410DDBC8157598C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_F4522EB951BCB42600D0DDBC8157702A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_9F6658405D731EFC6410DDBC8157598C" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_F4522EB951BCB42600D0DDBC8157702A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_F4522EB951BCB42600D0DDBC8157702A" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_F4522EB951BCB42600D0DDBC8157702A" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ONEBrandsLLCMember" xlink:label="loc_hsy_ONEBrandsLLCMember_C4F1DFBDF621ABB1062FDDBC81580BEE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F" xlink:to="loc_hsy_ONEBrandsLLCMember_C4F1DFBDF621ABB1062FDDBC81580BEE" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PirateBrandsMember" xlink:label="loc_hsy_PirateBrandsMember_36AAD6098B3659151CAFDDBC81581499" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F" xlink:to="loc_hsy_PirateBrandsMember_36AAD6098B3659151CAFDDBC81581499" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_E498E1AE2C46C0A30CA0DDBC815856EA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F8D656327E4FB9BDC2C0DDBC8157E28F" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_E498E1AE2C46C0A30CA0DDBC815856EA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock" xlink:label="loc_us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock_4D1C277AFD89452CC645DDBC8159DED8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F0AB8E2191BC0958A36DDDBC8159CC09" xlink:to="loc_us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock_4D1C277AFD89452CC645DDBC8159DED8" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessRealignmentActivities" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_D277B9C32F04D460E448F67502201C15" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:to="loc_srt_RangeAxis_D277B9C32F04D460E448F67502201C15" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_6231829CD7D5CAC7B4F8F67502204CB3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_D277B9C32F04D460E448F67502201C15" xlink:to="loc_srt_RangeMember_6231829CD7D5CAC7B4F8F67502204CB3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_6231829CD7D5CAC7B4F8F67502204CB3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_D277B9C32F04D460E448F67502201C15" xlink:to="loc_srt_RangeMember_6231829CD7D5CAC7B4F8F67502204CB3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_AA3DD6D1652D71C525F8F67502208F84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_6231829CD7D5CAC7B4F8F67502204CB3" xlink:to="loc_srt_MinimumMember_AA3DD6D1652D71C525F8F67502208F84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_F5019B26EF1A5FDEFA1DF67502205FDA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_6231829CD7D5CAC7B4F8F67502204CB3" xlink:to="loc_srt_MaximumMember_F5019B26EF1A5FDEFA1DF67502205FDA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_4840CC37893C540ED343F6750221B519" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_4840CC37893C540ED343F6750221B519" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_B5492F79E5A893D26C01F6750221EB38_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_4840CC37893C540ED343F6750221B519" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_B5492F79E5A893D26C01F6750221EB38_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_B5492F79E5A893D26C01F6750221EB38" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_4840CC37893C540ED343F6750221B519" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_B5492F79E5A893D26C01F6750221EB38" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringChargesMember" xlink:label="loc_us-gaap_RestructuringChargesMember_792DE96B14A8BFD2F884F6750221E30D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_B5492F79E5A893D26C01F6750221EB38" xlink:to="loc_us-gaap_RestructuringChargesMember_792DE96B14A8BFD2F884F6750221E30D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_CA92E9F47BC879DDB49BF6750222CACC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_CA92E9F47BC879DDB49BF6750222CACC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_A7D57EA80328793CBEDBF67502229EEA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_CA92E9F47BC879DDB49BF6750222CACC" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_A7D57EA80328793CBEDBF67502229EEA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_A7D57EA80328793CBEDBF67502229EEA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_CA92E9F47BC879DDB49BF6750222CACC" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_A7D57EA80328793CBEDBF67502229EEA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GeographicConcentrationRiskMember" xlink:label="loc_us-gaap_GeographicConcentrationRiskMember_0264CC88F09EBDFAB59DF67502227951" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_A7D57EA80328793CBEDBF67502229EEA" xlink:to="loc_us-gaap_GeographicConcentrationRiskMember_0264CC88F09EBDFAB59DF67502227951" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_828D3560A5510E51F334F675022341BD" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_828D3560A5510E51F334F675022341BD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_866519F242AF7D15FAF5F67502234FE6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_828D3560A5510E51F334F675022341BD" xlink:to="loc_us-gaap_SegmentDomain_866519F242AF7D15FAF5F67502234FE6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_866519F242AF7D15FAF5F67502234FE6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_828D3560A5510E51F334F675022341BD" xlink:to="loc_us-gaap_SegmentDomain_866519F242AF7D15FAF5F67502234FE6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_NorthAmericaMember" xlink:label="loc_srt_NorthAmericaMember_900ED1454EFDAD7D7A72F6750223F159" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_866519F242AF7D15FAF5F67502234FE6" xlink:to="loc_srt_NorthAmericaMember_900ED1454EFDAD7D7A72F6750223F159" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_954BBDA939BEA23B92D1F6750223B590" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_866519F242AF7D15FAF5F67502234FE6" xlink:to="loc_hsy_InternationalandOtherSegmentMember_954BBDA939BEA23B92D1F6750223B590" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_DE0820FC16EE6A868530F6750224D32E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:to="loc_us-gaap_RestructuringPlanAxis_DE0820FC16EE6A868530F6750224D32E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_14CE07063BC825DF4A65F6750224E7A5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_DE0820FC16EE6A868530F6750224D32E" xlink:to="loc_us-gaap_RestructuringPlanDomain_14CE07063BC825DF4A65F6750224E7A5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_14CE07063BC825DF4A65F6750224E7A5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_DE0820FC16EE6A868530F6750224D32E" xlink:to="loc_us-gaap_RestructuringPlanDomain_14CE07063BC825DF4A65F6750224E7A5" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_CC0DCF59605141E951D6F675022450A3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_14CE07063BC825DF4A65F6750224E7A5" xlink:to="loc_hsy_MarginforGrowthProgramMember_CC0DCF59605141E951D6F675022450A3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_02604F43C81FB383CBB5F67502246EEB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_14CE07063BC825DF4A65F6750224E7A5" xlink:to="loc_hsy_OperationalOptimizationProgramMember_02604F43C81FB383CBB5F67502246EEB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_008D3342508DB28F41F0F6750225D27D" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B8AE6D6D57F573927A0BF675021F55F9" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_008D3342508DB28F41F0F6750225D27D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_008D3342508DB28F41F0F6750225D27D" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_008D3342508DB28F41F0F6750225D27D" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeSeveranceMember" xlink:label="loc_us-gaap_EmployeeSeveranceMember_A60D9A28BC6D914BC2BDF6750225FB6B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A" xlink:to="loc_us-gaap_EmployeeSeveranceMember_A60D9A28BC6D914BC2BDF6750225FB6B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherRestructuringMember" xlink:label="loc_us-gaap_OtherRestructuringMember_58F9047925A75B871683F67502253C5A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A" xlink:to="loc_us-gaap_OtherRestructuringMember_58F9047925A75B871683F67502253C5A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_2940051ADD06C3368BA7F6750226BD3B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_82F9AF2842AFDCECD707F6750225DF7A" xlink:to="loc_us-gaap_FacilityClosingMember_2940051ADD06C3368BA7F6750226BD3B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_B85D6ECCF2E8D34290C9F6750226AD59" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_B85D6ECCF2E8D34290C9F6750226AD59" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringAndRelatedCostExpectedCost1" xlink:label="loc_us-gaap_RestructuringAndRelatedCostExpectedCost1_90AC7D9A36B407F818F1F6750226C10B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_RestructuringAndRelatedCostExpectedCost1_90AC7D9A36B407F818F1F6750226C10B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringAndRelatedCostCostIncurredToDate1" xlink:label="loc_us-gaap_RestructuringAndRelatedCostCostIncurredToDate1_3E4D7183832006095768F67502269862" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_RestructuringAndRelatedCostCostIncurredToDate1_3E4D7183832006095768F67502269862" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_A8D8776B57E7DAF48EABF675022775E7" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_AssetImpairmentCharges_A8D8776B57E7DAF48EABF675022775E7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_RestructuringandRelatedCostExpectedCostCashPortion" xlink:label="loc_hsy_RestructuringandRelatedCostExpectedCostCashPortion_7C37A410683BC8F018D0F6750227D31A" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_hsy_RestructuringandRelatedCostExpectedCostCashPortion_7C37A410683BC8F018D0F6750227D31A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent" xlink:label="loc_hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent_4608BCF2BC527CBAE2B9F6750227A961" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent_4608BCF2BC527CBAE2B9F6750227A961" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_2FF0A468F9CBE3B9DED4F6750227E83B" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_RestructuringCharges_2FF0A468F9CBE3B9DED4F6750227E83B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_7BF5059EAA08E7971C30F67502281D0F" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_7BF5059EAA08E7971C30F67502281D0F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsHeldForUse" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_E69F62A87B03500EE446F6750228B4F8" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_29BEB14806177927EDAAF67502267170" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_E69F62A87B03500EE446F6750228B4F8" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_FF039CBAF54D54C687DBC7FBACA9480E" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_31F014C9FD969099B6D0C7FBAC9F2E3B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_FF039CBAF54D54C687DBC7FBACA9480E" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_31F014C9FD969099B6D0C7FBAC9F2E3B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_EEBAE4C92F58D07F245DC7FBAC9F27E4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_31F014C9FD969099B6D0C7FBAC9F2E3B" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_EEBAE4C92F58D07F245DC7FBAC9F27E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_EEBAE4C92F58D07F245DC7FBAC9F27E4" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_EEBAE4C92F58D07F245DC7FBAC9F27E4" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CostOfSalesMember" xlink:label="loc_us-gaap_CostOfSalesMember_A38CFCA82B551FB5154DC7FBACA5948D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2" xlink:to="loc_us-gaap_CostOfSalesMember_A38CFCA82B551FB5154DC7FBACA5948D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_F5926563C9B007A489BFC7FBACA5B17B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_F5926563C9B007A489BFC7FBACA5B17B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringChargesMember" xlink:label="loc_us-gaap_RestructuringChargesMember_C52DB84512876C7D3B31C7FBACA6EADD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_D5774787BD7B3BF8D30DC7FBACA563D2" xlink:to="loc_us-gaap_RestructuringChargesMember_C52DB84512876C7D3B31C7FBACA6EADD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_CE9C6C081ED95B9028B1C7FBACA6361E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_31F014C9FD969099B6D0C7FBAC9F2E3B" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_CE9C6C081ED95B9028B1C7FBACA6361E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_CE9C6C081ED95B9028B1C7FBACA6361E" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_CE9C6C081ED95B9028B1C7FBACA6361E" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeSeveranceMember" xlink:label="loc_us-gaap_EmployeeSeveranceMember_EB872DEEB0C7D889404EC7FBACA6F1A1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF" xlink:to="loc_us-gaap_EmployeeSeveranceMember_EB872DEEB0C7D889404EC7FBACA6F1A1" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_AcceleratedDepreciationandAmortizationMember" xlink:label="loc_hsy_AcceleratedDepreciationandAmortizationMember_565C928617D8C80641EFC7FBACA7FDA1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF" xlink:to="loc_hsy_AcceleratedDepreciationandAmortizationMember_565C928617D8C80641EFC7FBACA7FDA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherRestructuringMember" xlink:label="loc_us-gaap_OtherRestructuringMember_2D7938205F38B05CAD26C7FBACA7A744" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF" xlink:to="loc_us-gaap_OtherRestructuringMember_2D7938205F38B05CAD26C7FBACA7A744" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_652DDBE03491E32D0567C7FBACA7DEA1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_8B736D8E3EF38984011BC7FBACA6E0AF" xlink:to="loc_us-gaap_FacilityClosingMember_652DDBE03491E32D0567C7FBACA7DEA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_24AA8547A87EDBA9A578C7FBACA7E137" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_31F014C9FD969099B6D0C7FBAC9F2E3B" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_24AA8547A87EDBA9A578C7FBACA7E137" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_B7074755ED6B6F14DFA6C7FBACA7116B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_24AA8547A87EDBA9A578C7FBACA7E137" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_B7074755ED6B6F14DFA6C7FBACA7116B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_B7074755ED6B6F14DFA6C7FBACA7116B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_24AA8547A87EDBA9A578C7FBACA7E137" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_B7074755ED6B6F14DFA6C7FBACA7116B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_AD349A244B8F34E1390BC7FBACA89B9E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_31F014C9FD969099B6D0C7FBAC9F2E3B" xlink:to="loc_us-gaap_RestructuringPlanAxis_AD349A244B8F34E1390BC7FBACA89B9E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_3475E6900707E4BC6298C7FBACA82076_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_AD349A244B8F34E1390BC7FBACA89B9E" xlink:to="loc_us-gaap_RestructuringPlanDomain_3475E6900707E4BC6298C7FBACA82076_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_3475E6900707E4BC6298C7FBACA82076" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_AD349A244B8F34E1390BC7FBACA89B9E" xlink:to="loc_us-gaap_RestructuringPlanDomain_3475E6900707E4BC6298C7FBACA82076" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_6AAE48CAF9E8DFA007C9C7FBACA87814" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_3475E6900707E4BC6298C7FBACA82076" xlink:to="loc_hsy_MarginforGrowthProgramMember_6AAE48CAF9E8DFA007C9C7FBACA87814" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_0132AF7C3285B97EA3D5C7FBACA8C0F7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_3475E6900707E4BC6298C7FBACA82076" xlink:to="loc_hsy_OperationalOptimizationProgramMember_0132AF7C3285B97EA3D5C7FBACA8C0F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_D375CDC405A82FD450BEC7FBACA9801C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_FF039CBAF54D54C687DBC7FBACA9480E" xlink:to="loc_us-gaap_RestructuringCharges_D375CDC405A82FD450BEC7FBACA9801C" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_E80F8952C33DE18F48E3D310C1AC01A4" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_C7CB9ADE2D29EAA8E21CD310C1ABC2C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_E80F8952C33DE18F48E3D310C1AC01A4" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_C7CB9ADE2D29EAA8E21CD310C1ABC2C7" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_294107F00C23404F7A82D310C1AB1ECD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_C7CB9ADE2D29EAA8E21CD310C1ABC2C7" xlink:to="loc_us-gaap_RestructuringPlanAxis_294107F00C23404F7A82D310C1AB1ECD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_51BF08AED307E6B1E05FD310C1ABAB79_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_294107F00C23404F7A82D310C1AB1ECD" xlink:to="loc_us-gaap_RestructuringPlanDomain_51BF08AED307E6B1E05FD310C1ABAB79_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_51BF08AED307E6B1E05FD310C1ABAB79" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_294107F00C23404F7A82D310C1AB1ECD" xlink:to="loc_us-gaap_RestructuringPlanDomain_51BF08AED307E6B1E05FD310C1ABAB79" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_7D6B3337D1515E32D5D6D310C1ACB9C9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_51BF08AED307E6B1E05FD310C1ABAB79" xlink:to="loc_hsy_OperationalOptimizationProgramMember_7D6B3337D1515E32D5D6D310C1ACB9C9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_699D8A28F08178026CFED310C1ACFA38" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_C7CB9ADE2D29EAA8E21CD310C1ABC2C7" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_699D8A28F08178026CFED310C1ACFA38" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_0F542FBF27C292470F99D310C1ACBF8C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_699D8A28F08178026CFED310C1ACFA38" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_0F542FBF27C292470F99D310C1ACBF8C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_0F542FBF27C292470F99D310C1ACBF8C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_699D8A28F08178026CFED310C1ACFA38" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_0F542FBF27C292470F99D310C1ACBF8C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_E8E4D623B57AD2F9150FD310C1AD34B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_E80F8952C33DE18F48E3D310C1AC01A4" xlink:to="loc_us-gaap_RestructuringCharges_E8E4D623B57AD2F9150FD310C1AD34B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringReserveRollForward" xlink:label="loc_us-gaap_RestructuringReserveRollForward_FA9E7220CE4B5B1B3557D310C1ADD2F5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_E80F8952C33DE18F48E3D310C1AC01A4" xlink:to="loc_us-gaap_RestructuringReserveRollForward_FA9E7220CE4B5B1B3557D310C1ADD2F5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringReserve" xlink:label="loc_us-gaap_RestructuringReserve_EA56E2F35C0947BB5F40D310C1AD3AEF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FA9E7220CE4B5B1B3557D310C1ADD2F5" xlink:to="loc_us-gaap_RestructuringReserve_EA56E2F35C0947BB5F40D310C1AD3AEF" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_RestructuringChargesBusinessRealignmentReserve" xlink:label="loc_hsy_RestructuringChargesBusinessRealignmentReserve_5DA2734467F9E4B445AED310C1AD8F35" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FA9E7220CE4B5B1B3557D310C1ADD2F5" xlink:to="loc_hsy_RestructuringChargesBusinessRealignmentReserve_5DA2734467F9E4B445AED310C1AD8F35" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PaymentsForRestructuring" xlink:label="loc_us-gaap_PaymentsForRestructuring_C7F71227562DEF670867D310C1AE3611" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FA9E7220CE4B5B1B3557D310C1ADD2F5" xlink:to="loc_us-gaap_PaymentsForRestructuring_C7F71227562DEF670867D310C1AE3611" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessRealignmentActivitiesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/CommitmentsAndContingencies" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskLineItems" xlink:label="loc_us-gaap_ConcentrationRiskLineItems_5A4CAD97E0FF801E6391AD1BBFD9ACD3" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTable" xlink:label="loc_us-gaap_ConcentrationRiskTable_50638C2759D6334F5194AD1BBFD1EE66" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_5A4CAD97E0FF801E6391AD1BBFD9ACD3" xlink:to="loc_us-gaap_ConcentrationRiskTable_50638C2759D6334F5194AD1BBFD1EE66" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_717BB172A8167F75C396AD1BBFD24867" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ConcentrationRiskTable_50638C2759D6334F5194AD1BBFD1EE66" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_717BB172A8167F75C396AD1BBFD24867" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_2F7C4D85CA3078004462AD1BBFD28CCD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_717BB172A8167F75C396AD1BBFD24867" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_2F7C4D85CA3078004462AD1BBFD28CCD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_2F7C4D85CA3078004462AD1BBFD28CCD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_717BB172A8167F75C396AD1BBFD24867" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_2F7C4D85CA3078004462AD1BBFD28CCD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember" xlink:label="loc_us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember_DA7787CFD231C41E2973AD1BBFD27BC3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_2F7C4D85CA3078004462AD1BBFD28CCD" xlink:to="loc_us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember_DA7787CFD231C41E2973AD1BBFD27BC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_StatementScenarioAxis" xlink:label="loc_srt_StatementScenarioAxis_86DC6F46AECAE6744424AD1BBFD84EE5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ConcentrationRiskTable_50638C2759D6334F5194AD1BBFD1EE66" xlink:to="loc_srt_StatementScenarioAxis_86DC6F46AECAE6744424AD1BBFD84EE5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_54F0A1242D4247B20577AD1BBFD898B5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_StatementScenarioAxis_86DC6F46AECAE6744424AD1BBFD84EE5" xlink:to="loc_srt_ScenarioUnspecifiedDomain_54F0A1242D4247B20577AD1BBFD898B5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_54F0A1242D4247B20577AD1BBFD898B5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_StatementScenarioAxis_86DC6F46AECAE6744424AD1BBFD84EE5" xlink:to="loc_srt_ScenarioUnspecifiedDomain_54F0A1242D4247B20577AD1BBFD898B5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioForecastMember" xlink:label="loc_srt_ScenarioForecastMember_D6F0F133B7DD7ADCAC93AD1BBFD85317" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ScenarioUnspecifiedDomain_54F0A1242D4247B20577AD1BBFD898B5" xlink:to="loc_srt_ScenarioForecastMember_D6F0F133B7DD7ADCAC93AD1BBFD85317" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityNumberOfEmployees" xlink:label="loc_dei_EntityNumberOfEmployees_8FB06CE07CCF292AB353AD1BBFD98F1A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_5A4CAD97E0FF801E6391AD1BBFD9ACD3" xlink:to="loc_dei_EntityNumberOfEmployees_8FB06CE07CCF292AB353AD1BBFD98F1A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_EntityNumberofPartTimeEmployees" xlink:label="loc_hsy_EntityNumberofPartTimeEmployees_28DFFFDD0C5A00326140AD1BBFD92453" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_5A4CAD97E0FF801E6391AD1BBFD9ACD3" xlink:to="loc_hsy_EntityNumberofPartTimeEmployees_28DFFFDD0C5A00326140AD1BBFD92453" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_E5EEF1CD744AA4431D1BAD1BBFD9652D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_5A4CAD97E0FF801E6391AD1BBFD9ACD3" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_E5EEF1CD744AA4431D1BAD1BBFD9652D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_732439F7DD42D4BEBCC7C8519DAC55F1" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationTable" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_7375402556942F0B1762C8519DABF5DB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_732439F7DD42D4BEBCC7C8519DAC55F1" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_7375402556942F0B1762C8519DABF5DB" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_54C48B3CD92F94A896ADC8519DAB424D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_7375402556942F0B1762C8519DABF5DB" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_54C48B3CD92F94A896ADC8519DAB424D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain" xlink:label="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_9F9C707CFBC05D0A9F20C8519DAC66BA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_54C48B3CD92F94A896ADC8519DAB424D" xlink:to="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_9F9C707CFBC05D0A9F20C8519DAC66BA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain" xlink:label="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_9F9C707CFBC05D0A9F20C8519DAC66BA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_54C48B3CD92F94A896ADC8519DAB424D" xlink:to="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_9F9C707CFBC05D0A9F20C8519DAC66BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InventoriesMember" xlink:label="loc_us-gaap_InventoriesMember_1EA0D9E7A986DF702A15C8519DACCF9F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_9F9C707CFBC05D0A9F20C8519DAC66BA" xlink:to="loc_us-gaap_InventoriesMember_1EA0D9E7A986DF702A15C8519DACCF9F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_732439F7DD42D4BEBCC7C8519DAC55F1" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary_45CCD50D5055DCB70E09C8519DAD5453" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary_45CCD50D5055DCB70E09C8519DAD5453" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary_01ED39A70873E9680A54C8519DADD86B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary_01ED39A70873E9680A54C8519DADD86B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary_CFAAF5E84D6737202A2BC8519DADFDA7" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary_CFAAF5E84D6737202A2BC8519DADFDA7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary_CB87039A7241C3498DE6C8519DAE7504" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary_CB87039A7241C3498DE6C8519DAE7504" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary_C7315F3DC332FCF67B1AC8519DAE1418" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_FC6730F59160A91C8542C8519DACF050" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary_C7315F3DC332FCF67B1AC8519DAE1418" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/CommitmentsAndContingenciesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedBalanceSheets" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_242D92DA8F1DD6B58402D310C32F9DC2" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_43D7EFA7EEBE87590DCCD310C3278DB7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_242D92DA8F1DD6B58402D310C32F9DC2" xlink:to="loc_us-gaap_StatementTable_43D7EFA7EEBE87590DCCD310C3278DB7" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_EFD900199BE11AB41A74D310C32DC553" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_43D7EFA7EEBE87590DCCD310C3278DB7" xlink:to="loc_us-gaap_StatementClassOfStockAxis_EFD900199BE11AB41A74D310C32DC553" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_8434A0E797213EDEEC35D310C32EFEFC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_EFD900199BE11AB41A74D310C32DC553" xlink:to="loc_us-gaap_ClassOfStockDomain_8434A0E797213EDEEC35D310C32EFEFC_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_8434A0E797213EDEEC35D310C32EFEFC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_EFD900199BE11AB41A74D310C32DC553" xlink:to="loc_us-gaap_ClassOfStockDomain_8434A0E797213EDEEC35D310C32EFEFC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_06841FD7106609C64FE5D310C32E2CCB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_8434A0E797213EDEEC35D310C32EFEFC" xlink:to="loc_us-gaap_CommonStockMember_06841FD7106609C64FE5D310C32E2CCB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_EB960AA62B2DC5398E8FD310C32E146A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_8434A0E797213EDEEC35D310C32EFEFC" xlink:to="loc_us-gaap_CommonClassBMember_EB960AA62B2DC5398E8FD310C32E146A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_125F49521C28C8CB3A07D310C32F4433" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_242D92DA8F1DD6B58402D310C32F9DC2" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_125F49521C28C8CB3A07D310C32F4433" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetsAbstract" xlink:label="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_242D92DA8F1DD6B58402D310C32F9DC2" xlink:to="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetsCurrentAbstract" xlink:label="loc_us-gaap_AssetsCurrentAbstract_3CC50DF933E615AFE038D310C32F96FB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_AssetsCurrentAbstract_3CC50DF933E615AFE038D310C32F96FB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccountsReceivableNetCurrent" xlink:label="loc_us-gaap_AccountsReceivableNetCurrent_D9E158616BD0A94ADC1DD310C32F7F37" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_3CC50DF933E615AFE038D310C32F96FB" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_D9E158616BD0A94ADC1DD310C32F7F37" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InventoryNet" xlink:label="loc_us-gaap_InventoryNet_CD3CE536EB88F9D72B2DD310C330A7A5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_3CC50DF933E615AFE038D310C32F96FB" xlink:to="loc_us-gaap_InventoryNet_CD3CE536EB88F9D72B2DD310C330A7A5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PrepaidExpenseAndOtherAssetsCurrent" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_53990BE5728F1BAC1B83D310C3308CE7" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_3CC50DF933E615AFE038D310C32F96FB" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_53990BE5728F1BAC1B83D310C3308CE7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetsCurrent" xlink:label="loc_us-gaap_AssetsCurrent_A49BC9163C365CBFFB04D310C33062C2" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_3CC50DF933E615AFE038D310C32F96FB" xlink:to="loc_us-gaap_AssetsCurrent_A49BC9163C365CBFFB04D310C33062C2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_4F83FD24F36E2AFAFB68D310C330C112" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_4F83FD24F36E2AFAFB68D310C330C112" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_1E4D289EF11EE80F21A7D310C3312D0E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_Goodwill_1E4D289EF11EE80F21A7D310C3312D0E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_6B4B5B4EC98F2294971DD310C331A499" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_6B4B5B4EC98F2294971DD310C331A499" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherAssetsNoncurrent" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_505736F3EB3310373B8AD310C331EBF6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_505736F3EB3310373B8AD310C331EBF6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DeferredIncomeTaxAssetsNet" xlink:label="loc_us-gaap_DeferredIncomeTaxAssetsNet_E51B3854A134615CA6C4D310C331D11C" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_DeferredIncomeTaxAssetsNet_E51B3854A134615CA6C4D310C331D11C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Assets" xlink:label="loc_us-gaap_Assets_E22834001B5F68D3F1F6D310C331574F" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_EE260E974089283B5A5FD310C32F6C56" xlink:to="loc_us-gaap_Assets_E22834001B5F68D3F1F6D310C331574F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LiabilitiesAndStockholdersEquityAbstract" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_242D92DA8F1DD6B58402D310C32F9DC2" xlink:to="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LiabilitiesCurrentAbstract" xlink:label="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccountsPayableCurrent" xlink:label="loc_us-gaap_AccountsPayableCurrent_CE3C2A6DC4DD9E0BF9F7D310C332A684" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:to="loc_us-gaap_AccountsPayableCurrent_CE3C2A6DC4DD9E0BF9F7D310C332A684" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccruedLiabilitiesCurrent" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_A428ED4EF9EDF0BECED5D310C332E3D2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:to="loc_us-gaap_AccruedLiabilitiesCurrent_A428ED4EF9EDF0BECED5D310C332E3D2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccruedIncomeTaxesCurrent" xlink:label="loc_us-gaap_AccruedIncomeTaxesCurrent_BC933D50F7E7F20490B3D310C3323FEF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:to="loc_us-gaap_AccruedIncomeTaxesCurrent_BC933D50F7E7F20490B3D310C3323FEF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShortTermBorrowings" xlink:label="loc_us-gaap_ShortTermBorrowings_814DF14E6DC648694582D310C333DA42" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:to="loc_us-gaap_ShortTermBorrowings_814DF14E6DC648694582D310C333DA42" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_504078359AEDE41D2499D310C3334ADA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:to="loc_us-gaap_LongTermDebtCurrent_504078359AEDE41D2499D310C3334ADA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LiabilitiesCurrent" xlink:label="loc_us-gaap_LiabilitiesCurrent_6A465C67EF16453C488ED310C33385FC" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_FF7EAE878F63E8702FD9D310C3320B3D" xlink:to="loc_us-gaap_LiabilitiesCurrent_6A465C67EF16453C488ED310C33385FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtAndCapitalLeaseObligations" xlink:label="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_E25E6BBC48DAD1DD2D3ED310C3333A20" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_E25E6BBC48DAD1DD2D3ED310C3333A20" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherLiabilitiesNoncurrent" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_F9C331D1F21E0FB4CAA0D310C333F8AC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_F9C331D1F21E0FB4CAA0D310C333F8AC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DeferredIncomeTaxLiabilitiesNet" xlink:label="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_2EC2A6FB4FC0C9F3D36CD310C334F23D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_2EC2A6FB4FC0C9F3D36CD310C334F23D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Liabilities" xlink:label="loc_us-gaap_Liabilities_83DCBF736BF467799621D310C33471AF" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_Liabilities_83DCBF736BF467799621D310C33471AF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PreferredStockValue" xlink:label="loc_us-gaap_PreferredStockValue_471FE3B529E1AA60E5AAD310C339899E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_PreferredStockValue_471FE3B529E1AA60E5AAD310C339899E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockValue" xlink:label="loc_us-gaap_CommonStockValue_C3BE26F022783C335318D310C339A463" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_CommonStockValue_C3BE26F022783C335318D310C339A463" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AdditionalPaidInCapital" xlink:label="loc_us-gaap_AdditionalPaidInCapital_27D496EA4DE658CA06B8D310C33A9D82" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_AdditionalPaidInCapital_27D496EA4DE658CA06B8D310C33A9D82" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetainedEarningsAccumulatedDeficit" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_871A32933C9EFE1644E2D310C33A6535" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_871A32933C9EFE1644E2D310C33A6535" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockValue" xlink:label="loc_us-gaap_TreasuryStockValue_DFE881926E6B31A4BBCAD310C33A5897" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_TreasuryStockValue_DFE881926E6B31A4BBCAD310C33A5897" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_149CE710ADB2E9DC89EBD310C33A6790" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_149CE710ADB2E9DC89EBD310C33A6790" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockholdersEquity" xlink:label="loc_us-gaap_StockholdersEquity_E5496ADCBF17F077B5DBD310C33A44BD" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_StockholdersEquity_E5496ADCBF17F077B5DBD310C33A44BD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MinorityInterest" xlink:label="loc_us-gaap_MinorityInterest_01F3B808BD9981861720D310C33BB670" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_MinorityInterest_01F3B808BD9981861720D310C33BB670" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_AF2EE5F810EB5D6D0494D310C33B6E63" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_D33C9B587420606114A7D310C33427E4" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_AF2EE5F810EB5D6D0494D310C33B6E63" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LiabilitiesAndStockholdersEquity" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_183A6D515584EDA98D43D310C33BB6C8" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_14075E75365DABA1B5F3D310C3327381" xlink:to="loc_us-gaap_LiabilitiesAndStockholdersEquity_183A6D515584EDA98D43D310C33BB6C8" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedBalanceSheetsParenthetical" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_263D3B1C423F1D382AAACEDF5D5F2B28" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_F3A6E8A0D98E81417056CEDF5D5E6A8B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_263D3B1C423F1D382AAACEDF5D5F2B28" xlink:to="loc_us-gaap_StatementTable_F3A6E8A0D98E81417056CEDF5D5E6A8B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_A723A7B23AEB2986A7B8CEDF5D5EA4C8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_F3A6E8A0D98E81417056CEDF5D5E6A8B" xlink:to="loc_us-gaap_StatementClassOfStockAxis_A723A7B23AEB2986A7B8CEDF5D5EA4C8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_329F43D429DE0528571BCEDF5D5E429E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_A723A7B23AEB2986A7B8CEDF5D5EA4C8" xlink:to="loc_us-gaap_ClassOfStockDomain_329F43D429DE0528571BCEDF5D5E429E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_329F43D429DE0528571BCEDF5D5E429E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_A723A7B23AEB2986A7B8CEDF5D5EA4C8" xlink:to="loc_us-gaap_ClassOfStockDomain_329F43D429DE0528571BCEDF5D5E429E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_B037DA95C849BBCFC22DCEE83AA9365C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_329F43D429DE0528571BCEDF5D5E429E" xlink:to="loc_us-gaap_CommonStockMember_B037DA95C849BBCFC22DCEE83AA9365C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_8895E69777160BC89FE7CEDF5D5F21DD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_329F43D429DE0528571BCEDF5D5E429E" xlink:to="loc_us-gaap_CommonClassBMember_8895E69777160BC89FE7CEDF5D5F21DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PreferredStockSharesIssued" xlink:label="loc_us-gaap_PreferredStockSharesIssued_709376ABDB994F64DC4ECEDF5D5FBBBD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_263D3B1C423F1D382AAACEDF5D5F2B28" xlink:to="loc_us-gaap_PreferredStockSharesIssued_709376ABDB994F64DC4ECEDF5D5FBBBD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockSharesIssued" xlink:label="loc_us-gaap_CommonStockSharesIssued_CFE4EB3B42EB31F536EFCEDF5D605693" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_263D3B1C423F1D382AAACEDF5D5F2B28" xlink:to="loc_us-gaap_CommonStockSharesIssued_CFE4EB3B42EB31F536EFCEDF5D605693" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockShares" xlink:label="loc_us-gaap_TreasuryStockShares_1CE9EAA7D7432AA7760ACEDF5D60D7A8" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_263D3B1C423F1D382AAACEDF5D5F2B28" xlink:to="loc_us-gaap_TreasuryStockShares_1CE9EAA7D7432AA7760ACEDF5D60D7A8" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedStatementsOfCashFlows" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedStatementsOfComprehensiveIncome" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedStatementsOfIncome" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_7C2FAC5CFCB6ADADAE5A4054C6425360" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_StatementTable_7C2FAC5CFCB6ADADAE5A4054C6425360" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_3898DF9FBF49039ADB6A4054C642A6B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_7C2FAC5CFCB6ADADAE5A4054C6425360" xlink:to="loc_us-gaap_StatementClassOfStockAxis_3898DF9FBF49039ADB6A4054C642A6B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_7C72CA885EBB432DA81A4054C6425FC1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_3898DF9FBF49039ADB6A4054C642A6B3" xlink:to="loc_us-gaap_ClassOfStockDomain_7C72CA885EBB432DA81A4054C6425FC1_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_7C72CA885EBB432DA81A4054C6425FC1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_3898DF9FBF49039ADB6A4054C642A6B3" xlink:to="loc_us-gaap_ClassOfStockDomain_7C72CA885EBB432DA81A4054C6425FC1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_7AEDFC30C0F2703A7F124054C643037F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_7C72CA885EBB432DA81A4054C6425FC1" xlink:to="loc_us-gaap_CommonStockMember_7AEDFC30C0F2703A7F124054C643037F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_50A9DF732263BCEF3CF94054C6439F7F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_7C72CA885EBB432DA81A4054C6425FC1" xlink:to="loc_us-gaap_CommonClassBMember_50A9DF732263BCEF3CF94054C6439F7F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_DFA2CA8EA4B580EDAF634054C6437E4A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_DFA2CA8EA4B580EDAF634054C6437E4A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CostOfGoodsAndServicesSold" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_5BACFD3019AACBDF52494054C644AE2A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_5BACFD3019AACBDF52494054C644AE2A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GrossProfit" xlink:label="loc_us-gaap_GrossProfit_7A35F6D22E6B78569FFD4054C644E332" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_GrossProfit_7A35F6D22E6B78569FFD4054C644E332" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpense" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_A0B258B36FA6AA8635C04054C64429DC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_A0B258B36FA6AA8635C04054C64429DC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_B96A7B4DBAC4CA832A2E4054C644AD51" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_AssetImpairmentCharges_B96A7B4DBAC4CA832A2E4054C644AD51" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_RestructuringChargesBusinessRealignment" xlink:label="loc_hsy_RestructuringChargesBusinessRealignment_417C97A7109E973FFDA34054C64426A5" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_hsy_RestructuringChargesBusinessRealignment_417C97A7109E973FFDA34054C64426A5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_CE6949CE4EA48DC2B5C84054C6447AC8" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_OperatingIncomeLoss_CE6949CE4EA48DC2B5C84054C6447AC8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_7AFF77411AAA32A885854054C644E8D8" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_7AFF77411AAA32A885854054C644E8D8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_F25117E53F62F769FCF04054C6452C5A" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_F25117E53F62F769FCF04054C6452C5A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_55E3531C53B15E3E4F6C4054C645FA96" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_55E3531C53B15E3E4F6C4054C645FA96" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeTaxExpenseBenefit" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_3782E424A9E77BB451854054C645AFA5" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_3782E424A9E77BB451854054C645AFA5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ProfitLoss" xlink:label="loc_us-gaap_ProfitLoss_4FF72FC95EDCED9F0C9E4054C645B794" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_ProfitLoss_4FF72FC95EDCED9F0C9E4054C645B794" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_77C76F49CF1BCE463EC14054C6450F63" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_77C76F49CF1BCE463EC14054C6450F63" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_836E01C71D151BEC69A04054C645F9F6" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_NetIncomeLoss_836E01C71D151BEC69A04054C645F9F6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareBasicAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicAbstract_198A84861B1D398AD5044054C6468647" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_EarningsPerShareBasicAbstract_198A84861B1D398AD5044054C6468647" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_AAD5FB38F98A545C15DD4054C646C911" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicAbstract_198A84861B1D398AD5044054C6468647" xlink:to="loc_us-gaap_EarningsPerShareBasic_AAD5FB38F98A545C15DD4054C646C911" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareDilutedAbstract" xlink:label="loc_us-gaap_EarningsPerShareDilutedAbstract_0CB700B873881F5FE27B4054C6467E61" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_EarningsPerShareDilutedAbstract_0CB700B873881F5FE27B4054C6467E61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_E68A6AE47BE0C9DBC9D94054C646BB9F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedAbstract_0CB700B873881F5FE27B4054C6467E61" xlink:to="loc_us-gaap_EarningsPerShareDiluted_E68A6AE47BE0C9DBC9D94054C646BB9F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DividendsCommonStockAbstract" xlink:label="loc_us-gaap_DividendsCommonStockAbstract_9428D271E1EEBEFB49DA4054C646780A" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C140E322306739CE9A514054C643BD17" xlink:to="loc_us-gaap_DividendsCommonStockAbstract_9428D271E1EEBEFB49DA4054C646780A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_42F9ACDBCC7A1C434D424054C647EA3C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DividendsCommonStockAbstract_9428D271E1EEBEFB49DA4054C646780A" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_42F9ACDBCC7A1C434D424054C647EA3C" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquity" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_973F747824D9BE096D283451FA96B8A8" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_780007F00361AAABDFBD3451FA924CB9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_973F747824D9BE096D283451FA96B8A8" xlink:to="loc_us-gaap_StatementTable_780007F00361AAABDFBD3451FA924CB9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AdjustmentsForNewAccountingPronouncementsAxis" xlink:label="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7DEA82496AD880673D1A3451FA933C5D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_780007F00361AAABDFBD3451FA924CB9" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7DEA82496AD880673D1A3451FA933C5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_A8F3BFB15FF04F1A3B823451FA93C962_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7DEA82496AD880673D1A3451FA933C5D" xlink:to="loc_us-gaap_TypeOfAdoptionMember_A8F3BFB15FF04F1A3B823451FA93C962_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_A8F3BFB15FF04F1A3B823451FA93C962" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7DEA82496AD880673D1A3451FA933C5D" xlink:to="loc_us-gaap_TypeOfAdoptionMember_A8F3BFB15FF04F1A3B823451FA93C962" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccountingStandardsUpdate201602Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201602Member_299576A5820E3D1E5EE43451FA93175B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_A8F3BFB15FF04F1A3B823451FA93C962" xlink:to="loc_us-gaap_AccountingStandardsUpdate201602Member_299576A5820E3D1E5EE43451FA93175B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_640A4F0E3355FF0703943451FA9418B0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_780007F00361AAABDFBD3451FA924CB9" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_640A4F0E3355FF0703943451FA9418B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_640A4F0E3355FF0703943451FA9418B0" xlink:to="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_640A4F0E3355FF0703943451FA9418B0" xlink:to="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PreferredStockMember" xlink:label="loc_us-gaap_PreferredStockMember_C03B6F3EB6227128063B3451FA94EEF3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_PreferredStockMember_C03B6F3EB6227128063B3451FA94EEF3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_C03EA2F4657A01EBFC103451FA94E85B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_CommonStockMember_C03EA2F4657A01EBFC103451FA94E85B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AdditionalPaidInCapitalMember" xlink:label="loc_us-gaap_AdditionalPaidInCapitalMember_A4D9E94D17A85D00615F3451FA947E0B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_AdditionalPaidInCapitalMember_A4D9E94D17A85D00615F3451FA947E0B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_AAEF20417466675D61433451FA940688" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_RetainedEarningsMember_AAEF20417466675D61433451FA940688" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockMember" xlink:label="loc_us-gaap_TreasuryStockMember_5CF32AAB74B481C4073D3451FA95A1BC" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_TreasuryStockMember_5CF32AAB74B481C4073D3451FA95A1BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeMember" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_453E4D0541B66D33AFB23451FA959971" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_453E4D0541B66D33AFB23451FA959971" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_74CD0483E659EC145C9D3451FA955FAC" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_890418EC08880B4D92A73451FA940E18" xlink:to="loc_us-gaap_NoncontrollingInterestMember_74CD0483E659EC145C9D3451FA955FAC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_608E8AED2CF1D65EE3ED3451FA950B75" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_780007F00361AAABDFBD3451FA924CB9" xlink:to="loc_us-gaap_StatementClassOfStockAxis_608E8AED2CF1D65EE3ED3451FA950B75" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_4AE3950145C344FD05583451FA9618FE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_608E8AED2CF1D65EE3ED3451FA950B75" xlink:to="loc_us-gaap_ClassOfStockDomain_4AE3950145C344FD05583451FA9618FE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_4AE3950145C344FD05583451FA9618FE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_608E8AED2CF1D65EE3ED3451FA950B75" xlink:to="loc_us-gaap_ClassOfStockDomain_4AE3950145C344FD05583451FA9618FE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_C8B6C7185033806FE28B3451FA96D54A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_4AE3950145C344FD05583451FA9618FE" xlink:to="loc_us-gaap_CommonStockMember_C8B6C7185033806FE28B3451FA96D54A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_CB267FECAF89D9B38E983451FA96F41A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_4AE3950145C344FD05583451FA9618FE" xlink:to="loc_us-gaap_CommonClassBMember_CB267FECAF89D9B38E983451FA96F41A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncreaseDecreaseInStockholdersEquityRollForward" xlink:label="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_973F747824D9BE096D283451FA96B8A8" xlink:to="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_4E0BA010F1150BE96BD03451FA97080A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_4E0BA010F1150BE96BD03451FA97080A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_A00122628706318DB6203451FA978BBF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_NetIncomeLoss_A00122628706318DB6203451FA978BBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_FE61225172851AA86E823451FA971033" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_FE61225172851AA86E823451FA971033" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ProfitLoss" xlink:label="loc_us-gaap_ProfitLoss_D02C1C928645161927013451FA97866B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_ProfitLoss_D02C1C928645161927013451FA97866B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsNetOfTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsNetOfTax_579FA5B02C89205E6FED3451FA984BFC" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsNetOfTax_579FA5B02C89205E6FED3451FA984BFC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DividendsCommonStockAbstract" xlink:label="loc_us-gaap_DividendsCommonStockAbstract_90E4275F423F104982423451FA9865DF" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_DividendsCommonStockAbstract_90E4275F423F104982423451FA9865DF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DividendsCommonStockCash" xlink:label="loc_us-gaap_DividendsCommonStockCash_81E54C64E20CF76A422F3451FA98178D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DividendsCommonStockAbstract_90E4275F423F104982423451FA9865DF" xlink:to="loc_us-gaap_DividendsCommonStockCash_81E54C64E20CF76A422F3451FA98178D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueConversionOfConvertibleSecurities" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueConversionOfConvertibleSecurities_65DC1217D479C30736EA3451FA9871D4" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueConversionOfConvertibleSecurities_65DC1217D479C30736EA3451FA9871D4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue" xlink:label="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_851796774207A0C14C0D3451FA996D6C" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_851796774207A0C14C0D3451FA996D6C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_5ACCCB4291D30E354B653451FA998225" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_5ACCCB4291D30E354B653451FA998225" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockValueAcquiredCostMethod" xlink:label="loc_us-gaap_TreasuryStockValueAcquiredCostMethod_4301BBD5227CB25CC4193451FA99D58C" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_TreasuryStockValueAcquiredCostMethod_4301BBD5227CB25CC4193451FA99D58C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockRetiredCostMethodAmount" xlink:label="loc_us-gaap_TreasuryStockRetiredCostMethodAmount_D461ED8F9B53D552CD893451FA9981E8" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_TreasuryStockRetiredCostMethodAmount_D461ED8F9B53D552CD893451FA9981E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_8217BC6A8F90A2B35D093451FA99C763" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_8217BC6A8F90A2B35D093451FA99C763" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_TaxCutsandJobsActReclassificationFromAOCIToRetainedEarningsTaxEffect" xlink:label="loc_hsy_TaxCutsandJobsActReclassificationFromAOCIToRetainedEarningsTaxEffect_D7B4AF074848973BD8333451FA99F018" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_63531B0EE0CC83ED96D43451FA96134E" xlink:to="loc_hsy_TaxCutsandJobsActReclassificationFromAOCIToRetainedEarningsTaxEffect_D7B4AF074848973BD8333451FA99F018" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_B0408CEF865EB76F85DDD310C25DDB4C" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_8A977ED3D739A0A99659D310C25B61F5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_B0408CEF865EB76F85DDD310C25DDB4C" xlink:to="loc_us-gaap_StatementTable_8A977ED3D739A0A99659D310C25B61F5" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_BDCF9B6C2D0ADC53555DD310C25C4161" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_8A977ED3D739A0A99659D310C25B61F5" xlink:to="loc_us-gaap_StatementClassOfStockAxis_BDCF9B6C2D0ADC53555DD310C25C4161" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_DC801350A718224F093AD310C25CACC4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_BDCF9B6C2D0ADC53555DD310C25C4161" xlink:to="loc_us-gaap_ClassOfStockDomain_DC801350A718224F093AD310C25CACC4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_DC801350A718224F093AD310C25CACC4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_BDCF9B6C2D0ADC53555DD310C25C4161" xlink:to="loc_us-gaap_ClassOfStockDomain_DC801350A718224F093AD310C25CACC4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_F11743BC07DE94E49AC5D310C25C1555" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_DC801350A718224F093AD310C25CACC4" xlink:to="loc_us-gaap_CommonStockMember_F11743BC07DE94E49AC5D310C25C1555" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_E8E4DAEF62395D9CA5DFD310C25D04E0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_DC801350A718224F093AD310C25CACC4" xlink:to="loc_us-gaap_CommonClassBMember_E8E4DAEF62395D9CA5DFD310C25D04E0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_144C312002C7D97ADDDAD310C25DBA02" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B0408CEF865EB76F85DDD310C25DDB4C" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_144C312002C7D97ADDDAD310C25DBA02" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DerivativeInstruments" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DerivativeInstrumentsNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_350629257C5C1BE4021C3451F93725ED" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_350629257C5C1BE4021C3451F93725ED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_350629257C5C1BE4021C3451F93725ED" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_350629257C5C1BE4021C3451F93725ED" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_46D165039678160E594D3451F937020A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:to="loc_us-gaap_CommodityContractMember_46D165039678160E594D3451F937020A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_97D2B2709ED480929FA73451F9386CF4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:to="loc_us-gaap_ForeignExchangeContractMember_97D2B2709ED480929FA73451F9386CF4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_68B38E34B474D4D2550A3451F9380A3C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:to="loc_us-gaap_InterestRateContractMember_68B38E34B474D4D2550A3451F9380A3C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_2CD6A83CBDCFDD1F777D3451F9383528" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:to="loc_us-gaap_EquitySwapMember_2CD6A83CBDCFDD1F777D3451F9383528" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestRateSwapMember" xlink:label="loc_us-gaap_InterestRateSwapMember_695974D3E1CEEF4D11923451F938814C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_1BF53B77E2C40A8599813451F9370016" xlink:to="loc_us-gaap_InterestRateSwapMember_695974D3E1CEEF4D11923451F938814C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_8A3E348DBD0D8800FC373451F9394C80" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:to="loc_us-gaap_HedgingDesignationAxis_8A3E348DBD0D8800FC373451F9394C80" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_B317A209546CC8F258243451F939D813_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_8A3E348DBD0D8800FC373451F9394C80" xlink:to="loc_us-gaap_HedgingDesignationDomain_B317A209546CC8F258243451F939D813_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_B317A209546CC8F258243451F939D813" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_8A3E348DBD0D8800FC373451F9394C80" xlink:to="loc_us-gaap_HedgingDesignationDomain_B317A209546CC8F258243451F939D813" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_0A69AFD821C86D9D4F433451F939B677" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_B317A209546CC8F258243451F939D813" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_0A69AFD821C86D9D4F433451F939B677" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_439454A2612D4660538C3451F93937BC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_B317A209546CC8F258243451F939D813" xlink:to="loc_us-gaap_NondesignatedMember_439454A2612D4660538C3451F93937BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_7FBD70BAD160AB511D753451F93A7B1A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_7FBD70BAD160AB511D753451F93A7B1A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_80A054D02169B1B416763451F93A1AF2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_7FBD70BAD160AB511D753451F93A7B1A" xlink:to="loc_us-gaap_HedgingRelationshipDomain_80A054D02169B1B416763451F93A1AF2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_80A054D02169B1B416763451F93A1AF2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_7FBD70BAD160AB511D753451F93A7B1A" xlink:to="loc_us-gaap_HedgingRelationshipDomain_80A054D02169B1B416763451F93A1AF2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_A5F2760C1FFA344BB90B3451F93ABC5B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_80A054D02169B1B416763451F93A1AF2" xlink:to="loc_us-gaap_CashFlowHedgingMember_A5F2760C1FFA344BB90B3451F93ABC5B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_ED0A3EC6F8D8BB3F5A303451F93AC03F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_80A054D02169B1B416763451F93A1AF2" xlink:to="loc_us-gaap_FairValueHedgingMember_ED0A3EC6F8D8BB3F5A303451F93AC03F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_16A5C12F1DE362A5927E3451F93B923D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:to="loc_srt_RangeAxis_16A5C12F1DE362A5927E3451F93B923D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_DD2337EBDB7F5F5030763451F93B42B1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_16A5C12F1DE362A5927E3451F93B923D" xlink:to="loc_srt_RangeMember_DD2337EBDB7F5F5030763451F93B42B1_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_DD2337EBDB7F5F5030763451F93B42B1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_16A5C12F1DE362A5927E3451F93B923D" xlink:to="loc_srt_RangeMember_DD2337EBDB7F5F5030763451F93B42B1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_2B7805E894402FC2626E3451F93B92CB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_DD2337EBDB7F5F5030763451F93B42B1" xlink:to="loc_srt_MinimumMember_2B7805E894402FC2626E3451F93B92CB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_0B7CF2E45AC2BD1471B13451F93BDDA2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_DD2337EBDB7F5F5030763451F93B42B1" xlink:to="loc_srt_MaximumMember_0B7CF2E45AC2BD1471B13451F93BDDA2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_5126127A835A0F2691F93451F93C7BEB" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_7D3E642C09C61CCCE7F73451F937BDC6" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_5126127A835A0F2691F93451F93C7BEB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_380B62A87B63B49218F83451F93CDF00_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_5126127A835A0F2691F93451F93C7BEB" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_380B62A87B63B49218F83451F93CDF00_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_380B62A87B63B49218F83451F93CDF00" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_5126127A835A0F2691F93451F93C7BEB" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_380B62A87B63B49218F83451F93CDF00" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestExpenseMember" xlink:label="loc_us-gaap_InterestExpenseMember_EBB995A7B5C13B3FDD6D3451F93C6D4D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_380B62A87B63B49218F83451F93CDF00" xlink:to="loc_us-gaap_InterestExpenseMember_EBB995A7B5C13B3FDD6D3451F93C6D4D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeTermOfContract" xlink:label="loc_us-gaap_DerivativeTermOfContract_DFC839BFFDB5B4C95A453451F93D1C14" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_us-gaap_DerivativeTermOfContract_DFC839BFFDB5B4C95A453451F93D1C14" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeNotionalAmount" xlink:label="loc_us-gaap_DerivativeNotionalAmount_305E11BFBC4786AB60A43451F93DAD1F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_us-gaap_DerivativeNotionalAmount_305E11BFBC4786AB60A43451F93DAD1F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_MinimumLengthofTimeHedgedinCashFlowHedge" xlink:label="loc_hsy_MinimumLengthofTimeHedgedinCashFlowHedge_278CF4A5C4877031EABE3451F93D5E15" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_hsy_MinimumLengthofTimeHedgedinCashFlowHedge_278CF4A5C4877031EABE3451F93D5E15" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1" xlink:label="loc_us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1_32293375949BDD6513783451F93D3A5E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1_32293375949BDD6513783451F93D3A5E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths" xlink:label="loc_us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths_D1BBF4B835F53D00BB3A3451F93D01E9" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths_D1BBF4B835F53D00BB3A3451F93D01E9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1" xlink:label="loc_us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1_2FECB635A8887804770A3451F93E5E31" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_B492C2CDC7F66FBEBE913451F93C0006" xlink:to="loc_us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1_2FECB635A8887804770A3451F93E5E31" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativesFairValueLineItems" xlink:label="loc_us-gaap_DerivativesFairValueLineItems_F66993DB000DB7D39128D747D4E4DA47" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable" xlink:label="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1BC33BAD3CE643477D4FD747D4D9C6E5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_F66993DB000DB7D39128D747D4E4DA47" xlink:to="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1BC33BAD3CE643477D4FD747D4D9C6E5" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_016D41B4A2E39591DACED747D4D9BB7B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1BC33BAD3CE643477D4FD747D4D9C6E5" xlink:to="loc_us-gaap_HedgingDesignationAxis_016D41B4A2E39591DACED747D4D9BB7B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_AE9A7A68F5C9B019A973D747D4DAB04B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_016D41B4A2E39591DACED747D4D9BB7B" xlink:to="loc_us-gaap_HedgingDesignationDomain_AE9A7A68F5C9B019A973D747D4DAB04B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_AE9A7A68F5C9B019A973D747D4DAB04B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_016D41B4A2E39591DACED747D4D9BB7B" xlink:to="loc_us-gaap_HedgingDesignationDomain_AE9A7A68F5C9B019A973D747D4DAB04B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_E5CDC015DF5D365DF716D747D4DA9DC2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_AE9A7A68F5C9B019A973D747D4DAB04B" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_E5CDC015DF5D365DF716D747D4DA9DC2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_6568CAB1CEA415A29B9BD747D4DAFEE7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_AE9A7A68F5C9B019A973D747D4DAB04B" xlink:to="loc_us-gaap_NondesignatedMember_6568CAB1CEA415A29B9BD747D4DAFEE7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B0873F115EB030CADE69D747D4DB972A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1BC33BAD3CE643477D4FD747D4D9C6E5" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B0873F115EB030CADE69D747D4DB972A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_068894085E554E90E366D747D4DBAE9A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B0873F115EB030CADE69D747D4DB972A" xlink:to="loc_us-gaap_HedgingRelationshipDomain_068894085E554E90E366D747D4DBAE9A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_068894085E554E90E366D747D4DBAE9A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B0873F115EB030CADE69D747D4DB972A" xlink:to="loc_us-gaap_HedgingRelationshipDomain_068894085E554E90E366D747D4DBAE9A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_FE9EFFAB1AD96B462A77D747D4DBFF0E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_068894085E554E90E366D747D4DBAE9A" xlink:to="loc_us-gaap_CashFlowHedgingMember_FE9EFFAB1AD96B462A77D747D4DBFF0E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_F7E95861A93002080F50D747D4DBE8C4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_068894085E554E90E366D747D4DBAE9A" xlink:to="loc_us-gaap_FairValueHedgingMember_F7E95861A93002080F50D747D4DBE8C4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_3A390AE200384CD13544D747D4DB559C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1BC33BAD3CE643477D4FD747D4D9C6E5" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_3A390AE200384CD13544D747D4DB559C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_3A390AE200384CD13544D747D4DB559C" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_3A390AE200384CD13544D747D4DB559C" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_1D2148FFBA57C07F5008D747D4E3197B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6" xlink:to="loc_us-gaap_CommodityContractMember_1D2148FFBA57C07F5008D747D4E3197B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_7E93A163D1CECB5266C5D747D4E301A7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6" xlink:to="loc_us-gaap_ForeignExchangeContractMember_7E93A163D1CECB5266C5D747D4E301A7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_75C9CE407CED363E693AD747D4E38E57" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6" xlink:to="loc_us-gaap_InterestRateContractMember_75C9CE407CED363E693AD747D4E38E57" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_5316EC7A2513714B458DD747D4E4D97B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_B06BF7A18F5927AF6D4BD747D4E20DB6" xlink:to="loc_us-gaap_EquitySwapMember_5316EC7A2513714B458DD747D4E4D97B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_A56CEEEF64AD15BFA978D747D4E42B31" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_F66993DB000DB7D39128D747D4E4DA47" xlink:to="loc_us-gaap_DerivativeAssets_A56CEEEF64AD15BFA978D747D4E42B31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_63105DA9C0475940AF58D747D4E51ACF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_F66993DB000DB7D39128D747D4E4DA47" xlink:to="loc_us-gaap_DerivativeLiabilities_63105DA9C0475940AF58D747D4E51ACF" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading" xlink:label="loc_hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_E3ED9A7C10C8B375A89CD747D4E57106" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_F66993DB000DB7D39128D747D4E4DA47" xlink:to="loc_hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_E3ED9A7C10C8B375A89CD747D4E57106" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading" xlink:label="loc_hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_57321C9FB36BBDF7EA18D747D4E5A53E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_F66993DB000DB7D39128D747D4E4DA47" xlink:to="loc_hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_57321C9FB36BBDF7EA18D747D4E5A53E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfCumulativeBasisAdjustmentsForInterestRateSwapDerivativesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_2BADCAF8A950876B0CC3D452D796613E" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_32165C09621FF519A0E3D452D786D35F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_2BADCAF8A950876B0CC3D452D796613E" xlink:to="loc_us-gaap_DerivativeTable_32165C09621FF519A0E3D452D786D35F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_40B81AA576D894C9423AD452D81F8862" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_32165C09621FF519A0E3D452D786D35F" xlink:to="loc_us-gaap_HedgingDesignationAxis_40B81AA576D894C9423AD452D81F8862" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_90398BA977CBE369EDD0D452D81F7583_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_40B81AA576D894C9423AD452D81F8862" xlink:to="loc_us-gaap_HedgingDesignationDomain_90398BA977CBE369EDD0D452D81F7583_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_90398BA977CBE369EDD0D452D81F7583" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_40B81AA576D894C9423AD452D81F8862" xlink:to="loc_us-gaap_HedgingDesignationDomain_90398BA977CBE369EDD0D452D81F7583" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_06C234F0752E3449A929D452D874BF6A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_90398BA977CBE369EDD0D452D81F7583" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_06C234F0752E3449A929D452D874BF6A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_47634987040B6E6BC1E4D452D7EA3BBD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_32165C09621FF519A0E3D452D786D35F" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_47634987040B6E6BC1E4D452D7EA3BBD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_62659A9CE2F542D58BE4D452D7EA1D9D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_47634987040B6E6BC1E4D452D7EA3BBD" xlink:to="loc_us-gaap_HedgingRelationshipDomain_62659A9CE2F542D58BE4D452D7EA1D9D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_62659A9CE2F542D58BE4D452D7EA1D9D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_47634987040B6E6BC1E4D452D7EA3BBD" xlink:to="loc_us-gaap_HedgingRelationshipDomain_62659A9CE2F542D58BE4D452D7EA1D9D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_91FB7FC589762FC10664D452D886B0BD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_62659A9CE2F542D58BE4D452D7EA1D9D" xlink:to="loc_us-gaap_FairValueHedgingMember_91FB7FC589762FC10664D452D886B0BD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_89C2EFC1AE29AF9B1EC4D452D786A17E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_32165C09621FF519A0E3D452D786D35F" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_89C2EFC1AE29AF9B1EC4D452D786A17E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_CBD62307A2E7F2F38C5CD452D7861939_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_89C2EFC1AE29AF9B1EC4D452D786A17E" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_CBD62307A2E7F2F38C5CD452D7861939_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_CBD62307A2E7F2F38C5CD452D7861939" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_89C2EFC1AE29AF9B1EC4D452D786A17E" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_CBD62307A2E7F2F38C5CD452D7861939" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestRateSwapMember" xlink:label="loc_us-gaap_InterestRateSwapMember_8FFC6360CAD3EAEBBF29D452D858D39F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_CBD62307A2E7F2F38C5CD452D7861939" xlink:to="loc_us-gaap_InterestRateSwapMember_8FFC6360CAD3EAEBBF29D452D858D39F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeFairValueOfDerivativeNet" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeNet_352A492D7F5666D8DEEAD452D7ABC102" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_2BADCAF8A950876B0CC3D452D796613E" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeNet_352A492D7F5666D8DEEAD452D7ABC102" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_97FABAA9EEDE6A456B70D452D7CBF74E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_2BADCAF8A950876B0CC3D452D796613E" xlink:to="loc_us-gaap_DerivativeAssets_97FABAA9EEDE6A456B70D452D7CBF74E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_76B6FD5782C4534475EED452D7DAB0B6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_2BADCAF8A950876B0CC3D452D796613E" xlink:to="loc_us-gaap_DerivativeLiabilities_76B6FD5782C4534475EED452D7DAB0B6" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_925B72D0AD3430D96BB2D4071D31B1C2" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_ECE6FBEA29A9EFE51D59D4071D2E47F3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_925B72D0AD3430D96BB2D4071D31B1C2" xlink:to="loc_us-gaap_DerivativeTable_ECE6FBEA29A9EFE51D59D4071D2E47F3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_3A0E946413434AE9C318D4071D2ED214" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_ECE6FBEA29A9EFE51D59D4071D2E47F3" xlink:to="loc_us-gaap_HedgingDesignationAxis_3A0E946413434AE9C318D4071D2ED214" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_D3409EA41D41942892F4D4071D2E4EBA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_3A0E946413434AE9C318D4071D2ED214" xlink:to="loc_us-gaap_HedgingDesignationDomain_D3409EA41D41942892F4D4071D2E4EBA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_D3409EA41D41942892F4D4071D2E4EBA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_3A0E946413434AE9C318D4071D2ED214" xlink:to="loc_us-gaap_HedgingDesignationDomain_D3409EA41D41942892F4D4071D2E4EBA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_E99027637A2ED235B907D4071D2E9CBA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_D3409EA41D41942892F4D4071D2E4EBA" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_E99027637A2ED235B907D4071D2E9CBA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_337D751422E72403D19DD4071D2F5C72" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_ECE6FBEA29A9EFE51D59D4071D2E47F3" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_337D751422E72403D19DD4071D2F5C72" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_5BF2C1837564E4D78B61D4071D2FAC15_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_337D751422E72403D19DD4071D2F5C72" xlink:to="loc_us-gaap_HedgingRelationshipDomain_5BF2C1837564E4D78B61D4071D2FAC15_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_5BF2C1837564E4D78B61D4071D2FAC15" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_337D751422E72403D19DD4071D2F5C72" xlink:to="loc_us-gaap_HedgingRelationshipDomain_5BF2C1837564E4D78B61D4071D2FAC15" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_1C976BF1CDA0678001D3D4071D2F4D61" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_5BF2C1837564E4D78B61D4071D2FAC15" xlink:to="loc_us-gaap_CashFlowHedgingMember_1C976BF1CDA0678001D3D4071D2F4D61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_A46DE874D40D719B33A6D4071D2F8B0B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_ECE6FBEA29A9EFE51D59D4071D2E47F3" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_A46DE874D40D719B33A6D4071D2F8B0B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_A46DE874D40D719B33A6D4071D2F8B0B" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_A46DE874D40D719B33A6D4071D2F8B0B" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_1ED9799877CB0F93617AD4071D30A143" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232" xlink:to="loc_us-gaap_CommodityContractMember_1ED9799877CB0F93617AD4071D30A143" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_9CBA990FD3E570BED973D4071D306FD0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232" xlink:to="loc_us-gaap_ForeignExchangeContractMember_9CBA990FD3E570BED973D4071D306FD0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_B038706E3E11A5AE7AFAD4071D308E9D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232" xlink:to="loc_us-gaap_InterestRateContractMember_B038706E3E11A5AE7AFAD4071D308E9D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_1B417EEBB642E78E8AF8D4071D306984" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_39FDEB9E9D0377A91485D4071D308232" xlink:to="loc_us-gaap_EquitySwapMember_1B417EEBB642E78E8AF8D4071D306984" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet" xlink:label="loc_us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet_262EBD06E806EFBA034BD4071D319EF9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_925B72D0AD3430D96BB2D4071D31B1C2" xlink:to="loc_us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet_262EBD06E806EFBA034BD4071D319EF9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax_8C72558C5C6549398BBFD4071D314AA5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_925B72D0AD3430D96BB2D4071D31B1C2" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAndTax_8C72558C5C6549398BBFD4071D314AA5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax" xlink:label="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax_0E7F3C6AAD192CFE7B3ED44ACFDF1CF4" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_925B72D0AD3430D96BB2D4071D31B1C2" xlink:to="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax_0E7F3C6AAD192CFE7B3ED44ACFDF1CF4" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DerivativeInstrumentsTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/DocumentAndEntityInformationDocument" xlink:type="extended">
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityInformationLineItems" xlink:label="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:type="locator" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntitiesTable" xlink:label="loc_dei_EntitiesTable_58664567E718A5CA50872038D89D2A34" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntitiesTable_58664567E718A5CA50872038D89D2A34" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_BEE28CA548678D5076DD2038D89EE061" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_dei_EntitiesTable_58664567E718A5CA50872038D89D2A34" xlink:to="loc_us-gaap_StatementClassOfStockAxis_BEE28CA548678D5076DD2038D89EE061" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_454DB9110CF85AF841BF2038D89EE6BA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_BEE28CA548678D5076DD2038D89EE061" xlink:to="loc_us-gaap_ClassOfStockDomain_454DB9110CF85AF841BF2038D89EE6BA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_454DB9110CF85AF841BF2038D89EE6BA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_BEE28CA548678D5076DD2038D89EE061" xlink:to="loc_us-gaap_ClassOfStockDomain_454DB9110CF85AF841BF2038D89EE6BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_31FF051E35711412B28A2038D89F7B71" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_454DB9110CF85AF841BF2038D89EE6BA" xlink:to="loc_us-gaap_CommonStockMember_31FF051E35711412B28A2038D89F7B71" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_2C2F19C27DF6AE8868752038D89F8B40" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_454DB9110CF85AF841BF2038D89EE6BA" xlink:to="loc_us-gaap_CommonClassBMember_2C2F19C27DF6AE8868752038D89F8B40" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_DocumentType" xlink:label="loc_dei_DocumentType_E17473C63DEBF3E8DCFF2038D8A0FAC4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_DocumentType_E17473C63DEBF3E8DCFF2038D8A0FAC4" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_DocumentAnnualReport" xlink:label="loc_dei_DocumentAnnualReport_12C6F8F0376F392A42502038D8A04595" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_DocumentAnnualReport_12C6F8F0376F392A42502038D8A04595" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_DocumentPeriodEndDate" xlink:label="loc_dei_DocumentPeriodEndDate_EA635E74ADAB6C5951192038D8A06D23" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_DocumentPeriodEndDate_EA635E74ADAB6C5951192038D8A06D23" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_DocumentTransitionReport" xlink:label="loc_dei_DocumentTransitionReport_CF11C861CBE2A18CC5AD2038D8A04029" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_DocumentTransitionReport_CF11C861CBE2A18CC5AD2038D8A04029" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityFileNumber" xlink:label="loc_dei_EntityFileNumber_1EC3836635307AF659502038D8A0D27C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityFileNumber_1EC3836635307AF659502038D8A0D27C" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityRegistrantName" xlink:label="loc_dei_EntityRegistrantName_4F927C3124B93B64289B2038D8A1500F" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityRegistrantName_4F927C3124B93B64289B2038D8A1500F" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityIncorporationStateCountryCode" xlink:label="loc_dei_EntityIncorporationStateCountryCode_14CFB0CA033491537ABC2038D8A107E4" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityIncorporationStateCountryCode_14CFB0CA033491537ABC2038D8A107E4" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityTaxIdentificationNumber" xlink:label="loc_dei_EntityTaxIdentificationNumber_F5D0F0F7F362767F3A662038D8A1218B" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityTaxIdentificationNumber_F5D0F0F7F362767F3A662038D8A1218B" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityAddressAddressLine1" xlink:label="loc_dei_EntityAddressAddressLine1_4F31D5A78D6E234853D32038D8A1D9CE" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityAddressAddressLine1_4F31D5A78D6E234853D32038D8A1D9CE" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityAddressCityOrTown" xlink:label="loc_dei_EntityAddressCityOrTown_C43FC8DFF70144F4400F2038D8A17B7E" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityAddressCityOrTown_C43FC8DFF70144F4400F2038D8A17B7E" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityAddressStateOrProvince" xlink:label="loc_dei_EntityAddressStateOrProvince_3695707956889FE6CB362038D8A25F81" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityAddressStateOrProvince_3695707956889FE6CB362038D8A25F81" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityAddressPostalZipCode" xlink:label="loc_dei_EntityAddressPostalZipCode_DEF4C264A80C94F4B7152038D8A25AF7" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityAddressPostalZipCode_DEF4C264A80C94F4B7152038D8A25AF7" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_CityAreaCode" xlink:label="loc_dei_CityAreaCode_ECF24B6F4AFB6B1C2D5B2038D8A2415F" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_CityAreaCode_ECF24B6F4AFB6B1C2D5B2038D8A2415F" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_LocalPhoneNumber" xlink:label="loc_dei_LocalPhoneNumber_FFE48BEC472B30786A202038D8A2EB8A" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_LocalPhoneNumber_FFE48BEC472B30786A202038D8A2EB8A" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_Security12bTitle" xlink:label="loc_dei_Security12bTitle_F00D50090E0547FA61D42038D8A2B431" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_Security12bTitle_F00D50090E0547FA61D42038D8A2B431" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_TradingSymbol" xlink:label="loc_dei_TradingSymbol_570D9DA626247C1850602038D8A24A9A" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_TradingSymbol_570D9DA626247C1850602038D8A24A9A" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_SecurityExchangeName" xlink:label="loc_dei_SecurityExchangeName_007DCF83DD7A3BA71ED52038D8A34885" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_SecurityExchangeName_007DCF83DD7A3BA71ED52038D8A34885" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityWellKnownSeasonedIssuer" xlink:label="loc_dei_EntityWellKnownSeasonedIssuer_E6BE08356822370D58782038D8A39FDF" xlink:type="locator" />
    <link:definitionArc order="18" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityWellKnownSeasonedIssuer_E6BE08356822370D58782038D8A39FDF" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityVoluntaryFilers" xlink:label="loc_dei_EntityVoluntaryFilers_5B7505F8B5A0B5D2E9452038D8A3715A" xlink:type="locator" />
    <link:definitionArc order="19" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityVoluntaryFilers_5B7505F8B5A0B5D2E9452038D8A3715A" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityCurrentReportingStatus" xlink:label="loc_dei_EntityCurrentReportingStatus_1C642C72A749ED7623A12038D8A3FEC0" xlink:type="locator" />
    <link:definitionArc order="20" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityCurrentReportingStatus_1C642C72A749ED7623A12038D8A3FEC0" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityInteractiveDataCurrent" xlink:label="loc_dei_EntityInteractiveDataCurrent_F35110C61DF50F912A992038D8A34856" xlink:type="locator" />
    <link:definitionArc order="21" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityInteractiveDataCurrent_F35110C61DF50F912A992038D8A34856" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityFilerCategory" xlink:label="loc_dei_EntityFilerCategory_AA6F5EC48C2C26CF5EED2038D8A3D50F" xlink:type="locator" />
    <link:definitionArc order="22" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityFilerCategory_AA6F5EC48C2C26CF5EED2038D8A3D50F" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntitySmallBusiness" xlink:label="loc_dei_EntitySmallBusiness_615BCFC09FBF4560B5CE2038D8A9CC01" xlink:type="locator" />
    <link:definitionArc order="23" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntitySmallBusiness_615BCFC09FBF4560B5CE2038D8A9CC01" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityEmergingGrowthCompany" xlink:label="loc_dei_EntityEmergingGrowthCompany_7E1E8975A108C68F34422038D8A9B0D7" xlink:type="locator" />
    <link:definitionArc order="24" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityEmergingGrowthCompany_7E1E8975A108C68F34422038D8A9B0D7" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityShellCompany" xlink:label="loc_dei_EntityShellCompany_5FA0D51035F9A1D4BB3F2038D8A9485D" xlink:type="locator" />
    <link:definitionArc order="25" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityShellCompany_5FA0D51035F9A1D4BB3F2038D8A9485D" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityPublicFloat" xlink:label="loc_dei_EntityPublicFloat_0AE258A34B12061AFE482038D8A9020A" xlink:type="locator" />
    <link:definitionArc order="26" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityPublicFloat_0AE258A34B12061AFE482038D8A9020A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_F068E1D54D8CB01791ED2038D8A98B49" xlink:type="locator" />
    <link:definitionArc order="27" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_us-gaap_SharePrice_F068E1D54D8CB01791ED2038D8A98B49" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityCommonStockSharesOutstanding" xlink:label="loc_dei_EntityCommonStockSharesOutstanding_7782F43C614FD130CF2A2038D8AA86AA" xlink:type="locator" />
    <link:definitionArc order="28" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityCommonStockSharesOutstanding_7782F43C614FD130CF2A2038D8AA86AA" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityCentralIndexKey" xlink:label="loc_dei_EntityCentralIndexKey_F7839CE85F248EBF9B7B2038D8AA5379" xlink:type="locator" />
    <link:definitionArc order="29" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_EntityCentralIndexKey_F7839CE85F248EBF9B7B2038D8AA5379" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_DocumentFiscalYearFocus" xlink:label="loc_dei_DocumentFiscalYearFocus_C4A4DCFAF3CCE83876972038D8AA27F8" xlink:type="locator" />
    <link:definitionArc order="30" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_DocumentFiscalYearFocus_C4A4DCFAF3CCE83876972038D8AA27F8" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_CurrentFiscalYearEndDate" xlink:label="loc_dei_CurrentFiscalYearEndDate_4595E3EE935699946E762038D8AA0D25" xlink:type="locator" />
    <link:definitionArc order="31" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_CurrentFiscalYearEndDate_4595E3EE935699946E762038D8AA0D25" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_DocumentFiscalPeriodFocus" xlink:label="loc_dei_DocumentFiscalPeriodFocus_5278637AEC10B0C1FFCC2038D8AAD530" xlink:type="locator" />
    <link:definitionArc order="32" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_DocumentFiscalPeriodFocus_5278637AEC10B0C1FFCC2038D8AAD530" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_AmendmentFlag" xlink:label="loc_dei_AmendmentFlag_99AB9629B838F6FDE0342038D8AA13F9" xlink:type="locator" />
    <link:definitionArc order="33" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityInformationLineItems_B31B72439C9A1E3698F12038D89F4E0B" xlink:to="loc_dei_AmendmentFlag_99AB9629B838F6FDE0342038D8AA13F9" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EarningsPerShare" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EarningsPerShareEarningsPerShareNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_ED1CAA9A0C416ADD95AAAD1BBB39ADE2" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable" xlink:label="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_597512CC14BE4E0FAA7DAD1BBB383AD2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_ED1CAA9A0C416ADD95AAAD1BBB39ADE2" xlink:to="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_597512CC14BE4E0FAA7DAD1BBB383AD2" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_93D9A7AE1DA6157712F4AD1BBB381540" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_597512CC14BE4E0FAA7DAD1BBB383AD2" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_93D9A7AE1DA6157712F4AD1BBB381540" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AntidilutiveSecuritiesNameDomain" xlink:label="loc_us-gaap_AntidilutiveSecuritiesNameDomain_EB821AE71FCE5BBC7E7CAD1BBB39C9A3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_93D9A7AE1DA6157712F4AD1BBB381540" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_EB821AE71FCE5BBC7E7CAD1BBB39C9A3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AntidilutiveSecuritiesNameDomain" xlink:label="loc_us-gaap_AntidilutiveSecuritiesNameDomain_EB821AE71FCE5BBC7E7CAD1BBB39C9A3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_93D9A7AE1DA6157712F4AD1BBB381540" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_EB821AE71FCE5BBC7E7CAD1BBB39C9A3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_E03A3EDF3C251B99A78BAD1BBB391E61" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_EB821AE71FCE5BBC7E7CAD1BBB39C9A3" xlink:to="loc_us-gaap_EmployeeStockOptionMember_E03A3EDF3C251B99A78BAD1BBB391E61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_1EFF8A1DC1F5FB855B25AD1BBB39677A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_ED1CAA9A0C416ADD95AAAD1BBB39ADE2" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_1EFF8A1DC1F5FB855B25AD1BBB39677A" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EarningsPerShareScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareBasicLineItems" xlink:label="loc_us-gaap_EarningsPerShareBasicLineItems_6E85541F32F057F1328F0C3B42021213" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable" xlink:label="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_9D60A4C95F44ABF772F10C3B4200418A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_6E85541F32F057F1328F0C3B42021213" xlink:to="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_9D60A4C95F44ABF772F10C3B4200418A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_013893F49A4967FCD5A10C3B4201040D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_9D60A4C95F44ABF772F10C3B4200418A" xlink:to="loc_us-gaap_StatementClassOfStockAxis_013893F49A4967FCD5A10C3B4201040D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_52DD15FF1C22276EF7550C3B420105E8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_013893F49A4967FCD5A10C3B4201040D" xlink:to="loc_us-gaap_ClassOfStockDomain_52DD15FF1C22276EF7550C3B420105E8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_52DD15FF1C22276EF7550C3B420105E8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_013893F49A4967FCD5A10C3B4201040D" xlink:to="loc_us-gaap_ClassOfStockDomain_52DD15FF1C22276EF7550C3B420105E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_00FCBA7177F682D504990C3B4201EE68" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_52DD15FF1C22276EF7550C3B420105E8" xlink:to="loc_us-gaap_CommonStockMember_00FCBA7177F682D504990C3B4201EE68" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_FE44B83D95DAD8CDD0D60C3B4201D23F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_52DD15FF1C22276EF7550C3B420105E8" xlink:to="loc_us-gaap_CommonClassBMember_FE44B83D95DAD8CDD0D60C3B4201D23F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_D1617F1B698BFDC4A4A90C3B4201C0F1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_9D60A4C95F44ABF772F10C3B4200418A" xlink:to="loc_us-gaap_AwardTypeAxis_D1617F1B698BFDC4A4A90C3B4201C0F1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87DD0F37D6A00AB9AC620C3B420251C7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_D1617F1B698BFDC4A4A90C3B4201C0F1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87DD0F37D6A00AB9AC620C3B420251C7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87DD0F37D6A00AB9AC620C3B420251C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_D1617F1B698BFDC4A4A90C3B4201C0F1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87DD0F37D6A00AB9AC620C3B420251C7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_250F7740FB878BF9B1A80C3B4202F8F9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87DD0F37D6A00AB9AC620C3B420251C7" xlink:to="loc_us-gaap_EmployeeStockOptionMember_250F7740FB878BF9B1A80C3B4202F8F9" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_D2757D25A29145E1D1AA0C3B42020CEC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87DD0F37D6A00AB9AC620C3B420251C7" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_D2757D25A29145E1D1AA0C3B42020CEC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareBasicTwoClassMethodAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_6E85541F32F057F1328F0C3B42021213" xlink:to="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Dividends" xlink:label="loc_us-gaap_Dividends_21ED01722CE8347CE9C20C3B420337D9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:to="loc_us-gaap_Dividends_21ED01722CE8347CE9C20C3B420337D9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_2D6E09575502BF4D2AE40C3B420363BC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_2D6E09575502BF4D2AE40C3B420363BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_7DA840E1B4C6EDE5F1AE0C3B420394A9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_7DA840E1B4C6EDE5F1AE0C3B420394A9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingBasic" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_3E33EB0F11373E1A941F0C3B4203E649" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_3E33EB0F11373E1A941F0C3B4203E649" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_BE66B8C08DADEC45CC7F0C3B42040000" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_3A255089FD2C3E99501C0C3B42021D96" xlink:to="loc_us-gaap_EarningsPerShareBasic_BE66B8C08DADEC45CC7F0C3B42040000" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract" xlink:label="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_6E85541F32F057F1328F0C3B42021213" xlink:to="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DistributedEarnings" xlink:label="loc_us-gaap_DistributedEarnings_DCA2B6C660AB99A5518A0C3B4204E3CC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_us-gaap_DistributedEarnings_DCA2B6C660AB99A5518A0C3B4204E3CC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_5463ACFC1F35105402580C3B42041AED" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_5463ACFC1F35105402580C3B42041AED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_04734736E44668D1B9E30C3B42054195" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_04734736E44668D1B9E30C3B42054195" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock" xlink:label="loc_hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock_FCA0B67ED7B0B8C735260C3B42056F93" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock_FCA0B67ED7B0B8C735260C3B42056F93" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements" xlink:label="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_D4FD384F275298B0075E0C3B420560CC" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_D4FD384F275298B0075E0C3B420560CC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding" xlink:label="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_D401E5C84F0FCF4CB1120C3B420557B8" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_D401E5C84F0FCF4CB1120C3B420557B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_D3C893780FAB40EE7F720C3B4205423E" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_72600940CE3865EEECF50C3B4204802A" xlink:to="loc_us-gaap_EarningsPerShareDiluted_D3C893780FAB40EE7F720C3B4205423E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EarningsPerShareTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EquityAndNoncontrollingInterest" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_415073E3CA796052D806DDBC7F2AB14C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:to="loc_us-gaap_AwardTypeAxis_415073E3CA796052D806DDBC7F2AB14C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_6E97773DA948867DDA6CDDBC7F2B631A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_415073E3CA796052D806DDBC7F2AB14C" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_6E97773DA948867DDA6CDDBC7F2B631A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_6E97773DA948867DDA6CDDBC7F2B631A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_415073E3CA796052D806DDBC7F2AB14C" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_6E97773DA948867DDA6CDDBC7F2B631A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_AE31479DD7B1FD14D99FDDBC7F2BC2D1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_6E97773DA948867DDA6CDDBC7F2B631A" xlink:to="loc_hsy_HersheyTrustCompanyMember_AE31479DD7B1FD14D99FDDBC7F2BC2D1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_A0ECB254FE09AC3B3C82DDBC7F2BF1B0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:to="loc_us-gaap_StatementClassOfStockAxis_A0ECB254FE09AC3B3C82DDBC7F2BF1B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_64035113630EF32B12E3DDBC7F2BFA75_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_A0ECB254FE09AC3B3C82DDBC7F2BF1B0" xlink:to="loc_us-gaap_ClassOfStockDomain_64035113630EF32B12E3DDBC7F2BFA75_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_64035113630EF32B12E3DDBC7F2BFA75" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_A0ECB254FE09AC3B3C82DDBC7F2BF1B0" xlink:to="loc_us-gaap_ClassOfStockDomain_64035113630EF32B12E3DDBC7F2BFA75" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_6AB3675672AA85ECEF45DDBC7F2CCE47" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_64035113630EF32B12E3DDBC7F2BFA75" xlink:to="loc_us-gaap_CommonStockMember_6AB3675672AA85ECEF45DDBC7F2CCE47" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_F8C779550407C4174D7DDDBC7F2CBEE8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_64035113630EF32B12E3DDBC7F2BFA75" xlink:to="loc_us-gaap_CommonClassBMember_F8C779550407C4174D7DDDBC7F2CBEE8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_CounterpartyNameAxis" xlink:label="loc_srt_CounterpartyNameAxis_8D082DD61B6F530F72B2DDBC7F2CD8D5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:to="loc_srt_CounterpartyNameAxis_8D082DD61B6F530F72B2DDBC7F2CD8D5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RepurchaseAgreementCounterpartyNameDomain" xlink:label="loc_srt_RepurchaseAgreementCounterpartyNameDomain_B9720CFB3011FECEE1A6DDBC7F2CCA6C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_CounterpartyNameAxis_8D082DD61B6F530F72B2DDBC7F2CD8D5" xlink:to="loc_srt_RepurchaseAgreementCounterpartyNameDomain_B9720CFB3011FECEE1A6DDBC7F2CCA6C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RepurchaseAgreementCounterpartyNameDomain" xlink:label="loc_srt_RepurchaseAgreementCounterpartyNameDomain_B9720CFB3011FECEE1A6DDBC7F2CCA6C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_CounterpartyNameAxis_8D082DD61B6F530F72B2DDBC7F2CD8D5" xlink:to="loc_srt_RepurchaseAgreementCounterpartyNameDomain_B9720CFB3011FECEE1A6DDBC7F2CCA6C" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_91D9739DAF9DCB34B90FDDBC7F2C1996" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RepurchaseAgreementCounterpartyNameDomain_B9720CFB3011FECEE1A6DDBC7F2CCA6C" xlink:to="loc_hsy_HersheyTrustCompanyMember_91D9739DAF9DCB34B90FDDBC7F2C1996" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_995DF83A2853D69B4C44DDBC7F2D51C4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_995DF83A2853D69B4C44DDBC7F2D51C4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_995DF83A2853D69B4C44DDBC7F2D51C4" xlink:to="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_995DF83A2853D69B4C44DDBC7F2D51C4" xlink:to="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockMember" xlink:label="loc_us-gaap_TreasuryStockMember_0C79DB5A7C6140BC44DADDDC1D296B23" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1" xlink:to="loc_us-gaap_TreasuryStockMember_0C79DB5A7C6140BC44DADDDC1D296B23" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_F75FA2DBFF11204D9267DDDC1D6FCCFD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1" xlink:to="loc_us-gaap_RetainedEarningsMember_F75FA2DBFF11204D9267DDDC1D6FCCFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_64EBADCB241966B47809DDBC7F2D8000" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_939DFAB23038A70C7A48DDBC7F2D07F1" xlink:to="loc_us-gaap_NoncontrollingInterestMember_64EBADCB241966B47809DDBC7F2D8000" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_LegalEntityAxis" xlink:label="loc_dei_LegalEntityAxis_5069D0207899C3D77057DDBC7F2DEFAA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_059DC0843158404A79CDDDBC7F2A5461" xlink:to="loc_dei_LegalEntityAxis_5069D0207899C3D77057DDBC7F2DEFAA" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_0E24A6A537A342646C42DDBC7F2ED68E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_dei_LegalEntityAxis_5069D0207899C3D77057DDBC7F2DEFAA" xlink:to="loc_dei_EntityDomain_0E24A6A537A342646C42DDBC7F2ED68E_default" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2019/dei-2019-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_0E24A6A537A342646C42DDBC7F2ED68E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_dei_LegalEntityAxis_5069D0207899C3D77057DDBC7F2DEFAA" xlink:to="loc_dei_EntityDomain_0E24A6A537A342646C42DDBC7F2ED68E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_LotteShanghaiFoodCompanyMember" xlink:label="loc_hsy_LotteShanghaiFoodCompanyMember_4AA585FAE0D24107C081DDBC7F2E99E8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityDomain_0E24A6A537A342646C42DDBC7F2ED68E" xlink:to="loc_hsy_LotteShanghaiFoodCompanyMember_4AA585FAE0D24107C081DDBC7F2E99E8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CommonandPreferredStockSharesAuthorized" xlink:label="loc_hsy_CommonandPreferredStockSharesAuthorized_C5C2E8898375ABF134FDDDBC7F2ED345" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_hsy_CommonandPreferredStockSharesAuthorized_C5C2E8898375ABF134FDDDBC7F2ED345" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockSharesAuthorized" xlink:label="loc_us-gaap_CommonStockSharesAuthorized_1762A05ADE465C173271DDBC7F2F49BA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_CommonStockSharesAuthorized_1762A05ADE465C173271DDBC7F2F49BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PreferredStockSharesAuthorized" xlink:label="loc_us-gaap_PreferredStockSharesAuthorized_208F05256FAA409A9510DDBC7F2F24B6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_PreferredStockSharesAuthorized_208F05256FAA409A9510DDBC7F2F24B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockParOrStatedValuePerShare" xlink:label="loc_us-gaap_CommonStockParOrStatedValuePerShare_7905FBAAEF2A24DD162DDDBC7F2F2A3B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_CommonStockParOrStatedValuePerShare_7905FBAAEF2A24DD162DDDBC7F2F2A3B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CommonStockNumberofVotes" xlink:label="loc_hsy_CommonStockNumberofVotes_713CBD904775CB850EECDDBC7F2F44E1" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_hsy_CommonStockNumberofVotes_713CBD904775CB850EECDDBC7F2F44E1" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends" xlink:label="loc_hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends_04DBF9FBCA80D4002DABDDBC7F2FC427" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends_04DBF9FBCA80D4002DABDDBC7F2FC427" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConversionOfStockSharesConverted1" xlink:label="loc_us-gaap_ConversionOfStockSharesConverted1_BFB9B4327764EEE9F604DDBC7F2FFF35" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_ConversionOfStockSharesConverted1_BFB9B4327764EEE9F604DDBC7F2FFF35" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockSharesRetired" xlink:label="loc_us-gaap_TreasuryStockSharesRetired_13674CC40A02AE2B8B41DDDC1CDC996D" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_TreasuryStockSharesRetired_13674CC40A02AE2B8B41DDDC1CDC996D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockRetiredCostMethodAmount" xlink:label="loc_us-gaap_TreasuryStockRetiredCostMethodAmount_425175C2D35D21CEFFE5DDDBA9721C0D" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_TreasuryStockRetiredCostMethodAmount_425175C2D35D21CEFFE5DDDBA9721C0D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockSharesOutstanding" xlink:label="loc_us-gaap_CommonStockSharesOutstanding_E11CAD1838968E8BB265DDBC7F2F1452" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_E11CAD1838968E8BB265DDBC7F2F1452" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CommonStockVotingPercentage" xlink:label="loc_hsy_CommonStockVotingPercentage_023A1D5006E4D336436EDDBC7F309E71" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_hsy_CommonStockVotingPercentage_023A1D5006E4D336436EDDBC7F309E71" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockSharesAcquired" xlink:label="loc_us-gaap_TreasuryStockSharesAcquired_E517552244F82144E7CBDDBC7F30BADA" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_TreasuryStockSharesAcquired_E517552244F82144E7CBDDBC7F30BADA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockAcquiredAverageCostPerShare" xlink:label="loc_us-gaap_TreasuryStockAcquiredAverageCostPerShare_491C7D40F5089C38D4E7DDBC7F30FB09" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_TreasuryStockAcquiredAverageCostPerShare_491C7D40F5089C38D4E7DDBC7F30FB09" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockRepurchasedDuringPeriodValue" xlink:label="loc_us-gaap_StockRepurchasedDuringPeriodValue_AD1920B304146D8F37D9DDBC7F30C067" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_StockRepurchasedDuringPeriodValue_AD1920B304146D8F37D9DDBC7F30C067" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MinorityInterestOwnershipPercentageByParent" xlink:label="loc_us-gaap_MinorityInterestOwnershipPercentageByParent_668460834E9EAC1A79A7DDBC7F30FC88" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_MinorityInterestOwnershipPercentageByParent_668460834E9EAC1A79A7DDBC7F30FC88" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PreferredStockParOrStatedValuePerShare" xlink:label="loc_us-gaap_PreferredStockParOrStatedValuePerShare_74F13F9E6A3766A264D7DDBC7F30C822" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_us-gaap_PreferredStockParOrStatedValuePerShare_74F13F9E6A3766A264D7DDBC7F30C822" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CommonStockVotingRightsBoardElectionPercentage" xlink:label="loc_hsy_CommonStockVotingRightsBoardElectionPercentage_0772B7D908389671F26BDDBC7F31D1BF" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_E04052AC4DF6C7D7DFD6DDBC7F2E907A" xlink:to="loc_hsy_CommonStockVotingRightsBoardElectionPercentage_0772B7D908389671F26BDDBC7F31D1BF" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MinorityInterestLineItems" xlink:label="loc_us-gaap_MinorityInterestLineItems_396EECF9A7BBD7ADB98CCDD407491799" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MinorityInterestTable" xlink:label="loc_us-gaap_MinorityInterestTable_3077C6A0E6A5F18593E6CDD4074996B2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_MinorityInterestLineItems_396EECF9A7BBD7ADB98CCDD407491799" xlink:to="loc_us-gaap_MinorityInterestTable_3077C6A0E6A5F18593E6CDD4074996B2" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_82C0CE096E6FB3EBBF97CDD407492014" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_MinorityInterestTable_3077C6A0E6A5F18593E6CDD4074996B2" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_82C0CE096E6FB3EBBF97CDD407492014" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_15E079B1CCF064DCE582CDD40749177E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_82C0CE096E6FB3EBBF97CDD407492014" xlink:to="loc_us-gaap_EquityComponentDomain_15E079B1CCF064DCE582CDD40749177E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_15E079B1CCF064DCE582CDD40749177E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_82C0CE096E6FB3EBBF97CDD407492014" xlink:to="loc_us-gaap_EquityComponentDomain_15E079B1CCF064DCE582CDD40749177E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_BD0967196BD97BD6CE9FCDD40749534A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_15E079B1CCF064DCE582CDD40749177E" xlink:to="loc_us-gaap_NoncontrollingInterestMember_BD0967196BD97BD6CE9FCDD40749534A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MovementInMinorityInterestRollForward" xlink:label="loc_us-gaap_MovementInMinorityInterestRollForward_FC1912BA8BDD4670DF1ACDD407490EA9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MinorityInterestLineItems_396EECF9A7BBD7ADB98CCDD407491799" xlink:to="loc_us-gaap_MovementInMinorityInterestRollForward_FC1912BA8BDD4670DF1ACDD407490EA9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MinorityInterest" xlink:label="loc_us-gaap_MinorityInterest_1A8E2896A2A75FC64C1ACDD407491DD5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_FC1912BA8BDD4670DF1ACDD407490EA9" xlink:to="loc_us-gaap_MinorityInterest_1A8E2896A2A75FC64C1ACDD407491DD5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_053167A8B3A3468D0A23CDD40749BBF8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_FC1912BA8BDD4670DF1ACDD407490EA9" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_053167A8B3A3468D0A23CDD40749BBF8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest_8CDC2DCA6919C018A735CDD40749B005" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_FC1912BA8BDD4670DF1ACDD407490EA9" xlink:to="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest_8CDC2DCA6919C018A735CDD40749B005" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_965785657E786C0D50913597D06BC17D" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_50290E4C769CF6E6BD5B3597D069BB9E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_965785657E786C0D50913597D06BC17D" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_50290E4C769CF6E6BD5B3597D069BB9E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_51F17ED84C459E66F7BC3597D069C6E8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_50290E4C769CF6E6BD5B3597D069BB9E" xlink:to="loc_us-gaap_StatementClassOfStockAxis_51F17ED84C459E66F7BC3597D069C6E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_6E5E58959D0023DEE89E3597D06A7730_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_51F17ED84C459E66F7BC3597D069C6E8" xlink:to="loc_us-gaap_ClassOfStockDomain_6E5E58959D0023DEE89E3597D06A7730_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_6E5E58959D0023DEE89E3597D06A7730" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_51F17ED84C459E66F7BC3597D069C6E8" xlink:to="loc_us-gaap_ClassOfStockDomain_6E5E58959D0023DEE89E3597D06A7730" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_05C6FD48666EDDA1CE383597D06A6C5A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_6E5E58959D0023DEE89E3597D06A7730" xlink:to="loc_us-gaap_CommonStockMember_05C6FD48666EDDA1CE383597D06A6C5A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_FD92A3052226B1A6DF6B3597D06A04A7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_6E5E58959D0023DEE89E3597D06A7730" xlink:to="loc_hsy_HersheyTrustCompanyMember_FD92A3052226B1A6DF6B3597D06A04A7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_60B80C6136F0DFDB56573597D06BA9CE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_50290E4C769CF6E6BD5B3597D069BB9E" xlink:to="loc_us-gaap_AwardTypeAxis_60B80C6136F0DFDB56573597D06BA9CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3777D972CFA632DD5C9F3597D06B01E8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_60B80C6136F0DFDB56573597D06BA9CE" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3777D972CFA632DD5C9F3597D06B01E8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3777D972CFA632DD5C9F3597D06B01E8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_60B80C6136F0DFDB56573597D06BA9CE" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3777D972CFA632DD5C9F3597D06B01E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_56CE9E6802888B8C5F2B3597D06B6B44" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3777D972CFA632DD5C9F3597D06B01E8" xlink:to="loc_us-gaap_EmployeeStockOptionMember_56CE9E6802888B8C5F2B3597D06B6B44" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockSharesIssued" xlink:label="loc_us-gaap_CommonStockSharesIssued_D25CF23ED6155BD003C13597D06B1367" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_965785657E786C0D50913597D06BC17D" xlink:to="loc_us-gaap_CommonStockSharesIssued_D25CF23ED6155BD003C13597D06B1367" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockShares" xlink:label="loc_us-gaap_TreasuryStockShares_4A930076B9DCA7689CDA3597D06C2267" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_965785657E786C0D50913597D06BC17D" xlink:to="loc_us-gaap_TreasuryStockShares_4A930076B9DCA7689CDA3597D06C2267" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_TreasuryStockSharesRollForward" xlink:label="loc_hsy_TreasuryStockSharesRollForward_19E98AEB95098AAF0ADB3597D06CDB40" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_965785657E786C0D50913597D06BC17D" xlink:to="loc_hsy_TreasuryStockSharesRollForward_19E98AEB95098AAF0ADB3597D06CDB40" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ShareRepurchaseProgramAbstract" xlink:label="loc_hsy_ShareRepurchaseProgramAbstract_2B1F141E3C1BA1F300723597D06C9213" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_19E98AEB95098AAF0ADB3597D06CDB40" xlink:to="loc_hsy_ShareRepurchaseProgramAbstract_2B1F141E3C1BA1F300723597D06C9213" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockSharesAcquired" xlink:label="loc_us-gaap_TreasuryStockSharesAcquired_8B1ADA1625D511487F5A3597D06DE750" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_ShareRepurchaseProgramAbstract_2B1F141E3C1BA1F300723597D06C9213" xlink:to="loc_us-gaap_TreasuryStockSharesAcquired_8B1ADA1625D511487F5A3597D06DE750" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_107B4FB3DE69D3A920F23597D06D1D7D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_19E98AEB95098AAF0ADB3597D06CDB40" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_107B4FB3DE69D3A920F23597D06D1D7D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross_C36B46F40F5DA294E5CB3597D06D18C0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_107B4FB3DE69D3A920F23597D06D1D7D" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross_C36B46F40F5DA294E5CB3597D06D18C0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TreasuryStockSharesRetired" xlink:label="loc_us-gaap_TreasuryStockSharesRetired_FF5D3A0E23C2C262F9843597D06DCFC8" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_19E98AEB95098AAF0ADB3597D06CDB40" xlink:to="loc_us-gaap_TreasuryStockSharesRetired_FF5D3A0E23C2C262F9843597D06DCFC8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CommonStockChangeDuetoRetirementofTreasuryStock" xlink:label="loc_hsy_CommonStockChangeDuetoRetirementofTreasuryStock_3951D930C0C2FB975C2F3597D06E44F2" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_19E98AEB95098AAF0ADB3597D06CDB40" xlink:to="loc_hsy_CommonStockChangeDuetoRetirementofTreasuryStock_3951D930C0C2FB975C2F3597D06E44F2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockSharesOutstanding" xlink:label="loc_us-gaap_CommonStockSharesOutstanding_468425B6D742EE9B46C03597D06EB4D5" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_965785657E786C0D50913597D06BC17D" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_468425B6D742EE9B46C03597D06EB4D5" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/EquityAndNoncontrollingInterestTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurements" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_D78773AE8F8EBF690CFDD302866F4165" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_B6E1049BAE377FFC3A0CD302866D3252" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_D78773AE8F8EBF690CFDD302866F4165" xlink:to="loc_us-gaap_DerivativeTable_B6E1049BAE377FFC3A0CD302866D3252" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BB2C55969D91DA1C4EAAD302866E3394" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_B6E1049BAE377FFC3A0CD302866D3252" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BB2C55969D91DA1C4EAAD302866E3394" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_900D2AEB499A9DE1189DD302866EBC45_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BB2C55969D91DA1C4EAAD302866E3394" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_900D2AEB499A9DE1189DD302866EBC45_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_900D2AEB499A9DE1189DD302866EBC45" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BB2C55969D91DA1C4EAAD302866E3394" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_900D2AEB499A9DE1189DD302866EBC45" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_27A39CC214DA58C9C0C9D302866E13AF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_900D2AEB499A9DE1189DD302866EBC45" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_27A39CC214DA58C9C0C9D302866E13AF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_7411480107025D104B55D302866E8D41" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_B6E1049BAE377FFC3A0CD302866D3252" xlink:to="loc_us-gaap_RestructuringPlanAxis_7411480107025D104B55D302866E8D41" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_A94BB93713D13C4BD4C6D302866F2EFA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_7411480107025D104B55D302866E8D41" xlink:to="loc_us-gaap_RestructuringPlanDomain_A94BB93713D13C4BD4C6D302866F2EFA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_A94BB93713D13C4BD4C6D302866F2EFA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_7411480107025D104B55D302866E8D41" xlink:to="loc_us-gaap_RestructuringPlanDomain_A94BB93713D13C4BD4C6D302866F2EFA" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_FB21FEAE82506F0E35C7D302866F997B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_A94BB93713D13C4BD4C6D302866F2EFA" xlink:to="loc_hsy_MarginforGrowthProgramMember_FB21FEAE82506F0E35C7D302866F997B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueNetAssetLiability" xlink:label="loc_us-gaap_FairValueNetAssetLiability_9D65699E1FBFE6290A8FD311F1AED4A2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_D78773AE8F8EBF690CFDD302866F4165" xlink:to="loc_us-gaap_FairValueNetAssetLiability_9D65699E1FBFE6290A8FD311F1AED4A2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsToBeDisposedOf" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsToBeDisposedOf_70FEFED743A5E65EDA99D30286703810" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_D78773AE8F8EBF690CFDD302866F4165" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsToBeDisposedOf_70FEFED743A5E65EDA99D30286703810" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_EDAEA860FBEA797FD0CAD3028670F658" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_D78773AE8F8EBF690CFDD302866F4165" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_EDAEA860FBEA797FD0CAD3028670F658" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsHeldForUse" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_F5EB59BACE75156C6B62D30286702127" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_D78773AE8F8EBF690CFDD302866F4165" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_F5EB59BACE75156C6B62D30286702127" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems" xlink:label="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_CAFC8E2546B26B53CF7DC72CA26AC031" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByBalanceSheetGroupingTable" xlink:label="loc_us-gaap_FairValueByBalanceSheetGroupingTable_BB7CC4C927B6427991F9C72CA2613714" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_CAFC8E2546B26B53CF7DC72CA26AC031" xlink:to="loc_us-gaap_FairValueByBalanceSheetGroupingTable_BB7CC4C927B6427991F9C72CA2613714" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2134CBBF8798CD036E0FC72CA262E9B4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_BB7CC4C927B6427991F9C72CA2613714" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2134CBBF8798CD036E0FC72CA262E9B4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_FBD14548FF3BA949F80AC72CA262D9C8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2134CBBF8798CD036E0FC72CA262E9B4" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_FBD14548FF3BA949F80AC72CA262D9C8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_FBD14548FF3BA949F80AC72CA262D9C8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2134CBBF8798CD036E0FC72CA262E9B4" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_FBD14548FF3BA949F80AC72CA262D9C8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_C65631601C167D828EAAC72CA2629064" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_FBD14548FF3BA949F80AC72CA262D9C8" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_C65631601C167D828EAAC72CA2629064" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_7B86628E8DFC5D921951C72CA2626953" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_BB7CC4C927B6427991F9C72CA2613714" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_7B86628E8DFC5D921951C72CA2626953" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_7B86628E8DFC5D921951C72CA2626953" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_7B86628E8DFC5D921951C72CA2626953" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_AEB59290F17339278F69C72CA26314C9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4" xlink:to="loc_us-gaap_ForeignExchangeContractMember_AEB59290F17339278F69C72CA26314C9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_D0FE67D2B25849262186C72CA26348B6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4" xlink:to="loc_us-gaap_InterestRateContractMember_D0FE67D2B25849262186C72CA26348B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_A807298739EB1B7AE5B6C72CA2631EEF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4" xlink:to="loc_us-gaap_EquitySwapMember_A807298739EB1B7AE5B6C72CA2631EEF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_9F802EFD81FD88010C8DC72CA268BDB0" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_271C87A6068252D249F0C72CA2630BF4" xlink:to="loc_us-gaap_CommodityContractMember_9F802EFD81FD88010C8DC72CA268BDB0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_17A8F43826E40A5559F1C72CA269751C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_BB7CC4C927B6427991F9C72CA2613714" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_17A8F43826E40A5559F1C72CA269751C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_17A8F43826E40A5559F1C72CA269751C" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_17A8F43826E40A5559F1C72CA269751C" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel1Member" xlink:label="loc_us-gaap_FairValueInputsLevel1Member_EA80AF4C33CF72071553C72CA2693072" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_EA80AF4C33CF72071553C72CA2693072" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_7A62D84809C6077AA922C72CA26A3316" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_7A62D84809C6077AA922C72CA26A3316" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_29553F33A068A352EFDEC72CA26AE44C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EA2F199EC50D5FEA678DC72CA269EC89" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_29553F33A068A352EFDEC72CA26AE44C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_045AD5A53FB91CA1BC39C72CA26AEEB2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_CAFC8E2546B26B53CF7DC72CA26AC031" xlink:to="loc_us-gaap_DerivativeAssets_045AD5A53FB91CA1BC39C72CA26AEEB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_24CD79EC2EAB915A961DC72CA26A8523" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_CAFC8E2546B26B53CF7DC72CA26AC031" xlink:to="loc_us-gaap_DerivativeLiabilities_24CD79EC2EAB915A961DC72CA26A8523" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_BEF5915A098C4FFDE0CCD4071D0BF76B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_BEF5915A098C4FFDE0CCD4071D0BF76B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_225C067EB3277E31209FD4071D0B0D2A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_BEF5915A098C4FFDE0CCD4071D0BF76B" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_225C067EB3277E31209FD4071D0B0D2A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_D2BA39CA1C9E69569366D4071D0BF73E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_225C067EB3277E31209FD4071D0B0D2A" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_D2BA39CA1C9E69569366D4071D0BF73E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_D2BA39CA1C9E69569366D4071D0BF73E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_225C067EB3277E31209FD4071D0B0D2A" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_D2BA39CA1C9E69569366D4071D0BF73E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_6E6D69B2594F29401D3FD4071D0BFFBF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_D2BA39CA1C9E69569366D4071D0BF73E" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_6E6D69B2594F29401D3FD4071D0BFFBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax" xlink:label="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax_34AD35B4C0C5DD4F85BFD42A3CE2944B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax_34AD35B4C0C5DD4F85BFD42A3CE2944B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_LongtermDebtCurrentMaturitiesFairValue" xlink:label="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_04E7C67737E6F0B7C3B8D4071D0BBD81" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_04E7C67737E6F0B7C3B8D4071D0BBD81" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_LongtermDebtExcludingCurrentMaturitiesFairValue" xlink:label="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_A3A020387E4B569A636BD4071D0B2F39" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_A3A020387E4B569A636BD4071D0B2F39" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtFairValue" xlink:label="loc_us-gaap_LongTermDebtFairValue_EA17EFCE2A6AB045DFE1D4071D0B3D8E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_us-gaap_LongTermDebtFairValue_EA17EFCE2A6AB045DFE1D4071D0B3D8E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_F38D83B7A3645F2F1FA5D4071D0BFADE" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_us-gaap_LongTermDebtCurrent_F38D83B7A3645F2F1FA5D4071D0BFADE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtNoncurrent" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_5F9EFC112875B583C6FCD4071D0B0E56" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_5F9EFC112875B583C6FCD4071D0B0E56" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_AD2BED9B8E32B13F4DE3D4071D0B1990" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_18305FC19237A504E821D4071D0B04F1" xlink:to="loc_us-gaap_LongTermDebt_AD2BED9B8E32B13F4DE3D4071D0B1990" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfImpairmentChargesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_9B02B5EFF2A597642CFEF67503080ACE" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_9339FD7642B9E495A96AF67503061B09" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_9B02B5EFF2A597642CFEF67503080ACE" xlink:to="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_9339FD7642B9E495A96AF67503061B09" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_10CEF007C89B88769529F6750307DE0C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_9339FD7642B9E495A96AF67503061B09" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_10CEF007C89B88769529F6750307DE0C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_5829448E0AEC94D957A0F6750307DB97_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_10CEF007C89B88769529F6750307DE0C" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_5829448E0AEC94D957A0F6750307DB97_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_5829448E0AEC94D957A0F6750307DB97" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_10CEF007C89B88769529F6750307DE0C" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_5829448E0AEC94D957A0F6750307DB97" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CustomerRelationshipandTrademarkMember" xlink:label="loc_hsy_CustomerRelationshipandTrademarkMember_4AA74DDDDF50513A34A2F67503077200" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_5829448E0AEC94D957A0F6750307DB97" xlink:to="loc_hsy_CustomerRelationshipandTrademarkMember_4AA74DDDDF50513A34A2F67503077200" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_OtherLongLivedAssetsNotHeldForSaleMember" xlink:label="loc_hsy_OtherLongLivedAssetsNotHeldForSaleMember_95E9104C00C1D9267099F67503085CD7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_5829448E0AEC94D957A0F6750307DB97" xlink:to="loc_hsy_OtherLongLivedAssetsNotHeldForSaleMember_95E9104C00C1D9267099F67503085CD7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ImpairmentChargeOnReclassifiedAssets" xlink:label="loc_us-gaap_ImpairmentChargeOnReclassifiedAssets_32959BB2726177507486F67503084795" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_9B02B5EFF2A597642CFEF67503080ACE" xlink:to="loc_us-gaap_ImpairmentChargeOnReclassifiedAssets_32959BB2726177507486F67503084795" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_558C3E1C61611D624A62F675030818D3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_9B02B5EFF2A597642CFEF67503080ACE" xlink:to="loc_us-gaap_AssetImpairmentCharges_558C3E1C61611D624A62F675030818D3" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssets" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_DB6C064C1AD298D7FFEDF67503CCC77F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_DB6C064C1AD298D7FFEDF67503CCC77F" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_2D36A2A021CB51D0BADDF67503C97064" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_2D36A2A021CB51D0BADDF67503C97064" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_537FBEF48C4AEF69DD6AF67503CAC603_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_2D36A2A021CB51D0BADDF67503C97064" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_537FBEF48C4AEF69DD6AF67503CAC603_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_537FBEF48C4AEF69DD6AF67503CAC603" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_2D36A2A021CB51D0BADDF67503C97064" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_537FBEF48C4AEF69DD6AF67503CAC603" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_KRAVEPureFoodsInc.Member" xlink:label="loc_hsy_KRAVEPureFoodsInc.Member_C67E50A88EE9A4567912F67503CAC588" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_537FBEF48C4AEF69DD6AF67503CAC603" xlink:to="loc_hsy_KRAVEPureFoodsInc.Member_C67E50A88EE9A4567912F67503CAC588" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC2DD94E3E1106849BE7F67503CA3DCC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC2DD94E3E1106849BE7F67503CA3DCC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_28165931CDCDBE5C6701F67503CBB36F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC2DD94E3E1106849BE7F67503CA3DCC" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_28165931CDCDBE5C6701F67503CBB36F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_28165931CDCDBE5C6701F67503CBB36F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC2DD94E3E1106849BE7F67503CA3DCC" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_28165931CDCDBE5C6701F67503CBB36F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_09C07F98BB4971159424F67503CB3DF9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:to="loc_srt_ConsolidationItemsAxis_09C07F98BB4971159424F67503CB3DF9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_D89812A6BBB0499CEEC2F67503CBECE1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_09C07F98BB4971159424F67503CB3DF9" xlink:to="loc_srt_ConsolidationItemsDomain_D89812A6BBB0499CEEC2F67503CBECE1_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_D89812A6BBB0499CEEC2F67503CBECE1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_09C07F98BB4971159424F67503CB3DF9" xlink:to="loc_srt_ConsolidationItemsDomain_D89812A6BBB0499CEEC2F67503CBECE1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_D4B2218052D4DF9A85B4F67503CB1FC3" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_D4B2218052D4DF9A85B4F67503CB1FC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_963327F2EA4D117F5627F67503CCA493_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_D4B2218052D4DF9A85B4F67503CB1FC3" xlink:to="loc_us-gaap_SegmentDomain_963327F2EA4D117F5627F67503CCA493_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_963327F2EA4D117F5627F67503CCA493" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_D4B2218052D4DF9A85B4F67503CB1FC3" xlink:to="loc_us-gaap_SegmentDomain_963327F2EA4D117F5627F67503CCA493" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_90DFEB82E1CF796AC1AAF67503CC6AE3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_77F89E5B10D5E34FD3DBF67503C953D1" xlink:to="loc_srt_RangeAxis_90DFEB82E1CF796AC1AAF67503CC6AE3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_70CF58E342BDAD189A9AF67503CCD42F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_90DFEB82E1CF796AC1AAF67503CC6AE3" xlink:to="loc_srt_RangeMember_70CF58E342BDAD189A9AF67503CCD42F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_70CF58E342BDAD189A9AF67503CCD42F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_90DFEB82E1CF796AC1AAF67503CC6AE3" xlink:to="loc_srt_RangeMember_70CF58E342BDAD189A9AF67503CCD42F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_569D284F273FF9D4F71DF67503CD1D07" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_DB6C064C1AD298D7FFEDF67503CCC77F" xlink:to="loc_us-gaap_AssetImpairmentCharges_569D284F273FF9D4F71DF67503CD1D07" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillLineItems" xlink:label="loc_us-gaap_GoodwillLineItems_03918EDD9AA04188D0D4FA331FD60C97" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfGoodwillTable" xlink:label="loc_us-gaap_ScheduleOfGoodwillTable_E82E706F58511A3B9F8AFA331FD4E251" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_GoodwillLineItems_03918EDD9AA04188D0D4FA331FD60C97" xlink:to="loc_us-gaap_ScheduleOfGoodwillTable_E82E706F58511A3B9F8AFA331FD4E251" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_3C354973C8325FE30A70FA331FD4BD6D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_E82E706F58511A3B9F8AFA331FD4E251" xlink:to="loc_srt_ConsolidationItemsAxis_3C354973C8325FE30A70FA331FD4BD6D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_EC8FA5BA75D63D61127BFA331FD5C06A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_3C354973C8325FE30A70FA331FD4BD6D" xlink:to="loc_srt_ConsolidationItemsDomain_EC8FA5BA75D63D61127BFA331FD5C06A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_EC8FA5BA75D63D61127BFA331FD5C06A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_3C354973C8325FE30A70FA331FD4BD6D" xlink:to="loc_srt_ConsolidationItemsDomain_EC8FA5BA75D63D61127BFA331FD5C06A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_66FADE130C01A2BB1A49FA331FD5395D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_EC8FA5BA75D63D61127BFA331FD5C06A" xlink:to="loc_us-gaap_OperatingSegmentsMember_66FADE130C01A2BB1A49FA331FD5395D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_224F22E3B179E81ABAA7FA331FD587B8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_E82E706F58511A3B9F8AFA331FD4E251" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_224F22E3B179E81ABAA7FA331FD587B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_F4B404A90B485A43FFB7FA331FD5065D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_224F22E3B179E81ABAA7FA331FD587B8" xlink:to="loc_us-gaap_SegmentDomain_F4B404A90B485A43FFB7FA331FD5065D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_F4B404A90B485A43FFB7FA331FD5065D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_224F22E3B179E81ABAA7FA331FD587B8" xlink:to="loc_us-gaap_SegmentDomain_F4B404A90B485A43FFB7FA331FD5065D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_82A4C393F5F99A056599FA331FD6E4C4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_F4B404A90B485A43FFB7FA331FD5065D" xlink:to="loc_hsy_NorthAmericaSegmentMember_82A4C393F5F99A056599FA331FD6E4C4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_280E2CF631E36C6F58A5FA331FD630A6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_F4B404A90B485A43FFB7FA331FD5065D" xlink:to="loc_hsy_InternationalandOtherSegmentMember_280E2CF631E36C6F58A5FA331FD630A6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillGross" xlink:label="loc_us-gaap_GoodwillGross_6CAA2CACA1524CA538B2FA331FD67526" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_03918EDD9AA04188D0D4FA331FD60C97" xlink:to="loc_us-gaap_GoodwillGross_6CAA2CACA1524CA538B2FA331FD67526" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillImpairedAccumulatedImpairmentLoss" xlink:label="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_46CAA6DACFACAA578F4BFA331FD7715D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_03918EDD9AA04188D0D4FA331FD60C97" xlink:to="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_46CAA6DACFACAA578F4BFA331FD7715D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillRollForward" xlink:label="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_03918EDD9AA04188D0D4FA331FD60C97" xlink:to="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_66804EB145804A43F5E0FA331FD787DA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:to="loc_us-gaap_Goodwill_66804EB145804A43F5E0FA331FD787DA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillAcquiredDuringPeriod" xlink:label="loc_us-gaap_GoodwillAcquiredDuringPeriod_BAC18DAA49D051C9CACEFA331FD74E30" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:to="loc_us-gaap_GoodwillAcquiredDuringPeriod_BAC18DAA49D051C9CACEFA331FD74E30" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillPurchaseAccountingAdjustments" xlink:label="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_A6C945180DCC1AC20F7EFA331FD78D53" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:to="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_A6C945180DCC1AC20F7EFA331FD78D53" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillWrittenOffRelatedToSaleOfBusinessUnit" xlink:label="loc_us-gaap_GoodwillWrittenOffRelatedToSaleOfBusinessUnit_899FD1F0A73C681E0D6EFA331FD70484" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:to="loc_us-gaap_GoodwillWrittenOffRelatedToSaleOfBusinessUnit_899FD1F0A73C681E0D6EFA331FD70484" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillForeignCurrencyTranslationGainLoss" xlink:label="loc_us-gaap_GoodwillForeignCurrencyTranslationGainLoss_69859F90CD16A801D63CFA331FD8D5D6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_8C55C24796603CBC7C0EFA331FD71CDD" xlink:to="loc_us-gaap_GoodwillForeignCurrencyTranslationGainLoss_69859F90CD16A801D63CFA331FD8D5D6" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8F6E2333BD860F5F693CAD1BBAF24C93" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_AF2F0B724C9DA6A890A7AD1BBAEF94DC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8F6E2333BD860F5F693CAD1BBAF24C93" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_AF2F0B724C9DA6A890A7AD1BBAEF94DC" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_B87F81768547E84C652AAD1BBAF0D847" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_AF2F0B724C9DA6A890A7AD1BBAEF94DC" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_B87F81768547E84C652AAD1BBAF0D847" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_B87F81768547E84C652AAD1BBAF0D847" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_B87F81768547E84C652AAD1BBAF0D847" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_3AE1AA02C4B0764B99C7AD1BBAF0AC9E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E" xlink:to="loc_us-gaap_TrademarksMember_3AE1AA02C4B0764B99C7AD1BBAF0AC9E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CustomerRelatedIntangibleAssetsMember" xlink:label="loc_us-gaap_CustomerRelatedIntangibleAssetsMember_15931CDB3AB88611C26FAD1BBAF17E9C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E" xlink:to="loc_us-gaap_CustomerRelatedIntangibleAssetsMember_15931CDB3AB88611C26FAD1BBAF17E9C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PatentsMember" xlink:label="loc_us-gaap_PatentsMember_C7ECB1733B435A4F1D0AAD1BBAF10526" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_84F956C954337931B092AD1BBAF0A16E" xlink:to="loc_us-gaap_PatentsMember_C7ECB1733B435A4F1D0AAD1BBAF10526" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_9DF71EC6199B5E82614FAD1BBAF10B3F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_AF2F0B724C9DA6A890A7AD1BBAEF94DC" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_9DF71EC6199B5E82614FAD1BBAF10B3F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_66D8287690F4662038B0AD1BBAF1504F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_9DF71EC6199B5E82614FAD1BBAF10B3F" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_66D8287690F4662038B0AD1BBAF1504F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_66D8287690F4662038B0AD1BBAF1504F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_9DF71EC6199B5E82614FAD1BBAF10B3F" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_66D8287690F4662038B0AD1BBAF1504F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_C91678589437AF3D8856AD1BBAF27D33" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_66D8287690F4662038B0AD1BBAF1504F" xlink:to="loc_us-gaap_TrademarksMember_C91678589437AF3D8856AD1BBAF27D33" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsGross" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsGross_1931C49A0A4A7F78FB2EAD1BBAF25810" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8F6E2333BD860F5F693CAD1BBAF24C93" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsGross_1931C49A0A4A7F78FB2EAD1BBAF25810" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_5885746AADAD6F08221AAD1BBAF23A65" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8F6E2333BD860F5F693CAD1BBAF24C93" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_5885746AADAD6F08221AAD1BBAF23A65" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill_E70AC970C093828F648DAD1BBAF38B84" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8F6E2333BD860F5F693CAD1BBAF24C93" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill_E70AC970C093828F648DAD1BBAF38B84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_9F41CA61F13263887790AD1BBAF3DFAB" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8F6E2333BD860F5F693CAD1BBAF24C93" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_9F41CA61F13263887790AD1BBAF3DFAB" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxes" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesIncomeTaxesNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeTaxContingencyLineItems" xlink:label="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeTaxContingencyTable" xlink:label="loc_us-gaap_IncomeTaxContingencyTable_0480926C00E76EC62AF1D7E31D8CBDBF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_IncomeTaxContingencyTable_0480926C00E76EC62AF1D7E31D8CBDBF" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_17531D8B0CF2296CBBEAD7E31D8C2678" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_0480926C00E76EC62AF1D7E31D8CBDBF" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_17531D8B0CF2296CBBEAD7E31D8C2678" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_0D3F9278CAB72D6D1CABD7E31D8C5E97_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_17531D8B0CF2296CBBEAD7E31D8C2678" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_0D3F9278CAB72D6D1CABD7E31D8C5E97_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_0D3F9278CAB72D6D1CABD7E31D8C5E97" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_17531D8B0CF2296CBBEAD7E31D8C2678" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_0D3F9278CAB72D6D1CABD7E31D8C5E97" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpenseMember" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_195578FD59857BC88C72D7E31D8C3FA5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_0D3F9278CAB72D6D1CABD7E31D8C5E97" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_195578FD59857BC88C72D7E31D8C3FA5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis" xlink:label="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_9EB6DE5A077A6A831B0DD7E31D8C8AB2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_0480926C00E76EC62AF1D7E31D8CBDBF" xlink:to="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_9EB6DE5A077A6A831B0DD7E31D8C8AB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_EquityMethodInvesteeNameDomain" xlink:label="loc_srt_EquityMethodInvesteeNameDomain_F7F467BA59394AC6E9BFD7E31D8C395D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_9EB6DE5A077A6A831B0DD7E31D8C8AB2" xlink:to="loc_srt_EquityMethodInvesteeNameDomain_F7F467BA59394AC6E9BFD7E31D8C395D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_EquityMethodInvesteeNameDomain" xlink:label="loc_srt_EquityMethodInvesteeNameDomain_F7F467BA59394AC6E9BFD7E31D8C395D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_9EB6DE5A077A6A831B0DD7E31D8C8AB2" xlink:to="loc_srt_EquityMethodInvesteeNameDomain_F7F467BA59394AC6E9BFD7E31D8C395D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PartnershipsQualifyingForTaxCreditsMember" xlink:label="loc_hsy_PartnershipsQualifyingForTaxCreditsMember_B48E661079DB3A7F4B8DD7E31D8C23D8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_EquityMethodInvesteeNameDomain_F7F467BA59394AC6E9BFD7E31D8C395D" xlink:to="loc_hsy_PartnershipsQualifyingForTaxCreditsMember_B48E661079DB3A7F4B8DD7E31D8C23D8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit" xlink:label="loc_hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit_1E095EADEF5B70CE35EED7E31D8C0268" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit_1E095EADEF5B70CE35EED7E31D8C0268" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TaxCutsAndJobsActOf2017MeasurementPeriodAdjustmentIncomeTaxExpenseBenefit" xlink:label="loc_us-gaap_TaxCutsAndJobsActOf2017MeasurementPeriodAdjustmentIncomeTaxExpenseBenefit_C17659F476918BCDB3CCD7E31D8C269F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_TaxCutsAndJobsActOf2017MeasurementPeriodAdjustmentIncomeTaxExpenseBenefit_C17659F476918BCDB3CCD7E31D8C269F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate_0B017F01C4C3163C340ED7E31D8C6115" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate_0B017F01C4C3163C340ED7E31D8C6115" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense_B6796F6F942CF06D7725D7E31D8CDB4E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense_B6796F6F942CF06D7725D7E31D8CDB4E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_8B4DB4B83807374FC80DD7E31D8C326E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_8B4DB4B83807374FC80DD7E31D8C326E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit" xlink:label="loc_us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit_69461DDD859BDAC1F963D7E31D8C2D2E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit_69461DDD859BDAC1F963D7E31D8C2D2E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_UndistributedEarningsOfForeignSubsidiaries" xlink:label="loc_us-gaap_UndistributedEarningsOfForeignSubsidiaries_3B82B7DD0AFE538848B5D7E31D8C2D7D" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_UndistributedEarningsOfForeignSubsidiaries_3B82B7DD0AFE538848B5D7E31D8C2D7D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeTaxCreditsAndAdjustments" xlink:label="loc_us-gaap_IncomeTaxCreditsAndAdjustments_8FD64A131792CCE98971D7E31D8C5F6C" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_IncomeTaxCreditsAndAdjustments_8FD64A131792CCE98971D7E31D8C5F6C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_B73FF7568E84FEDC6512D7E31D8C4151" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_13E255DDC2B22D67BAB4D7E31D8C5D78" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_B73FF7568E84FEDC6512D7E31D8C4151" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/IncomeTaxesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/Leases" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesScheduleOfComponenetsOfLeaseExpenseDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesScheduleOfInformationRegardingOurLeaseTermsAndDiscountRatesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesScheduleOfMaturitiesOfLeaseLiabilitiesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesScheduleOfSupplementalCashFlowInformationRelatedToLeasesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesSupplementalBalanceSheetInformationRelatedToLeasesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LesseeLeaseDescriptionLineItems" xlink:label="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LesseeLeaseDescriptionTable" xlink:label="loc_us-gaap_LesseeLeaseDescriptionTable_18980CD8E794F3030CA735E305BEED23" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_LesseeLeaseDescriptionTable_18980CD8E794F3030CA735E305BEED23" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BalanceSheetLocationAxis" xlink:label="loc_us-gaap_BalanceSheetLocationAxis_48AB7BA7676E41F9898C35E305BF8276" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LesseeLeaseDescriptionTable_18980CD8E794F3030CA735E305BEED23" xlink:to="loc_us-gaap_BalanceSheetLocationAxis_48AB7BA7676E41F9898C35E305BF8276" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BalanceSheetLocationDomain" xlink:label="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BalanceSheetLocationAxis_48AB7BA7676E41F9898C35E305BF8276" xlink:to="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BalanceSheetLocationDomain" xlink:label="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BalanceSheetLocationAxis_48AB7BA7676E41F9898C35E305BF8276" xlink:to="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PropertyPlantandEquipmentGrossMember" xlink:label="loc_hsy_PropertyPlantandEquipmentGrossMember_966DD2BEB3341C6C836C35E305BFBAE6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6" xlink:to="loc_hsy_PropertyPlantandEquipmentGrossMember_966DD2BEB3341C6C836C35E305BFBAE6" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_AccumulatedDepreciationMember" xlink:label="loc_hsy_AccumulatedDepreciationMember_E15DEA460445D4F4C86235E305C00D47" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6" xlink:to="loc_hsy_AccumulatedDepreciationMember_E15DEA460445D4F4C86235E305C00D47" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentMember" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentMember_68C153990EC7E2CAB4CE35E305C07CDD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BalanceSheetLocationDomain_961B7E521BF331814FEA35E305BFA4B6" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentMember_68C153990EC7E2CAB4CE35E305C07CDD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingLeaseRightOfUseAsset" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_DF01DEEE4B63F4478FDD35E305C0581F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_DF01DEEE4B63F4478FDD35E305C0581F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FinanceLeaseRightOfUseAsset" xlink:label="loc_us-gaap_FinanceLeaseRightOfUseAsset_81ACEDCAB75F029CD45E35E305C0B3DE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_FinanceLeaseRightOfUseAsset_81ACEDCAB75F029CD45E35E305C0B3DE" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_LeaseRightofUseAsset" xlink:label="loc_hsy_LeaseRightofUseAsset_63732FC84AC11D3AF3A435E305C1D389" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_hsy_LeaseRightofUseAsset_63732FC84AC11D3AF3A435E305C1D389" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingLeaseLiabilityCurrent" xlink:label="loc_us-gaap_OperatingLeaseLiabilityCurrent_FFE9216CBF532A58B22035E305C12B13" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_OperatingLeaseLiabilityCurrent_FFE9216CBF532A58B22035E305C12B13" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FinanceLeaseLiabilityCurrent" xlink:label="loc_us-gaap_FinanceLeaseLiabilityCurrent_5C15EA323D292A2239D135E305C1C131" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_FinanceLeaseLiabilityCurrent_5C15EA323D292A2239D135E305C1C131" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingLeaseLiabilityNoncurrent" xlink:label="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_2DB295561663D689CEEC35E305C12FF5" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_2DB295561663D689CEEC35E305C12FF5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FinanceLeaseLiabilityNoncurrent" xlink:label="loc_us-gaap_FinanceLeaseLiabilityNoncurrent_3BF93EB2BAC63D2D40A335E305C1BB08" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_us-gaap_FinanceLeaseLiabilityNoncurrent_3BF93EB2BAC63D2D40A335E305C1BB08" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_LeaseLiability" xlink:label="loc_hsy_LeaseLiability_B86493AF6F09D57D0BB635E305C10EC7" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LesseeLeaseDescriptionLineItems_1C88E989CFA63CFC380835E305C09A85" xlink:to="loc_hsy_LeaseLiability_B86493AF6F09D57D0BB635E305C10EC7" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/LeasesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems" xlink:label="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_9C64D3AA657366288446D7EB4F92B50A" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable" xlink:label="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_EFA4F40F6013DDD18763D7EB4F907820" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_9C64D3AA657366288446D7EB4F92B50A" xlink:to="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_EFA4F40F6013DDD18763D7EB4F907820" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FE1600812E147394ACC2D7EB4F909B28" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_EFA4F40F6013DDD18763D7EB4F907820" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FE1600812E147394ACC2D7EB4F909B28" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_07C0CAFFBE188483BC01D7EB4F917BE5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FE1600812E147394ACC2D7EB4F909B28" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_07C0CAFFBE188483BC01D7EB4F917BE5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_07C0CAFFBE188483BC01D7EB4F917BE5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FE1600812E147394ACC2D7EB4F909B28" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_07C0CAFFBE188483BC01D7EB4F917BE5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_2126A7C605171D9A1BCAD7EB4F9242EA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_9C64D3AA657366288446D7EB4F92B50A" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_2126A7C605171D9A1BCAD7EB4F9242EA" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DefinedBenefitPlanNonServiceCost" xlink:label="loc_hsy_DefinedBenefitPlanNonServiceCost_4E6D79C4F0E18069A997D7EB4F926197" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_9C64D3AA657366288446D7EB4F92B50A" xlink:to="loc_hsy_DefinedBenefitPlanNonServiceCost_4E6D79C4F0E18069A997D7EB4F926197" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_OtherNonoperatingGainLoss" xlink:label="loc_hsy_OtherNonoperatingGainLoss_B02C6865CE81443FD86DD7EB4F93BDDE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_9C64D3AA657366288446D7EB4F92B50A" xlink:to="loc_hsy_OtherNonoperatingGainLoss_B02C6865CE81443FD86DD7EB4F93BDDE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_879BA239131F5C2C58AFD7EB4F93A303" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_9C64D3AA657366288446D7EB4F92B50A" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_879BA239131F5C2C58AFD7EB4F93A303" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlans" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F18C4BA2516E3F035F8BD7EBA7EAA295" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F18C4BA2516E3F035F8BD7EBA7EAA295" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_6EF6A257856F6795DF3CD7EBA7EA40A1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F18C4BA2516E3F035F8BD7EBA7EAA295" xlink:to="loc_srt_RangeAxis_6EF6A257856F6795DF3CD7EBA7EA40A1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_1B32C569EA67F7AA4FA1D7EBA7EAA993_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_6EF6A257856F6795DF3CD7EBA7EA40A1" xlink:to="loc_srt_RangeMember_1B32C569EA67F7AA4FA1D7EBA7EAA993_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_1B32C569EA67F7AA4FA1D7EBA7EAA993" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_6EF6A257856F6795DF3CD7EBA7EA40A1" xlink:to="loc_srt_RangeMember_1B32C569EA67F7AA4FA1D7EBA7EAA993" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_3E49F4A6A1F0EBD16856D7EBA7EB3981" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_1B32C569EA67F7AA4FA1D7EBA7EAA993" xlink:to="loc_srt_MinimumMember_3E49F4A6A1F0EBD16856D7EBA7EB3981" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_005863D0E3EEA2A7F82BD7EBA7EB1CA4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_1B32C569EA67F7AA4FA1D7EBA7EAA993" xlink:to="loc_srt_MaximumMember_005863D0E3EEA2A7F82BD7EBA7EB1CA4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_7E537CCBBFDAB19E230BD7EBA7EB3E1A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F18C4BA2516E3F035F8BD7EBA7EAA295" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_7E537CCBBFDAB19E230BD7EBA7EB3E1A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_F1DB7037826BE5E66070D7EBA7EB0EE4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_7E537CCBBFDAB19E230BD7EBA7EB3E1A" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_F1DB7037826BE5E66070D7EBA7EB0EE4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_F1DB7037826BE5E66070D7EBA7EB0EE4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_7E537CCBBFDAB19E230BD7EBA7EB3E1A" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_F1DB7037826BE5E66070D7EBA7EB0EE4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_001690B6C3F0CD9C398DD7EBA7EC2BC9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_F1DB7037826BE5E66070D7EBA7EB0EE4" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_001690B6C3F0CD9C398DD7EBA7EC2BC9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_19690E678F50F752E2EBD7EBA7EC12F4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_F1DB7037826BE5E66070D7EBA7EB0EE4" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_19690E678F50F752E2EBD7EBA7EC12F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_StatementScenarioAxis" xlink:label="loc_srt_StatementScenarioAxis_F9BC757F6585104ED1BED7EBA7EC1112" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F18C4BA2516E3F035F8BD7EBA7EAA295" xlink:to="loc_srt_StatementScenarioAxis_F9BC757F6585104ED1BED7EBA7EC1112" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_7FA7D06085D69E118A22D7EBA7ED71E7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_StatementScenarioAxis_F9BC757F6585104ED1BED7EBA7EC1112" xlink:to="loc_srt_ScenarioUnspecifiedDomain_7FA7D06085D69E118A22D7EBA7ED71E7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_7FA7D06085D69E118A22D7EBA7ED71E7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_StatementScenarioAxis_F9BC757F6585104ED1BED7EBA7EC1112" xlink:to="loc_srt_ScenarioUnspecifiedDomain_7FA7D06085D69E118A22D7EBA7ED71E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioForecastMember" xlink:label="loc_srt_ScenarioForecastMember_BC4D6F87B4335B84926AD7EBA7ED024F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ScenarioUnspecifiedDomain_7FA7D06085D69E118A22D7EBA7ED71E7" xlink:to="loc_srt_ScenarioForecastMember_BC4D6F87B4335B84926AD7EBA7ED024F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanNameAxis" xlink:label="loc_us-gaap_RetirementPlanNameAxis_8F9287AB5582A80A999DD7EBA7EE0BC8" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F18C4BA2516E3F035F8BD7EBA7EAA295" xlink:to="loc_us-gaap_RetirementPlanNameAxis_8F9287AB5582A80A999DD7EBA7EE0BC8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanNameDomain" xlink:label="loc_us-gaap_RetirementPlanNameDomain_91792C2E8A954E490D3AD7EBA7EE4865_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanNameAxis_8F9287AB5582A80A999DD7EBA7EE0BC8" xlink:to="loc_us-gaap_RetirementPlanNameDomain_91792C2E8A954E490D3AD7EBA7EE4865_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanNameDomain" xlink:label="loc_us-gaap_RetirementPlanNameDomain_91792C2E8A954E490D3AD7EBA7EE4865" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanNameAxis_8F9287AB5582A80A999DD7EBA7EE0BC8" xlink:to="loc_us-gaap_RetirementPlanNameDomain_91792C2E8A954E490D3AD7EBA7EE4865" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans" xlink:label="loc_hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans_42964CD0CEAADBF57754D7EBA7EF2F7B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans_42964CD0CEAADBF57754D7EBA7EF2F7B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanActuarialGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_8D86346E5BD874E434B4D7EBA7EFAB31" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_8D86346E5BD874E434B4D7EBA7EFAB31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_EA6DA8B7730D48D70A0BD7EBA7EF4226" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_EA6DA8B7730D48D70A0BD7EBA7EF4226" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation_5355F632D3FDEB5A2311D7EBA7F56F99" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation_5355F632D3FDEB5A2311D7EBA7F56F99" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear_011299B1B2B31A6F30EED7EBA7F65DCE" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear_011299B1B2B31A6F30EED7EBA7F65DCE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1" xlink:label="loc_us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1_539403B4613CEC40F574D7EBA7F646FD" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1_539403B4613CEC40F574D7EBA7F646FD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanContributionsByEmployer" xlink:label="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_A4DFDC74916CA6D32E4CD7EBA7F69F6E" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_A4DFDC74916CA6D32E4CD7EBA7F69F6E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedContributionPlanCostRecognized" xlink:label="loc_us-gaap_DefinedContributionPlanCostRecognized_04499999F2BAAB6D3294D7EBA7F6AD63" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_us-gaap_DefinedContributionPlanCostRecognized_04499999F2BAAB6D3294D7EBA7F6AD63" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear" xlink:label="loc_hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear_BD0702AE4298B66AC963D7EBA7F6DCF1" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8966F4C193316BA384A4D7EBA7EFC65F" xlink:to="loc_hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear_BD0702AE4298B66AC963D7EBA7F6DCF1" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_A126D6CE7E4133789862D310C11D5DDC" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_E6202730A9D5E290E24BD310C11C976E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_A126D6CE7E4133789862D310C11D5DDC" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_E6202730A9D5E290E24BD310C11C976E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_A9913A30B3C7FA7243CDD310C11C9BBA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_E6202730A9D5E290E24BD310C11C976E" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_A9913A30B3C7FA7243CDD310C11C9BBA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_B0F6F49BFB2C01A35206D310C11C269E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_A9913A30B3C7FA7243CDD310C11C9BBA" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_B0F6F49BFB2C01A35206D310C11C269E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_B0F6F49BFB2C01A35206D310C11C269E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_A9913A30B3C7FA7243CDD310C11C9BBA" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_B0F6F49BFB2C01A35206D310C11C269E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_FA821F998269DA289B0ED310C11DEAF3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_B0F6F49BFB2C01A35206D310C11C269E" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_FA821F998269DA289B0ED310C11DEAF3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_97076E6A821D2A1A7D9BD310C11D6257" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_B0F6F49BFB2C01A35206D310C11C269E" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_97076E6A821D2A1A7D9BD310C11D6257" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_A126D6CE7E4133789862D310C11D5DDC" xlink:to="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanServiceCost" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_3731CAB6BD4C9B878941D310C11E15CF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_3731CAB6BD4C9B878941D310C11E15CF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanInterestCost" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_04680F3284C681B1936AD310C11E964A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_04680F3284C681B1936AD310C11E964A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_10831A1ABE1A87E33EFCD310C11EB0F5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_10831A1ABE1A87E33EFCD310C11EB0F5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_AB1654D9B9ED637077DAD310C11EE615" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_AB1654D9B9ED637077DAD310C11EE615" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_41F242733126D9E461E5D310C11E8E7F" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_41F242733126D9E461E5D310C11E8E7F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments_5FC48907A1F6DA97D95AD310C11E696E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments_5FC48907A1F6DA97D95AD310C11E696E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_10A7F0785E19988112F1D310C11FE595" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_10A7F0785E19988112F1D310C11FE595" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_15C71BAFA23504CAF41ED310C11F0DA0" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_3B06E3FA0EEE41C21EF8D310C11D995F" xlink:to="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_15C71BAFA23504CAF41ED310C11F0DA0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_13E0318BD3B9C2F5A56FD310C11FAEA0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_A126D6CE7E4133789862D310C11D5DDC" xlink:to="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_13E0318BD3B9C2F5A56FD310C11FAEA0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax_CBEFDD83954248AAA0C7D310C11F2111" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_13E0318BD3B9C2F5A56FD310C11FAEA0" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax_CBEFDD83954248AAA0C7D310C11F2111" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax_DCB65E914E1A4B9061B8D310C12072FD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_13E0318BD3B9C2F5A56FD310C11FAEA0" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax_DCB65E914E1A4B9061B8D310C12072FD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax_EEF2217E80C21CA4537ED310C12067A6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_13E0318BD3B9C2F5A56FD310C11FAEA0" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax_EEF2217E80C21CA4537ED310C12067A6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax" xlink:label="loc_us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax_3FEC9D6E512224770462D310C12027E3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_A126D6CE7E4133789862D310C11D5DDC" xlink:to="loc_us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax_3FEC9D6E512224770462D310C12027E3" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AAE0DEF52AC848EB7C2AD7DCC2EBDB60" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AAE0DEF52AC848EB7C2AD7DCC2EBDB60" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_62790C40C0AB23EAFAA9D7DCC2EB35A1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AAE0DEF52AC848EB7C2AD7DCC2EBDB60" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_62790C40C0AB23EAFAA9D7DCC2EB35A1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_5E693CFC656A8476AADAD7DCC2EB1DC7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_62790C40C0AB23EAFAA9D7DCC2EB35A1" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_5E693CFC656A8476AADAD7DCC2EB1DC7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_5E693CFC656A8476AADAD7DCC2EB1DC7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_62790C40C0AB23EAFAA9D7DCC2EB35A1" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_5E693CFC656A8476AADAD7DCC2EB1DC7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_00A01E6E80217A295560D7DCC2EBDCBE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_5E693CFC656A8476AADAD7DCC2EB1DC7" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_00A01E6E80217A295560D7DCC2EBDCBE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_50CF5E5103FBA91E616AD7DCC2EB6FFD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_5E693CFC656A8476AADAD7DCC2EB1DC7" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_50CF5E5103FBA91E616AD7DCC2EB6FFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward" xlink:label="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:to="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanBenefitObligation_330F876448CBCB223F17D7DCC2EBCF16" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanBenefitObligation_330F876448CBCB223F17D7DCC2EBCF16" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanServiceCost" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_728E0CF5B84E2E8A077DD7DCC2EBF097" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_728E0CF5B84E2E8A077DD7DCC2EBF097" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanInterestCost" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_3959FA967B6B40553C0BD7DCC2EB6B8B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_3959FA967B6B40553C0BD7DCC2EB6B8B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanActuarialGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_4C64D040CF3A4AACE026D7DCC2EBF9DE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_4C64D040CF3A4AACE026D7DCC2EBF9DE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanCurtailments" xlink:label="loc_us-gaap_DefinedBenefitPlanCurtailments_3EDAD8AAF38CAC63EA4DD7DCC2EB73A8" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanCurtailments_3EDAD8AAF38CAC63EA4DD7DCC2EB73A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanSettlementsBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanSettlementsBenefitObligation_8A589440BBCF803DACE6D7DCC2EB5F9E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanSettlementsBenefitObligation_8A589440BBCF803DACE6D7DCC2EB5F9E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation_D00EA7F9A458C2920C7AD7DCC2EB37F0" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation_D00EA7F9A458C2920C7AD7DCC2EB37F0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid" xlink:label="loc_us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid_E998BA39F02BD74BFAB7D7DCC2EBEFE9" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_F4EC6456F7E960673D1ED7DCC2EB60E1" xlink:to="loc_us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid_E998BA39F02BD74BFAB7D7DCC2EBEFE9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward" xlink:label="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:to="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanFairValueOfPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_7B4D15CBBDB14AC27C27D7DCC2EB7E0F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:to="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_7B4D15CBBDB14AC27C27D7DCC2EB7E0F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets_31234657881B829DEBB1D7DCC2FB224D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:to="loc_us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets_31234657881B829DEBB1D7DCC2FB224D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanContributionsByEmployer" xlink:label="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_841D0A83A21938B5A903D7DCC2FBB1A3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:to="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_841D0A83A21938B5A903D7DCC2FBB1A3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanSettlementsPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanSettlementsPlanAssets_C91D550B3AB43722EB4FD7DCC2FB36E6" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:to="loc_us-gaap_DefinedBenefitPlanSettlementsPlanAssets_C91D550B3AB43722EB4FD7DCC2FB36E6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss_617B3083F48F514B2FA1D7DCC2FB6C0F" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss_617B3083F48F514B2FA1D7DCC2FB6C0F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid_2D5144FB00694E84DEA8D7DCC2FB1A29" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_F3CFE5ECDFC03FACE80AD7DCC2EB3FB4" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid_2D5144FB00694E84DEA8D7DCC2FB1A29" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanFundedStatusOfPlan" xlink:label="loc_us-gaap_DefinedBenefitPlanFundedStatusOfPlan_E6ABC822B25CAA82C954D7DCC2FB56A5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:to="loc_us-gaap_DefinedBenefitPlanFundedStatusOfPlan_E6ABC822B25CAA82C954D7DCC2FB56A5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_F4C86E7807FD42954ED7D7DCC2FB837B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_F4C86E7807FD42954ED7D7DCC2FB837B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent" xlink:label="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_5C74231093F53A670A6DD7DCC2FB5C10" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_F4C86E7807FD42954ED7D7DCC2FB837B" xlink:to="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_5C74231093F53A670A6DD7DCC2FB5C10" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities" xlink:label="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities_F0145E7504E80471A7C6D7DCC2FB878E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_F4C86E7807FD42954ED7D7DCC2FB837B" xlink:to="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities_F0145E7504E80471A7C6D7DCC2FB878E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent" xlink:label="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent_3E4930CB528DE21884F5D7DCC2FBFBA1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_F4C86E7807FD42954ED7D7DCC2FB837B" xlink:to="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent_3E4930CB528DE21884F5D7DCC2FBFBA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet_C16FABB84C292F68B732D7DCC2FBACE6" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_F4C86E7807FD42954ED7D7DCC2FB837B" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet_C16FABB84C292F68B732D7DCC2FBACE6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_4AEDD9D7F7F6052F2B6BD7DCC2FB606D" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_4285FA0886FA5066E56DD7DCC2EB9965" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_4AEDD9D7F7F6052F2B6BD7DCC2FB606D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax_D60E2B6D41E468EEDB9FD7DCC2FB6AD6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_4AEDD9D7F7F6052F2B6BD7DCC2FB606D" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax_D60E2B6D41E468EEDB9FD7DCC2FB6AD6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax_564C236A8987AC450378D7DCC2FBA71B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_4AEDD9D7F7F6052F2B6BD7DCC2FB606D" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax_564C236A8987AC450378D7DCC2FBA71B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_757AC36ADBB5DADBC336D7DCC2FB1FB4" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_4AEDD9D7F7F6052F2B6BD7DCC2FB606D" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_757AC36ADBB5DADBC336D7DCC2FB1FB4" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_53CBCD11F598C2196CC4C82606A79407" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_53CBCD11F598C2196CC4C82606A79407" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_E300B864200A3F1193D5C82606A801CF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_53CBCD11F598C2196CC4C82606A79407" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_E300B864200A3F1193D5C82606A801CF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_EC4008650FA9FB5B8F20C82606A87926_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_E300B864200A3F1193D5C82606A801CF" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_EC4008650FA9FB5B8F20C82606A87926_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_EC4008650FA9FB5B8F20C82606A87926" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_E300B864200A3F1193D5C82606A801CF" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_EC4008650FA9FB5B8F20C82606A87926" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_21BC095CF953E595B008C82606A86105" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_EC4008650FA9FB5B8F20C82606A87926" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_21BC095CF953E595B008C82606A86105" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_525562E41D5C1F8E4FA3C82606A83DC3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_EC4008650FA9FB5B8F20C82606A87926" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_525562E41D5C1F8E4FA3C82606A83DC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths_CB88AA05E800DE674873C82606A9D151" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths_CB88AA05E800DE674873C82606A9D151" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo_4CB33CEAE5BC5EDC0EC5C82606A9D180" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo_4CB33CEAE5BC5EDC0EC5C82606A9D180" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree_A0B2BBDFB8F80560422BC82606A9A7BA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree_A0B2BBDFB8F80560422BC82606A9A7BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour_E8B3326FD3BA86A90A82C82606AA865B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour_E8B3326FD3BA86A90A82C82606AA865B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive_0B92F2287334F9031CC8C82606AA07F3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive_0B92F2287334F9031CC8C82606AA07F3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter_825E5087B4790F7FEE91C82606AAD46C" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_3248413A9077817609F8C82606A9C97C" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter_825E5087B4790F7FEE91C82606AAD46C" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E4A91DE925CF9111D2EED310C0F8FDB7" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FD5DE2CE89F00E4EE37D310C0F38588" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E4A91DE925CF9111D2EED310C0F8FDB7" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FD5DE2CE89F00E4EE37D310C0F38588" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2A08949C53D749CA5BABD310C0F3C677" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FD5DE2CE89F00E4EE37D310C0F38588" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2A08949C53D749CA5BABD310C0F3C677" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_B486A20C590A38DEB102D310C0F369EA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2A08949C53D749CA5BABD310C0F3C677" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_B486A20C590A38DEB102D310C0F369EA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_B486A20C590A38DEB102D310C0F369EA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_2A08949C53D749CA5BABD310C0F3C677" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_B486A20C590A38DEB102D310C0F369EA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_3C7B6EF896E5DD8B08B6D310C0F32BFE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_B486A20C590A38DEB102D310C0F369EA" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_3C7B6EF896E5DD8B08B6D310C0F32BFE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_F447B84DA92366AC9737D310C0F4D15C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FD5DE2CE89F00E4EE37D310C0F38588" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_F447B84DA92366AC9737D310C0F4D15C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_F7715EB66EB0C9D23171D310C0F45619_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_F447B84DA92366AC9737D310C0F4D15C" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_F7715EB66EB0C9D23171D310C0F45619_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_F7715EB66EB0C9D23171D310C0F45619" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_F447B84DA92366AC9737D310C0F4D15C" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_F7715EB66EB0C9D23171D310C0F45619" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_D0A1C79D46D64302777ED310C0F4531D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_F7715EB66EB0C9D23171D310C0F45619" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_D0A1C79D46D64302777ED310C0F4531D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis" xlink:label="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_ABB9CE57B53D8B1EF8A3D310C0F422F5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FD5DE2CE89F00E4EE37D310C0F38588" xlink:to="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_ABB9CE57B53D8B1EF8A3D310C0F422F5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_ABB9CE57B53D8B1EF8A3D310C0F422F5" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_ABB9CE57B53D8B1EF8A3D310C0F422F5" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashAndCashEquivalentsMember" xlink:label="loc_us-gaap_CashAndCashEquivalentsMember_BF04831997AD5F023FB1D310C0F54EF0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_us-gaap_CashAndCashEquivalentsMember_BF04831997AD5F023FB1D310C0F54EF0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_GlobalAllCapMember" xlink:label="loc_hsy_GlobalAllCapMember_A82DFF725ACC71F5B5C0D310C0F57C0E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_hsy_GlobalAllCapMember_A82DFF725ACC71F5B5C0D310C0F57C0E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_USTreasuryAndGovernmentMember" xlink:label="loc_us-gaap_USTreasuryAndGovernmentMember_80868466C998DA73A3FDD310C0F5CB04" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_us-gaap_USTreasuryAndGovernmentMember_80868466C998DA73A3FDD310C0F5CB04" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CorporateBondSecuritiesMember" xlink:label="loc_us-gaap_CorporateBondSecuritiesMember_E60DFDF1D130D2B490DBD310C0F683F9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_us-gaap_CorporateBondSecuritiesMember_E60DFDF1D130D2B490DBD310C0F683F9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ForeignGovernmentDebtSecuritiesMember" xlink:label="loc_us-gaap_ForeignGovernmentDebtSecuritiesMember_97E01D0582811E2818B5D310C0F62B97" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_us-gaap_ForeignGovernmentDebtSecuritiesMember_97E01D0582811E2818B5D310C0F62B97" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DiversifiedcreditMember" xlink:label="loc_hsy_DiversifiedcreditMember_5840169CD5EEA7D5A5B6D310C0F60CF8" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_hsy_DiversifiedcreditMember_5840169CD5EEA7D5A5B6D310C0F60CF8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_GlobaldiversifiedassetsMember" xlink:label="loc_hsy_GlobaldiversifiedassetsMember_727FACAE392152353F89D310C0F6A11A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_hsy_GlobaldiversifiedassetsMember_727FACAE392152353F89D310C0F6A11A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_GlobalrealestateinvestmenttrustsMember" xlink:label="loc_hsy_GlobalrealestateinvestmenttrustsMember_7DEA3F7ED7F5DEFBBA23D310C0F6CED8" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_hsy_GlobalrealestateinvestmenttrustsMember_7DEA3F7ED7F5DEFBBA23D310C0F6CED8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_GlobalinfrastructureMember" xlink:label="loc_hsy_GlobalinfrastructureMember_DB8DD5A13FC35C5D6026D310C0F771DD" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_8FDD0BBD6013825F0172D310C0F5E73D" xlink:to="loc_hsy_GlobalinfrastructureMember_DB8DD5A13FC35C5D6026D310C0F771DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_944121AA3729721090B9D310C0F7A688" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FD5DE2CE89F00E4EE37D310C0F38588" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_944121AA3729721090B9D310C0F7A688" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_944121AA3729721090B9D310C0F7A688" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_944121AA3729721090B9D310C0F7A688" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel1Member" xlink:label="loc_us-gaap_FairValueInputsLevel1Member_0D0B5A113A15384DD77DD310C0F7569D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_0D0B5A113A15384DD77DD310C0F7569D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_2B286AD5F85F325D2750D310C0F8ED26" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_2B286AD5F85F325D2750D310C0F8ED26" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_B18EE131E10A92D1B6F1D310C0F89A4B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_9B97025DCC911B9339F2D310C0F7D91C" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_B18EE131E10A92D1B6F1D310C0F89A4B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanFairValueOfPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_EA003C6815F5253F3BB9D310C0F8D62A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E4A91DE925CF9111D2EED310C0F8FDB7" xlink:to="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_EA003C6815F5253F3BB9D310C0F8D62A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue" xlink:label="loc_hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue_BAD49A9422111DF290CCD310C0F88396" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E4A91DE925CF9111D2EED310C0F8FDB7" xlink:to="loc_hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue_BAD49A9422111DF290CCD310C0F88396" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8741931DC00A852A2BE5AD1BB9264452" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_EE6D767C6AE6F14E3817AD1BB9234FA6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8741931DC00A852A2BE5AD1BB9264452" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_EE6D767C6AE6F14E3817AD1BB9234FA6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_469D16C59960DE83E618AD1BB923D11C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_EE6D767C6AE6F14E3817AD1BB9234FA6" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_469D16C59960DE83E618AD1BB923D11C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_A4BF41B9CC0518E1DE54AD1BB9240C2C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_469D16C59960DE83E618AD1BB923D11C" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_A4BF41B9CC0518E1DE54AD1BB9240C2C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_A4BF41B9CC0518E1DE54AD1BB9240C2C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_469D16C59960DE83E618AD1BB923D11C" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_A4BF41B9CC0518E1DE54AD1BB9240C2C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DomesticPlanMember" xlink:label="loc_us-gaap_DomesticPlanMember_EF9C9EF72BB4409900B7AD1BB924106C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_A4BF41B9CC0518E1DE54AD1BB9240C2C" xlink:to="loc_us-gaap_DomesticPlanMember_EF9C9EF72BB4409900B7AD1BB924106C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis" xlink:label="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_2D2AC4F668A83EE20CC1AD1BB9240D42" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_EE6D767C6AE6F14E3817AD1BB9234FA6" xlink:to="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_2D2AC4F668A83EE20CC1AD1BB9240D42" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_2D2AC4F668A83EE20CC1AD1BB9240D42" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_2D2AC4F668A83EE20CC1AD1BB9240D42" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CashAndCashEquivalentsMember" xlink:label="loc_us-gaap_CashAndCashEquivalentsMember_738865DBD29D5B046DBAAD1BB925F171" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02" xlink:to="loc_us-gaap_CashAndCashEquivalentsMember_738865DBD29D5B046DBAAD1BB925F171" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquitySecuritiesMember" xlink:label="loc_us-gaap_EquitySecuritiesMember_141ED816C52648D7F269AD1BB92553A3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02" xlink:to="loc_us-gaap_EquitySecuritiesMember_141ED816C52648D7F269AD1BB92553A3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtSecuritiesMember" xlink:label="loc_us-gaap_DebtSecuritiesMember_111E1EC510A1ABC693ADAD1BB9253035" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02" xlink:to="loc_us-gaap_DebtSecuritiesMember_111E1EC510A1ABC693ADAD1BB9253035" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherInvestmentsMember" xlink:label="loc_us-gaap_OtherInvestmentsMember_CA06F3DABB5BE6DA6C5DAD1BB9260944" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_1C628658949209F4B864AD1BB9246B02" xlink:to="loc_us-gaap_OtherInvestmentsMember_CA06F3DABB5BE6DA6C5DAD1BB9260944" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage_FBAE0D6E75279CE063D6AD1BB926D192" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8741931DC00A852A2BE5AD1BB9264452" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage_FBAE0D6E75279CE063D6AD1BB926D192" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0146B198720BA10F3FECD310C10F867C" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C9952702AB04B4E45AF9D310C10E2B7E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0146B198720BA10F3FECD310C10F867C" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C9952702AB04B4E45AF9D310C10E2B7E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_D41660722F9BD909D642D310C10EE949" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C9952702AB04B4E45AF9D310C10E2B7E" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_D41660722F9BD909D642D310C10EE949" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_17F9401099AEE2EE3411D310C10E192B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_D41660722F9BD909D642D310C10EE949" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_17F9401099AEE2EE3411D310C10E192B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_17F9401099AEE2EE3411D310C10E192B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_D41660722F9BD909D642D310C10EE949" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_17F9401099AEE2EE3411D310C10E192B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_B8368D9F11B10A157E83D310C10E343E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_17F9401099AEE2EE3411D310C10E192B" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_B8368D9F11B10A157E83D310C10E343E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_DBD120DC7D73DFCAE099D310C10F5C43" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_17F9401099AEE2EE3411D310C10E192B" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_DBD120DC7D73DFCAE099D310C10F5C43" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_ED13431E0BA3F7C92983D310C10F5CF5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0146B198720BA10F3FECD310C10F867C" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_ED13431E0BA3F7C92983D310C10F5CF5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease_19AE3B019DBC392D1AA4D310C10F6E54" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0146B198720BA10F3FECD310C10F867C" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease_19AE3B019DBC392D1AA4D310C10F6E54" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationWeightedAverageInterestCreditingRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationWeightedAverageInterestCreditingRate_761BAB22CE4FB7BF7E90D3C4935B9C7F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0146B198720BA10F3FECD310C10F867C" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationWeightedAverageInterestCreditingRate_761BAB22CE4FB7BF7E90D3C4935B9C7F" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_AE5C283EC0CFFEF8F88BD310C10AF65F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_67FA4A95A4F83B2285F0D310C1085B23" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_AE5C283EC0CFFEF8F88BD310C10AF65F" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_67FA4A95A4F83B2285F0D310C1085B23" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_97A551EA41C1A953C151D310C108FD27" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_67FA4A95A4F83B2285F0D310C1085B23" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_97A551EA41C1A953C151D310C108FD27" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_937641A2D5229A3272A7D310C109E4A7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_97A551EA41C1A953C151D310C108FD27" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_937641A2D5229A3272A7D310C109E4A7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_937641A2D5229A3272A7D310C109E4A7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_97A551EA41C1A953C151D310C108FD27" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_937641A2D5229A3272A7D310C109E4A7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_2C1C837139A0D0EEAD3AD310C109EF07" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_937641A2D5229A3272A7D310C109E4A7" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_2C1C837139A0D0EEAD3AD310C109EF07" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_BA10AA5FD2CA9219BBE4D310C109D503" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_937641A2D5229A3272A7D310C109E4A7" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_BA10AA5FD2CA9219BBE4D310C109D503" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate_4316522FC5E21CD937ACD310C10ABDC1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_AE5C283EC0CFFEF8F88BD310C10AF65F" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate_4316522FC5E21CD937ACD310C10ABDC1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets_F794C17634F1A09569F5D310C10AF9B7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_AE5C283EC0CFFEF8F88BD310C10AF65F" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets_F794C17634F1A09569F5D310C10AF9B7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease_FC9C5A43486723470A61D310C10A1AFF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_AE5C283EC0CFFEF8F88BD310C10AF65F" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease_FC9C5A43486723470A61D310C10A1AFF" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/QuarterlyDataTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/QuarterlyDataUnaudited" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/QuarterlyDataUnauditedScheduleOfQuarterlyFinancialInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_48B894BFC088370536990C3B41C35966" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_StatementTable_48B894BFC088370536990C3B41C35966" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_550B93C0F6BB2CF803920C3B41C3811A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_48B894BFC088370536990C3B41C35966" xlink:to="loc_us-gaap_StatementClassOfStockAxis_550B93C0F6BB2CF803920C3B41C3811A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_62E14E2BBD302AD3FB5F0C3B41C32A7B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_550B93C0F6BB2CF803920C3B41C3811A" xlink:to="loc_us-gaap_ClassOfStockDomain_62E14E2BBD302AD3FB5F0C3B41C32A7B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_62E14E2BBD302AD3FB5F0C3B41C32A7B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_550B93C0F6BB2CF803920C3B41C3811A" xlink:to="loc_us-gaap_ClassOfStockDomain_62E14E2BBD302AD3FB5F0C3B41C32A7B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_0C9BA4BAF678984B06B90C3B41C466E0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_62E14E2BBD302AD3FB5F0C3B41C32A7B" xlink:to="loc_us-gaap_CommonStockMember_0C9BA4BAF678984B06B90C3B41C466E0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_1B4FAD645DFE29C89FEE0C3B41C4C3E0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_62E14E2BBD302AD3FB5F0C3B41C32A7B" xlink:to="loc_us-gaap_CommonClassBMember_1B4FAD645DFE29C89FEE0C3B41C4C3E0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_E8900F329901991634A20C3B41C466D7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_48B894BFC088370536990C3B41C35966" xlink:to="loc_srt_RangeAxis_E8900F329901991634A20C3B41C466D7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_5E6D6A6152515500953D0C3B41C4AF3B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_E8900F329901991634A20C3B41C466D7" xlink:to="loc_srt_RangeMember_5E6D6A6152515500953D0C3B41C4AF3B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_5E6D6A6152515500953D0C3B41C4AF3B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_E8900F329901991634A20C3B41C466D7" xlink:to="loc_srt_RangeMember_5E6D6A6152515500953D0C3B41C4AF3B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_AAE5515CA9A1E1D773BC0C3B41C57051" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_5E6D6A6152515500953D0C3B41C4AF3B" xlink:to="loc_srt_MaximumMember_AAE5515CA9A1E1D773BC0C3B41C57051" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_F1AC2D844D3865EE640B0C3B41C59D53" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_5E6D6A6152515500953D0C3B41C4AF3B" xlink:to="loc_srt_MinimumMember_F1AC2D844D3865EE640B0C3B41C59D53" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_6BA299BB6458D6DFB73D0C3B41C5CC7E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_Revenues_6BA299BB6458D6DFB73D0C3B41C5CC7E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GrossProfit" xlink:label="loc_us-gaap_GrossProfit_3C44825D2E4623969A8C0C3B41C60C3C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_GrossProfit_3C44825D2E4623969A8C0C3B41C60C3C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_50EAD14C16AF720C4E750C3B41C66566" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_NetIncomeLoss_50EAD14C16AF720C4E750C3B41C66566" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_43D888ABAAF175C11E710C3B41C6F9E1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_EarningsPerShareBasic_43D888ABAAF175C11E710C3B41C6F9E1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_65A6325E4B7CAA647A480C3B41C6F9CE" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_EarningsPerShareDiluted_65A6325E4B7CAA647A480C3B41C6F9CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_30B2A95F5A577C427FA80C3B41C68BAA" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_30B2A95F5A577C427FA80C3B41C68BAA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_9ED53A02C62DC0CD09EF0C3B41C69145" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_D1B353DEAB7D35C3BC620C3B41C57826" xlink:to="loc_us-gaap_SharePrice_9ED53A02C62DC0CD09EF0C3B41C69145" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccounts" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureLineItems" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_8F888A20AEDB9BC491B30C3B41BF3913" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureTable" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_C44449D5930EF1CF82C30C3B41BE29BD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_8F888A20AEDB9BC491B30C3B41BF3913" xlink:to="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_C44449D5930EF1CF82C30C3B41BE29BD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesTypeAxis" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_B296B579CAA70BEEBEC90C3B41BEFD7A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_C44449D5930EF1CF82C30C3B41BE29BD" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_B296B579CAA70BEEBEC90C3B41BEFD7A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_A2B8FE397723163F95850C3B41BE838B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_B296B579CAA70BEEBEC90C3B41BEFD7A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_A2B8FE397723163F95850C3B41BE838B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_A2B8FE397723163F95850C3B41BE838B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_B296B579CAA70BEEBEC90C3B41BEFD7A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_A2B8FE397723163F95850C3B41BE838B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScheduleOfValuationAndQualifyingAccountsDisclosureTextBlock" xlink:label="loc_srt_ScheduleOfValuationAndQualifyingAccountsDisclosureTextBlock_8DAFFF134525BC0C29BF0C3B41BF8192" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_8F888A20AEDB9BC491B30C3B41BF3913" xlink:to="loc_srt_ScheduleOfValuationAndQualifyingAccountsDisclosureTextBlock_8DAFFF134525BC0C29BF0C3B41BF8192" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureLineItems" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_76EC8EF8FB045D0806D30C3B41B82589" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureTable" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_C6FBCA042F04C4C3113A0C3B41B76B98" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_76EC8EF8FB045D0806D30C3B41B82589" xlink:to="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_C6FBCA042F04C4C3113A0C3B41B76B98" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesTypeAxis" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_C0621E658211EE5389160C3B41B7B18A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_C6FBCA042F04C4C3113A0C3B41B76B98" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_C0621E658211EE5389160C3B41B7B18A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_C0621E658211EE5389160C3B41B7B18A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_C0621E658211EE5389160C3B41B7B18A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AllowanceForCreditLossMember" xlink:label="loc_us-gaap_AllowanceForCreditLossMember_C63A0CA1B77E4EC3A5AB0C3B41B80685" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB" xlink:to="loc_us-gaap_AllowanceForCreditLossMember_C63A0CA1B77E4EC3A5AB0C3B41B80685" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember" xlink:label="loc_us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember_801CC13D96BC9E5DAC240C3B41B89C13" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB" xlink:to="loc_us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember_801CC13D96BC9E5DAC240C3B41B89C13" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InventoryValuationReserveMember" xlink:label="loc_us-gaap_InventoryValuationReserveMember_52A5FA83183892B7E6A40C3B41B8EA6F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_CEBB711CE8360F7EB8840C3B41B73DDB" xlink:to="loc_us-gaap_InventoryValuationReserveMember_52A5FA83183892B7E6A40C3B41B8EA6F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesBalance" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesBalance_210B38234FBC1BF61EE70C3B41B89E3F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_76EC8EF8FB045D0806D30C3B41B82589" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesBalance_210B38234FBC1BF61EE70C3B41B89E3F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense_5CA0502E7460EFD19F920C3B41B9A159" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_76EC8EF8FB045D0806D30C3B41B82589" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense_5CA0502E7460EFD19F920C3B41B9A159" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts_C5A8D009196C7C93F0660C3B41B98C5D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_76EC8EF8FB045D0806D30C3B41B82589" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts_C5A8D009196C7C93F0660C3B41B98C5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDeductions" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDeductions_022E51C1FA06C40BEC740C3B41B9A6B1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_76EC8EF8FB045D0806D30C3B41B82589" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDeductions_022E51C1FA06C40BEC740C3B41B9A6B1" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformation" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EntityWideRevenueMajorCustomerLineItems" xlink:label="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_A783ABD29D26AB3DBDF1358E537C12BB" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable" xlink:label="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_A783ABD29D26AB3DBDF1358E537C12BB" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_E6FA38880C2ADD159B92358E537124C3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_E6FA38880C2ADD159B92358E537124C3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_5B4276BCBBA524E3F428358E5371DD91_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_E6FA38880C2ADD159B92358E537124C3" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_5B4276BCBBA524E3F428358E5371DD91_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_5B4276BCBBA524E3F428358E5371DD91" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_E6FA38880C2ADD159B92358E537124C3" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_5B4276BCBBA524E3F428358E5371DD91" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CostOfSalesMember" xlink:label="loc_us-gaap_CostOfSalesMember_6ACD993221ED90FEB20F358E53729267" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_5B4276BCBBA524E3F428358E5371DD91" xlink:to="loc_us-gaap_CostOfSalesMember_6ACD993221ED90FEB20F358E53729267" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_StatementScenarioAxis" xlink:label="loc_srt_StatementScenarioAxis_3FD09478A541D6E07191358E5372F348" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_srt_StatementScenarioAxis_3FD09478A541D6E07191358E5372F348" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_A231AF7E1148DEEDF604358E53724E57_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_StatementScenarioAxis_3FD09478A541D6E07191358E5372F348" xlink:to="loc_srt_ScenarioUnspecifiedDomain_A231AF7E1148DEEDF604358E53724E57_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioUnspecifiedDomain" xlink:label="loc_srt_ScenarioUnspecifiedDomain_A231AF7E1148DEEDF604358E53724E57" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_StatementScenarioAxis_3FD09478A541D6E07191358E5372F348" xlink:to="loc_srt_ScenarioUnspecifiedDomain_A231AF7E1148DEEDF604358E53724E57" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ScenarioForecastMember" xlink:label="loc_srt_ScenarioForecastMember_D8C620D0B0E6B017C084358E53729CC3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ScenarioUnspecifiedDomain_A231AF7E1148DEEDF604358E53724E57" xlink:to="loc_srt_ScenarioForecastMember_D8C620D0B0E6B017C084358E53729CC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_EB2BA38AA190406B8619358E5373D80B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_srt_ConsolidationItemsAxis_EB2BA38AA190406B8619358E5373D80B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_36CACD1BA75AFA25FC6D358E53736124_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_EB2BA38AA190406B8619358E5373D80B" xlink:to="loc_srt_ConsolidationItemsDomain_36CACD1BA75AFA25FC6D358E53736124_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_36CACD1BA75AFA25FC6D358E53736124" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_EB2BA38AA190406B8619358E5373D80B" xlink:to="loc_srt_ConsolidationItemsDomain_36CACD1BA75AFA25FC6D358E53736124" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_B9F066355014409F223C358E537836EE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_36CACD1BA75AFA25FC6D358E53736124" xlink:to="loc_us-gaap_OperatingSegmentsMember_B9F066355014409F223C358E537836EE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_27613579B91CC3A66554358E53790C31" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_27613579B91CC3A66554358E53790C31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_995943765209FF33FB33358E5379F063_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_27613579B91CC3A66554358E53790C31" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_995943765209FF33FB33358E5379F063_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_995943765209FF33FB33358E5379F063" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_27613579B91CC3A66554358E53790C31" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_995943765209FF33FB33358E5379F063" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_DB29313DB1FE87E399AC358E5379B5F7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_995943765209FF33FB33358E5379F063" xlink:to="loc_us-gaap_CommodityContractMember_DB29313DB1FE87E399AC358E5379B5F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_CA9E03C394A8E0BF2B46358E537A4D97" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_CA9E03C394A8E0BF2B46358E537A4D97" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_662642A2CCAE745CE734358E537A560C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_CA9E03C394A8E0BF2B46358E537A4D97" xlink:to="loc_us-gaap_SegmentDomain_662642A2CCAE745CE734358E537A560C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_662642A2CCAE745CE734358E537A560C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_CA9E03C394A8E0BF2B46358E537A4D97" xlink:to="loc_us-gaap_SegmentDomain_662642A2CCAE745CE734358E537A560C" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_98F36756BA56C19FC463358E537AADCD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_662642A2CCAE745CE734358E537A560C" xlink:to="loc_hsy_NorthAmericaSegmentMember_98F36756BA56C19FC463358E537AADCD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_15AF1BF6BE48C82E1544358E537AD15A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_15AF1BF6BE48C82E1544358E537AD15A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_70AC51550C789CDB2447358E537B3481_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_15AF1BF6BE48C82E1544358E537AD15A" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_70AC51550C789CDB2447358E537B3481_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_70AC51550C789CDB2447358E537B3481" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_15AF1BF6BE48C82E1544358E537AD15A" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_70AC51550C789CDB2447358E537B3481" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GeographicConcentrationRiskMember" xlink:label="loc_us-gaap_GeographicConcentrationRiskMember_2D77D02BB379BF6AF59A358E537BE7EF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_70AC51550C789CDB2447358E537B3481" xlink:to="loc_us-gaap_GeographicConcentrationRiskMember_2D77D02BB379BF6AF59A358E537BE7EF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_D5B58811DEBACB4A87AD358E537B573A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_B10E74BF622E1A02C78F358E53710D3C" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_D5B58811DEBACB4A87AD358E537B573A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_7F5520DD46057F468BB9358E537B3BAB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_D5B58811DEBACB4A87AD358E537B573A" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_7F5520DD46057F468BB9358E537B3BAB_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_7F5520DD46057F468BB9358E537B3BAB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_D5B58811DEBACB4A87AD358E537B573A" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_7F5520DD46057F468BB9358E537B3BAB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevenueFromContractWithCustomerMember" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerMember_2A48A3A8D4F096EBBEB6358E537C05C5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_7F5520DD46057F468BB9358E537B3BAB" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerMember_2A48A3A8D4F096EBBEB6358E537C05C5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_39408CB8F8386F4C5AF9358E537C7DB2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_A783ABD29D26AB3DBDF1358E537C12BB" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_39408CB8F8386F4C5AF9358E537C7DB2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CumulativeAmountofMarktoMarketGainesLossesonCommodityDerivatives" xlink:label="loc_hsy_CumulativeAmountofMarktoMarketGainesLossesonCommodityDerivatives_E74EC75814A4F4A5C7B2358E537D1E52" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_A783ABD29D26AB3DBDF1358E537C12BB" xlink:to="loc_hsy_CumulativeAmountofMarktoMarketGainesLossesonCommodityDerivatives_E74EC75814A4F4A5C7B2358E537D1E52" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome" xlink:label="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_A510AD6ADE1251DBBB32358E537D77FE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_A783ABD29D26AB3DBDF1358E537C12BB" xlink:to="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_A510AD6ADE1251DBBB32358E537D77FE" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationScheduleOfAdditionalProductLineSalesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_CD46DE4A3B1A79CF60FF0C3B426C5205" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D59E9F99C7EE6B205AC20C3B426B8EBF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_CD46DE4A3B1A79CF60FF0C3B426C5205" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D59E9F99C7EE6B205AC20C3B426B8EBF" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ProductOrServiceAxis" xlink:label="loc_srt_ProductOrServiceAxis_3770461FA8E99A6A60FC0C3B426BC1BB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D59E9F99C7EE6B205AC20C3B426B8EBF" xlink:to="loc_srt_ProductOrServiceAxis_3770461FA8E99A6A60FC0C3B426BC1BB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ProductsAndServicesDomain" xlink:label="loc_srt_ProductsAndServicesDomain_371F2C42073C37EB78AC0C3B426BFD22_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ProductOrServiceAxis_3770461FA8E99A6A60FC0C3B426BC1BB" xlink:to="loc_srt_ProductsAndServicesDomain_371F2C42073C37EB78AC0C3B426BFD22_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ProductsAndServicesDomain" xlink:label="loc_srt_ProductsAndServicesDomain_371F2C42073C37EB78AC0C3B426BFD22" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ProductOrServiceAxis_3770461FA8E99A6A60FC0C3B426BC1BB" xlink:to="loc_srt_ProductsAndServicesDomain_371F2C42073C37EB78AC0C3B426BFD22" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ConfectioneryandConfectionerybasedPortfolioMember" xlink:label="loc_hsy_ConfectioneryandConfectionerybasedPortfolioMember_64D8C08CA6884A0034140C3B426B1F90" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ProductsAndServicesDomain_371F2C42073C37EB78AC0C3B426BFD22" xlink:to="loc_hsy_ConfectioneryandConfectionerybasedPortfolioMember_64D8C08CA6884A0034140C3B426B1F90" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_SnacksPortfolioMember" xlink:label="loc_hsy_SnacksPortfolioMember_ACF2E4106631875B74E00C3B426C7A90" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ProductsAndServicesDomain_371F2C42073C37EB78AC0C3B426BFD22" xlink:to="loc_hsy_SnacksPortfolioMember_ACF2E4106631875B74E00C3B426C7A90" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_F698F1B41B75BF93017B0C3B426CA8E9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_CD46DE4A3B1A79CF60FF0C3B426C5205" xlink:to="loc_us-gaap_Revenues_F698F1B41B75BF93017B0C3B426CA8E9" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_7043DE4A854B27E0E4390C3B4288B5FC" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_AE508427872BEBC5D10E0C3B428679DF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_7043DE4A854B27E0E4390C3B4288B5FC" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_AE508427872BEBC5D10E0C3B428679DF" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_5D3851A636912F6460230C3B42865F38" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_AE508427872BEBC5D10E0C3B428679DF" xlink:to="loc_srt_ConsolidationItemsAxis_5D3851A636912F6460230C3B42865F38" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_39F746892A50B67AA7D40C3B42879003_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_5D3851A636912F6460230C3B42865F38" xlink:to="loc_srt_ConsolidationItemsDomain_39F746892A50B67AA7D40C3B42879003_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_39F746892A50B67AA7D40C3B42879003" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_5D3851A636912F6460230C3B42865F38" xlink:to="loc_srt_ConsolidationItemsDomain_39F746892A50B67AA7D40C3B42879003" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_7928F7A5E61B6B8C5C970C3B4287915E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_39F746892A50B67AA7D40C3B42879003" xlink:to="loc_us-gaap_OperatingSegmentsMember_7928F7A5E61B6B8C5C970C3B4287915E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CorporateNonSegmentMember" xlink:label="loc_us-gaap_CorporateNonSegmentMember_573BB19EB49879995C570C3B4287547C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_39F746892A50B67AA7D40C3B42879003" xlink:to="loc_us-gaap_CorporateNonSegmentMember_573BB19EB49879995C570C3B4287547C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_4D11C906D04B42A18D9B0C3B42873440" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_AE508427872BEBC5D10E0C3B428679DF" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_4D11C906D04B42A18D9B0C3B42873440" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_4D11C906D04B42A18D9B0C3B42873440" xlink:to="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_4D11C906D04B42A18D9B0C3B42873440" xlink:to="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_D1D7D15E251DF9F8FE5E0C3B428869D7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A" xlink:to="loc_hsy_NorthAmericaSegmentMember_D1D7D15E251DF9F8FE5E0C3B428869D7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_C92C97E831996ED3E1BA0C3B4288673F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A" xlink:to="loc_hsy_InternationalandOtherSegmentMember_C92C97E831996ED3E1BA0C3B4288673F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CorporateMember" xlink:label="loc_us-gaap_CorporateMember_601788ED3975B87A40450C3B4288AA31" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_3EB17E8686F383D040D90C3B4287798A" xlink:to="loc_us-gaap_CorporateMember_601788ED3975B87A40450C3B4288AA31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DepreciationDepletionAndAmortization" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_0037CD0F87BA2F5538380C3B42896867" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_7043DE4A854B27E0E4390C3B4288B5FC" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_0037CD0F87BA2F5538380C3B42896867" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_2C2207BC74B07417631843E8D5F77ABB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_2C2207BC74B07417631843E8D5F77ABB" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_A25B0A3DF4EF4C27DCE643E8D5F89479" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_2C2207BC74B07417631843E8D5F77ABB" xlink:to="loc_srt_ConsolidationItemsAxis_A25B0A3DF4EF4C27DCE643E8D5F89479" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_A25B0A3DF4EF4C27DCE643E8D5F89479" xlink:to="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_A25B0A3DF4EF4C27DCE643E8D5F89479" xlink:to="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_030899FB86B1FD9D77FB43E8D5F888DD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5" xlink:to="loc_us-gaap_OperatingSegmentsMember_030899FB86B1FD9D77FB43E8D5F888DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CorporateNonSegmentMember" xlink:label="loc_us-gaap_CorporateNonSegmentMember_6EF54A0ADE1F6B8B4D6D43E8D5F9103F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5" xlink:to="loc_us-gaap_CorporateNonSegmentMember_6EF54A0ADE1F6B8B4D6D43E8D5F9103F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_F4407896FE6BA59834D643E8D5F9C593" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_E45621FEE5C982A1D60A43E8D5F8EAD5" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_F4407896FE6BA59834D643E8D5F9C593" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_630DA75478A8652F8B5943E8D5F9DC5D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_2C2207BC74B07417631843E8D5F77ABB" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_630DA75478A8652F8B5943E8D5F9DC5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_630DA75478A8652F8B5943E8D5F9DC5D" xlink:to="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_630DA75478A8652F8B5943E8D5F9DC5D" xlink:to="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_A43194813BF1C13CEFB843E8D5FAFC1B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24" xlink:to="loc_hsy_NorthAmericaSegmentMember_A43194813BF1C13CEFB843E8D5FAFC1B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_8E293B4C2EAB3A79484243E8D5FBD221" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24" xlink:to="loc_hsy_InternationalandOtherSegmentMember_8E293B4C2EAB3A79484243E8D5FBD221" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_F6B46E8A59876FFFE13943E8D5FB1102" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_D7B1C99C60D0D847DB9743E8D5F9CF24" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_F6B46E8A59876FFFE13943E8D5FB1102" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_7431A9D8F5EFAE9BE27E43E8D5FCD74E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_7431A9D8F5EFAE9BE27E43E8D5FCD74E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_E71F6B787F6C135203AF43E8D5FC0B86" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_OperatingIncomeLoss_E71F6B787F6C135203AF43E8D5FC0B86" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NonoperatingIncomeExpense" xlink:label="loc_us-gaap_NonoperatingIncomeExpense_7D14A5B65A2DF377F3BF43E8D5FC9967" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_NonoperatingIncomeExpense_7D14A5B65A2DF377F3BF43E8D5FC9967" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_86BFEFA5D4CFEE1B3A9543E8D5FCAE12" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_86BFEFA5D4CFEE1B3A9543E8D5FCAE12" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GoodwillAndIntangibleAssetImpairment" xlink:label="loc_us-gaap_GoodwillAndIntangibleAssetImpairment_2FBD038F0E93ED8865A143E8D5FD18FF" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_GoodwillAndIntangibleAssetImpairment_2FBD038F0E93ED8865A143E8D5FD18FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_6A86A0061A5E13C764D243E8D5FDC700" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_RestructuringCharges_6A86A0061A5E13C764D243E8D5FDC700" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BusinessCombinationIntegrationRelatedCosts" xlink:label="loc_us-gaap_BusinessCombinationIntegrationRelatedCosts_741DDABC899EBB52AEEA43E8D5FDD12A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_BusinessCombinationIntegrationRelatedCosts_741DDABC899EBB52AEEA43E8D5FDD12A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_GainLossOnDispositionOfIntangibleAssets" xlink:label="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_8ED3B8252A84A97771E343E8D5FD7E32" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_8ED3B8252A84A97771E343E8D5FD7E32" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_024C647F49DEA311BFC243E8D5FD9F9A" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_024C647F49DEA311BFC243E8D5FD9F9A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_9F88F24C30048F839A9243E8D5FD6B7D" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_9F88F24C30048F839A9243E8D5FD6B7D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97F00F3AAD9A0F656D6E43E8D5FDF271" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_3D75A5C5478573D9127143E8D5FCF329" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97F00F3AAD9A0F656D6E43E8D5FDF271" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationScheduleOfSegmentInformationByGeographyDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems" xlink:label="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_50C10AD3A2B7427A048A0C3B4277D28C" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable" xlink:label="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_0E1CC12A08116E3E7B8D0C3B4276B207" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_50C10AD3A2B7427A048A0C3B4277D28C" xlink:to="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_0E1CC12A08116E3E7B8D0C3B4276B207" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_StatementGeographicalAxis" xlink:label="loc_srt_StatementGeographicalAxis_2E7D995ADCFF776E80380C3B4276A20C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_0E1CC12A08116E3E7B8D0C3B4276B207" xlink:to="loc_srt_StatementGeographicalAxis_2E7D995ADCFF776E80380C3B4276A20C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_SegmentGeographicalDomain" xlink:label="loc_srt_SegmentGeographicalDomain_7BB5340E03144D7B5B4B0C3B4277DFE4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_StatementGeographicalAxis_2E7D995ADCFF776E80380C3B4276A20C" xlink:to="loc_srt_SegmentGeographicalDomain_7BB5340E03144D7B5B4B0C3B4277DFE4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_SegmentGeographicalDomain" xlink:label="loc_srt_SegmentGeographicalDomain_7BB5340E03144D7B5B4B0C3B4277DFE4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_StatementGeographicalAxis_2E7D995ADCFF776E80380C3B4276A20C" xlink:to="loc_srt_SegmentGeographicalDomain_7BB5340E03144D7B5B4B0C3B4277DFE4" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/country/2017/country-2017-01-31.xsd#country_US" xlink:label="loc_country_US_F4D7FA723C153DF518DB0C3B42771675" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SegmentGeographicalDomain_7BB5340E03144D7B5B4B0C3B4277DFE4" xlink:to="loc_country_US_F4D7FA723C153DF518DB0C3B42771675" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NonUsMember" xlink:label="loc_us-gaap_NonUsMember_54630D19C5D96B274AF70C3B42771EE8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SegmentGeographicalDomain_7BB5340E03144D7B5B4B0C3B4277DFE4" xlink:to="loc_us-gaap_NonUsMember_54630D19C5D96B274AF70C3B42771EE8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_F4B66DC2408B9D826D9F0C3B4277514D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_50C10AD3A2B7427A048A0C3B4277D28C" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_F4B66DC2408B9D826D9F0C3B4277514D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_8B47D1EF9BEC7FE88A8D0C3B42788AE5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_50C10AD3A2B7427A048A0C3B4277D28C" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_8B47D1EF9BEC7FE88A8D0C3B42788AE5" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_C99049CA8EFC4EDD83193451F5AEBD06" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_C99049CA8EFC4EDD83193451F5AEBD06" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_DD8A0CA7CFA3954CF4373451F5AA6D95" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:to="loc_us-gaap_HedgingDesignationAxis_DD8A0CA7CFA3954CF4373451F5AA6D95" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_A1D709F4765CBF6D5F593451F5AB97E1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_DD8A0CA7CFA3954CF4373451F5AA6D95" xlink:to="loc_us-gaap_HedgingDesignationDomain_A1D709F4765CBF6D5F593451F5AB97E1_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_A1D709F4765CBF6D5F593451F5AB97E1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_DD8A0CA7CFA3954CF4373451F5AA6D95" xlink:to="loc_us-gaap_HedgingDesignationDomain_A1D709F4765CBF6D5F593451F5AB97E1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_E7266578688AB28C68ED3451F5ABCD1D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_A1D709F4765CBF6D5F593451F5AB97E1" xlink:to="loc_us-gaap_NondesignatedMember_E7266578688AB28C68ED3451F5ABCD1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_DF186D1E0A7C367B364A3451F5AB92BA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_DF186D1E0A7C367B364A3451F5AB92BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_A2FB7780849A306B8A6C3451F5ABB709_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_DF186D1E0A7C367B364A3451F5AB92BA" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A2FB7780849A306B8A6C3451F5ABB709_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_A2FB7780849A306B8A6C3451F5ABB709" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_DF186D1E0A7C367B364A3451F5AB92BA" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A2FB7780849A306B8A6C3451F5ABB709" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_6F4F9A78E0442A8075323451F5ACEE31" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A2FB7780849A306B8A6C3451F5ABB709" xlink:to="loc_us-gaap_CommodityContractMember_6F4F9A78E0442A8075323451F5ACEE31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_5747CD24EF391B4E07813451F5AC5F5B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:to="loc_srt_ConsolidationItemsAxis_5747CD24EF391B4E07813451F5AC5F5B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_4A85C4AE44E154FB9DBE3451F5ACD523_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_5747CD24EF391B4E07813451F5AC5F5B" xlink:to="loc_srt_ConsolidationItemsDomain_4A85C4AE44E154FB9DBE3451F5ACD523_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_4A85C4AE44E154FB9DBE3451F5ACD523" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_5747CD24EF391B4E07813451F5AC5F5B" xlink:to="loc_srt_ConsolidationItemsDomain_4A85C4AE44E154FB9DBE3451F5ACD523" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_B06D6B511BDAD5430F1D3451F5AC93AF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_4A85C4AE44E154FB9DBE3451F5ACD523" xlink:to="loc_us-gaap_OperatingSegmentsMember_B06D6B511BDAD5430F1D3451F5AC93AF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_DF6044749C8B047145FC3451F5ADA730" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_DF6044749C8B047145FC3451F5ADA730" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_A33C9B9C00721721F97E3451F5AD3517_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_DF6044749C8B047145FC3451F5ADA730" xlink:to="loc_us-gaap_SegmentDomain_A33C9B9C00721721F97E3451F5AD3517_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_A33C9B9C00721721F97E3451F5AD3517" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_DF6044749C8B047145FC3451F5ADA730" xlink:to="loc_us-gaap_SegmentDomain_A33C9B9C00721721F97E3451F5AD3517" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_A042183677081E8640413451F5AD2533" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_A33C9B9C00721721F97E3451F5AD3517" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_A042183677081E8640413451F5AD2533" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SubsegmentsAxis" xlink:label="loc_us-gaap_SubsegmentsAxis_466CD93F18A0270A82E03451F5AD3828" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:to="loc_us-gaap_SubsegmentsAxis_466CD93F18A0270A82E03451F5AD3828" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SubsegmentsDomain" xlink:label="loc_us-gaap_SubsegmentsDomain_C04FE74053BC1BF8FFEA3451F5AD386A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsegmentsAxis_466CD93F18A0270A82E03451F5AD3828" xlink:to="loc_us-gaap_SubsegmentsDomain_C04FE74053BC1BF8FFEA3451F5AD386A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SubsegmentsDomain" xlink:label="loc_us-gaap_SubsegmentsDomain_C04FE74053BC1BF8FFEA3451F5AD386A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsegmentsAxis_466CD93F18A0270A82E03451F5AD3828" xlink:to="loc_us-gaap_SubsegmentsDomain_C04FE74053BC1BF8FFEA3451F5AD386A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsAxis" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BC231F79D147C68080253451F5AEE91E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_820FBAE931D2C800411A3451F5AA51C4" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BC231F79D147C68080253451F5AEE91E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsDomain" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsDomain_CDB299D197D59A0456B83451F5AE2FF0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BC231F79D147C68080253451F5AEE91E" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsDomain_CDB299D197D59A0456B83451F5AE2FF0_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsDomain" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsDomain_CDB299D197D59A0456B83451F5AE2FF0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BC231F79D147C68080253451F5AEE91E" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsDomain_CDB299D197D59A0456B83451F5AE2FF0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_B73E63C54B3CA386AB423451F5AE4CF4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_C99049CA8EFC4EDD83193451F5AEBD06" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_B73E63C54B3CA386AB423451F5AE4CF4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome" xlink:label="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_2F386CDDF2220711178B3451F5AF8355" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_C99049CA8EFC4EDD83193451F5AEBD06" xlink:to="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_2F386CDDF2220711178B3451F5AF8355" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses" xlink:label="loc_hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses_FA9AB7D44DE42F76B92A3451F5AF9DDF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_C99049CA8EFC4EDD83193451F5AEBD06" xlink:to="loc_hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses_FA9AB7D44DE42F76B92A3451F5AF9DDF" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SegmentInformationTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebt" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_88364631C67460D2F32CC72AD7161D33" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_3C10704A8CA66F0E221FC72AD7125880" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_88364631C67460D2F32CC72AD7161D33" xlink:to="loc_us-gaap_DebtInstrumentTable_3C10704A8CA66F0E221FC72AD7125880" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_0ED02AB94196A4C3164CC72AD7122672" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_3C10704A8CA66F0E221FC72AD7125880" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_0ED02AB94196A4C3164CC72AD7122672" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_0DAC658120491E2AE9C4C72AD712D1B6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_0ED02AB94196A4C3164CC72AD7122672" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_0DAC658120491E2AE9C4C72AD712D1B6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_0DAC658120491E2AE9C4C72AD712D1B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_0ED02AB94196A4C3164CC72AD7122672" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_0DAC658120491E2AE9C4C72AD712D1B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_BB2968979031FCD4E362C72AD713B048" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_0DAC658120491E2AE9C4C72AD712D1B6" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_BB2968979031FCD4E362C72AD713B048" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_E9246D7BA0AC26CE11EEC72AD71358AE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_3C10704A8CA66F0E221FC72AD7125880" xlink:to="loc_us-gaap_DebtInstrumentAxis_E9246D7BA0AC26CE11EEC72AD71358AE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_E9246D7BA0AC26CE11EEC72AD71358AE" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_E9246D7BA0AC26CE11EEC72AD71358AE" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.90Due2020Domain" xlink:label="loc_hsy_Notes2.90Due2020Domain_AEAC1F73ED40D1BFFD7CC72AD7140AF3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes2.90Due2020Domain_AEAC1F73ED40D1BFFD7CC72AD7140AF3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes4.125Due2020Member" xlink:label="loc_hsy_Notes4.125Due2020Member_8FF374294747957316AFC72AD7148E9B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes4.125Due2020Member_8FF374294747957316AFC72AD7148E9B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.10Due2021Domain" xlink:label="loc_hsy_Notes3.10Due2021Domain_A5EF29ACEB629A3FCCB7C72AD7146ECC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes3.10Due2021Domain_A5EF29ACEB629A3FCCB7C72AD7146ECC" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_5C4C308E80CFE6F6596CC72AD714B79A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Debentures8.8Due2021Member_5C4C308E80CFE6F6596CC72AD714B79A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.375Due2023Domain" xlink:label="loc_hsy_Notes3.375Due2023Domain_D9C50389ED64084A2BB5C72AD715B1EA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes3.375Due2023Domain_D9C50389ED64084A2BB5C72AD715B1EA" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.625Due2023Member" xlink:label="loc_hsy_Notes2.625Due2023Member_27930F10A9A9670B4B4EC72AD7155A73" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes2.625Due2023Member_27930F10A9A9670B4B4EC72AD7155A73" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.050Due2024Member" xlink:label="loc_hsy_Notes2.050Due2024Member_B8EDB12950B7BC16006FC72AD715CEA7" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes2.050Due2024Member_B8EDB12950B7BC16006FC72AD715CEA7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.20Due2025Member" xlink:label="loc_hsy_Notes3.20Due2025Member_4AAF9181E91C9C589E5CC72AD71562A1" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes3.20Due2025Member_4AAF9181E91C9C589E5CC72AD71562A1" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_F78660F7417A9994FDB1C72AD715E66A" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes2.30Due2026Member_F78660F7417A9994FDB1C72AD715E66A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_FF9F306DD95C6A020A25C72AD716F0B1" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Debentures7.2Due2027Member_FF9F306DD95C6A020A25C72AD716F0B1" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.450Due2029Member" xlink:label="loc_hsy_Notes2.450Due2029Member_6443E0ADC87B476F57BCC72AD716EADF" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes2.450Due2029Member_6443E0ADC87B476F57BCC72AD716EADF" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_B86A2483E765EF76AB8BC72AD7160380" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes3.375Due2046Member_B86A2483E765EF76AB8BC72AD7160380" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.125Due2049Member" xlink:label="loc_hsy_Notes3.125Due2049Member_9EB3BBE54727C43F7D85C72AD71668A3" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_AF8117A137F706BC6CCDC72AD7135CD5" xlink:to="loc_hsy_Notes3.125Due2049Member_9EB3BBE54727C43F7D85C72AD71668A3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_5A0ECCF9AA27CA1553FEC72AD7160C01" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_88364631C67460D2F32CC72AD7161D33" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_5A0ECCF9AA27CA1553FEC72AD7160C01" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_8E1509164CC83C3C2357C72AD5965193" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_4D9276F77D6457CA3118C72AD593980A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_8E1509164CC83C3C2357C72AD5965193" xlink:to="loc_us-gaap_DebtInstrumentTable_4D9276F77D6457CA3118C72AD593980A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_2711419705C040A2F1C2C72AD594E165" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_4D9276F77D6457CA3118C72AD593980A" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_2711419705C040A2F1C2C72AD594E165" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_9C654B423526FF8334B4C72AD59499D6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_2711419705C040A2F1C2C72AD594E165" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_9C654B423526FF8334B4C72AD59499D6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_9C654B423526FF8334B4C72AD59499D6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_2711419705C040A2F1C2C72AD594E165" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_9C654B423526FF8334B4C72AD59499D6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_9DFC1A7739BE8D43F39CC72AD5942E7F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_9C654B423526FF8334B4C72AD59499D6" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_9DFC1A7739BE8D43F39CC72AD5942E7F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_81D3506D6EFA4D474D7AC72AD595DCE6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_4D9276F77D6457CA3118C72AD593980A" xlink:to="loc_us-gaap_DebtInstrumentAxis_81D3506D6EFA4D474D7AC72AD595DCE6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_74A52C68EB7F3AF2F1FBC72AD595EE16_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_81D3506D6EFA4D474D7AC72AD595DCE6" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_74A52C68EB7F3AF2F1FBC72AD595EE16_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_74A52C68EB7F3AF2F1FBC72AD595EE16" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_81D3506D6EFA4D474D7AC72AD595DCE6" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_74A52C68EB7F3AF2F1FBC72AD595EE16" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes1.60Due2018Member" xlink:label="loc_hsy_Notes1.60Due2018Member_6A7D4785367452957329C72AD5956599" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_74A52C68EB7F3AF2F1FBC72AD595EE16" xlink:to="loc_hsy_Notes1.60Due2018Member_6A7D4785367452957329C72AD5956599" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ExtinguishmentOfDebtAxis" xlink:label="loc_us-gaap_ExtinguishmentOfDebtAxis_A6335E89BFEAA8D30E2FC72AD595D4D9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_4D9276F77D6457CA3118C72AD593980A" xlink:to="loc_us-gaap_ExtinguishmentOfDebtAxis_A6335E89BFEAA8D30E2FC72AD595D4D9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ExtinguishmentOfDebtTypeDomain" xlink:label="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_ACFC5651E7D129F8F71AC72AD595B9A5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ExtinguishmentOfDebtAxis_A6335E89BFEAA8D30E2FC72AD595D4D9" xlink:to="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_ACFC5651E7D129F8F71AC72AD595B9A5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ExtinguishmentOfDebtTypeDomain" xlink:label="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_ACFC5651E7D129F8F71AC72AD595B9A5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ExtinguishmentOfDebtAxis_A6335E89BFEAA8D30E2FC72AD595D4D9" xlink:to="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_ACFC5651E7D129F8F71AC72AD595B9A5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_C9DBDDD9F07A58BE3824C72AD59634E8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_ACFC5651E7D129F8F71AC72AD595B9A5" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_C9DBDDD9F07A58BE3824C72AD59634E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RepaymentsOfDebt" xlink:label="loc_us-gaap_RepaymentsOfDebt_3BD36AD3BA8FF3A4DBE4C72AD596EEC6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_8E1509164CC83C3C2357C72AD5965193" xlink:to="loc_us-gaap_RepaymentsOfDebt_3BD36AD3BA8FF3A4DBE4C72AD596EEC6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_A9B7213DAD115DB371CDC72AD5970794" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_8E1509164CC83C3C2357C72AD5965193" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_A9B7213DAD115DB371CDC72AD5970794" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_6EEBD495D34BC0234FDDD468B133CC53" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_DebtInstrumentTable_6EEBD495D34BC0234FDDD468B133CC53" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_0D289846134D8374E51ED468B133CC38" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_6EEBD495D34BC0234FDDD468B133CC53" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_0D289846134D8374E51ED468B133CC38" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_13F05F8E06BFA38EDA3ED468B13432C8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_0D289846134D8374E51ED468B133CC38" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_13F05F8E06BFA38EDA3ED468B13432C8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_13F05F8E06BFA38EDA3ED468B13432C8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_0D289846134D8374E51ED468B133CC38" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_13F05F8E06BFA38EDA3ED468B13432C8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_8C12978C7A1D0D07A501D468B134F675" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_13F05F8E06BFA38EDA3ED468B13432C8" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_8C12978C7A1D0D07A501D468B134F675" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_A89EF53B26B0955EFB4DD468B13489C3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_6EEBD495D34BC0234FDDD468B133CC53" xlink:to="loc_us-gaap_DebtInstrumentAxis_A89EF53B26B0955EFB4DD468B13489C3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_A89EF53B26B0955EFB4DD468B13489C3" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_A89EF53B26B0955EFB4DD468B13489C3" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.90Due2020Domain" xlink:label="loc_hsy_Notes2.90Due2020Domain_3A8968F27B5CFF4751B6D468B13596D9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes2.90Due2020Domain_3A8968F27B5CFF4751B6D468B13596D9" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes4.125Due2020Member" xlink:label="loc_hsy_Notes4.125Due2020Member_6EFEC510BBF3712666A6D468B135D9D4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes4.125Due2020Member_6EFEC510BBF3712666A6D468B135D9D4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.10Due2021Domain" xlink:label="loc_hsy_Notes3.10Due2021Domain_A6AA5675A7CB8FA4ED34D468B1357568" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes3.10Due2021Domain_A6AA5675A7CB8FA4ED34D468B1357568" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_1BF66EFD7C6B51E6F97DD468B13535C2" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Debentures8.8Due2021Member_1BF66EFD7C6B51E6F97DD468B13535C2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.375Due2023Domain" xlink:label="loc_hsy_Notes3.375Due2023Domain_EC51FFDFDA6F8633B2E6D468B136D704" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes3.375Due2023Domain_EC51FFDFDA6F8633B2E6D468B136D704" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.625Due2023Member" xlink:label="loc_hsy_Notes2.625Due2023Member_7C6F00EC22A62A61B99DD468B13638E9" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes2.625Due2023Member_7C6F00EC22A62A61B99DD468B13638E9" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.050Due2024Member" xlink:label="loc_hsy_Notes2.050Due2024Member_4AE831F5AA7D887FBDF0D468B1360EA8" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes2.050Due2024Member_4AE831F5AA7D887FBDF0D468B1360EA8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.20Due2025Member" xlink:label="loc_hsy_Notes3.20Due2025Member_71CECB44A385AF32A4D9D468B1363EC0" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes3.20Due2025Member_71CECB44A385AF32A4D9D468B1363EC0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_93B60611A29B9DBCCE79D468B136AD9D" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes2.30Due2026Member_93B60611A29B9DBCCE79D468B136AD9D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_4DF3447BB63A27CE0BA4D468B1361222" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Debentures7.2Due2027Member_4DF3447BB63A27CE0BA4D468B1361222" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes2.450Due2029Member" xlink:label="loc_hsy_Notes2.450Due2029Member_D5230B28ED575E88EEBCD468B137F3B2" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes2.450Due2029Member_D5230B28ED575E88EEBCD468B137F3B2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_3E44CC9727D5311698F6D468B13729AB" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes3.375Due2046Member_3E44CC9727D5311698F6D468B13729AB" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_Notes3.125Due2049Member" xlink:label="loc_hsy_Notes3.125Due2049Member_A186E0D2B8CF1288EBBBD468B137CC03" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_6B2902567E865616ECB5D468B134BF89" xlink:to="loc_hsy_Notes3.125Due2049Member_A186E0D2B8CF1288EBBBD468B137CC03" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_FD95F007DC3578BFBEFCD468B1375935" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_LongTermDebt_FD95F007DC3578BFBEFCD468B1375935" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FinanceLeaseLiability" xlink:label="loc_us-gaap_FinanceLeaseLiability_2FFD3E60B81E55EF4EADD468B137D775" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_FinanceLeaseLiability_2FFD3E60B81E55EF4EADD468B137D775" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet" xlink:label="loc_hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet_02C96928DE68AD1E6522D468B1382065" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet_02C96928DE68AD1E6522D468B1382065" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_2876A63C283923219889D468B1380035" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_LongTermDebtCurrent_2876A63C283923219889D468B1380035" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongTermDebtNoncurrent" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_EDE79F4CAEC7A27D0696D468B138D1E4" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_EDE79F4CAEC7A27D0696D468B138D1E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_72A7D7202F8930543659D468B138B46D" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_72A7D7202F8930543659D468B138B46D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_E2F7EBF65419D84F17A7D468B13DFF0B" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB1636883C153DD73E8FD468B13718D6" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_E2F7EBF65419D84F17A7D468B13DFF0B" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LineOfCreditFacilityLineItems" xlink:label="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LineOfCreditFacilityTable" xlink:label="loc_us-gaap_LineOfCreditFacilityTable_855DEDC5B70A2A412B2CAD98AAC9BD70" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_us-gaap_LineOfCreditFacilityTable_855DEDC5B70A2A412B2CAD98AAC9BD70" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_68241CBA94A2BB6CCE1CAD98AAC950B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_855DEDC5B70A2A412B2CAD98AAC9BD70" xlink:to="loc_us-gaap_DebtInstrumentAxis_68241CBA94A2BB6CCE1CAD98AAC950B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_F451A772B725EF676167AD98AACAB020_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_68241CBA94A2BB6CCE1CAD98AAC950B8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_F451A772B725EF676167AD98AACAB020_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_F451A772B725EF676167AD98AACAB020" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_68241CBA94A2BB6CCE1CAD98AAC950B8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_F451A772B725EF676167AD98AACAB020" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_121FADB81EE770A3655BAD98AACA9F45" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_F451A772B725EF676167AD98AACAB020" xlink:to="loc_us-gaap_LineOfCreditMember_121FADB81EE770A3655BAD98AACA9F45" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CreditFacilityAxis" xlink:label="loc_us-gaap_CreditFacilityAxis_C8C884D59BFD6EF47F93AD98AACA6E50" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_855DEDC5B70A2A412B2CAD98AAC9BD70" xlink:to="loc_us-gaap_CreditFacilityAxis_C8C884D59BFD6EF47F93AD98AACA6E50" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_7CD81D9A02B180A5507BAD98AACA6548_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_C8C884D59BFD6EF47F93AD98AACA6E50" xlink:to="loc_us-gaap_CreditFacilityDomain_7CD81D9A02B180A5507BAD98AACA6548_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_7CD81D9A02B180A5507BAD98AACA6548" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_C8C884D59BFD6EF47F93AD98AACA6E50" xlink:to="loc_us-gaap_CreditFacilityDomain_7CD81D9A02B180A5507BAD98AACA6548" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevolvingCreditFacilityMember" xlink:label="loc_us-gaap_RevolvingCreditFacilityMember_53316717C8E66421DDCDAD98AACBDA7D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_7CD81D9A02B180A5507BAD98AACA6548" xlink:to="loc_us-gaap_RevolvingCreditFacilityMember_53316717C8E66421DDCDAD98AACBDA7D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_A2AED36F62078C280E5CAD98AACB014C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_855DEDC5B70A2A412B2CAD98AAC9BD70" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_A2AED36F62078C280E5CAD98AACB014C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_61E9FFEC022F96DEFFD4AD98AACBA886_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_A2AED36F62078C280E5CAD98AACB014C" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_61E9FFEC022F96DEFFD4AD98AACBA886_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_61E9FFEC022F96DEFFD4AD98AACBA886" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_A2AED36F62078C280E5CAD98AACB014C" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_61E9FFEC022F96DEFFD4AD98AACBA886" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_DC9F0D8016A63C7265F4AD98AACBCD66" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_61E9FFEC022F96DEFFD4AD98AACBA886" xlink:to="loc_us-gaap_LineOfCreditMember_DC9F0D8016A63C7265F4AD98AACBCD66" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ForeignLineOfCreditMember" xlink:label="loc_us-gaap_ForeignLineOfCreditMember_08A900CC2D2C23689A24AD98AACCF564" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_61E9FFEC022F96DEFFD4AD98AACBA886" xlink:to="loc_us-gaap_ForeignLineOfCreditMember_08A900CC2D2C23689A24AD98AACCF564" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShortTermDebtTypeAxis" xlink:label="loc_us-gaap_ShortTermDebtTypeAxis_43193DA8EC78910810CCAD98AACCD511" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_855DEDC5B70A2A412B2CAD98AAC9BD70" xlink:to="loc_us-gaap_ShortTermDebtTypeAxis_43193DA8EC78910810CCAD98AACCD511" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShortTermDebtTypeDomain" xlink:label="loc_us-gaap_ShortTermDebtTypeDomain_5B79C4913468FF7FCD1AAD98AACC013B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ShortTermDebtTypeAxis_43193DA8EC78910810CCAD98AACCD511" xlink:to="loc_us-gaap_ShortTermDebtTypeDomain_5B79C4913468FF7FCD1AAD98AACC013B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShortTermDebtTypeDomain" xlink:label="loc_us-gaap_ShortTermDebtTypeDomain_5B79C4913468FF7FCD1AAD98AACC013B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ShortTermDebtTypeAxis_43193DA8EC78910810CCAD98AACCD511" xlink:to="loc_us-gaap_ShortTermDebtTypeDomain_5B79C4913468FF7FCD1AAD98AACC013B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CommercialPaperMember" xlink:label="loc_us-gaap_CommercialPaperMember_A780844112E31985CE09AD98AACC11C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShortTermDebtTypeDomain_5B79C4913468FF7FCD1AAD98AACC013B" xlink:to="loc_us-gaap_CommercialPaperMember_A780844112E31985CE09AD98AACC11C7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_E1AE2B8E391D95FE3447AD98AACDEB21" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_E1AE2B8E391D95FE3447AD98AACDEB21" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_LineOfCreditFacilityAccordionFeatureIncreaseLimit" xlink:label="loc_hsy_LineOfCreditFacilityAccordionFeatureIncreaseLimit_73C568A581F76AAEE61DADEBDFBB12A4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_hsy_LineOfCreditFacilityAccordionFeatureIncreaseLimit_73C568A581F76AAEE61DADEBDFBB12A4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum" xlink:label="loc_hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum_802305E1B461A1C15C82AD98AACDD9A8" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum_802305E1B461A1C15C82AD98AACDD9A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LinesOfCreditCurrent" xlink:label="loc_us-gaap_LinesOfCreditCurrent_E90E347105C5569C1D83AD98AACD2C6A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_us-gaap_LinesOfCreditCurrent_E90E347105C5569C1D83AD98AACD2C6A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShortTermBorrowings" xlink:label="loc_us-gaap_ShortTermBorrowings_A21D21739BD268477645AD98AACD2764" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_us-gaap_ShortTermBorrowings_A21D21739BD268477645AD98AACD2764" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShortTermDebtWeightedAverageInterestRate" xlink:label="loc_us-gaap_ShortTermDebtWeightedAverageInterestRate_6A2D726380252A868F12AD98AACED50C" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_us-gaap_ShortTermDebtWeightedAverageInterestRate_6A2D726380252A868F12AD98AACED50C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod_93D1D116E26B486FE6A2AD98AACE4820" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_501F252CE9AF81DB307FAD98AACC5880" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod_93D1D116E26B486FE6A2AD98AACE4820" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ShortAndLongTermDebtTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlans" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F991F0037A03779402E1AD1BBB086E0B" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_A1B39B85D5099123994BAD1BBB070F60" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F991F0037A03779402E1AD1BBB086E0B" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_A1B39B85D5099123994BAD1BBB070F60" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_7DE4359D06F982CAD210AD1BBB07D6F5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_A1B39B85D5099123994BAD1BBB070F60" xlink:to="loc_us-gaap_AwardTypeAxis_7DE4359D06F982CAD210AD1BBB07D6F5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7A0685B9DFF95B8E0B43AD1BBB08D4CD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_7DE4359D06F982CAD210AD1BBB07D6F5" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7A0685B9DFF95B8E0B43AD1BBB08D4CD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7A0685B9DFF95B8E0B43AD1BBB08D4CD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_7DE4359D06F982CAD210AD1BBB07D6F5" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7A0685B9DFF95B8E0B43AD1BBB08D4CD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_EB7B2ECED9701108A631AD1BBB08F2C4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7A0685B9DFF95B8E0B43AD1BBB08D4CD" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_EB7B2ECED9701108A631AD1BBB08F2C4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F991F0037A03779402E1AD1BBB086E0B" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_F195E6C8D20BFC7A070DAD1BBB0991AC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_F195E6C8D20BFC7A070DAD1BBB0991AC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_F44C751F0D804448C957AD1BBB096B08" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_F44C751F0D804448C957AD1BBB096B08" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange_7BAD8AD728A21DB7C318AD1BBB090F2C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange_7BAD8AD728A21DB7C318AD1BBB090F2C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_7307F2EB109EF444B805AD1BBB09A8E8" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_7307F2EB109EF444B805AD1BBB09A8E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_ED49AA68992069974869AD1BBB093EB0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_9E6A8A0F47037CDD59A1AD1BBB08954E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_ED49AA68992069974869AD1BBB093EB0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F991F0037A03779402E1AD1BBB086E0B" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_46C9FA71BD6A788ED975AD1BBB0F14C5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_46C9FA71BD6A788ED975AD1BBB0F14C5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_7946D4B4749321568321AD1BBB0F4571" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_7946D4B4749321568321AD1BBB0F4571" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue_6C66860BE467FB56217BAD1BBB103933" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue_6C66860BE467FB56217BAD1BBB103933" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_81A05F86276FA8F7CD40AD1BBB108457" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_81A05F86276FA8F7CD40AD1BBB108457" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_661F703221F832D1ABA5AD1BBB10E8C0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_D5C192895925ECEF0A39AD1BBB0F9925" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_661F703221F832D1ABA5AD1BBB10E8C0" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B7EB34D98AD3D89D9AF4AD1BB9E652C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B7EB34D98AD3D89D9AF4AD1BB9E652C7" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_505063981F99D1F296F2AD1BB9E6FE8D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B7EB34D98AD3D89D9AF4AD1BB9E652C7" xlink:to="loc_us-gaap_AwardTypeAxis_505063981F99D1F296F2AD1BB9E6FE8D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_98CF768C05729E19B005AD1BB9E75BCD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_505063981F99D1F296F2AD1BB9E6FE8D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_98CF768C05729E19B005AD1BB9E75BCD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_98CF768C05729E19B005AD1BB9E75BCD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_505063981F99D1F296F2AD1BB9E6FE8D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_98CF768C05729E19B005AD1BB9E75BCD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_888CE95B398288A7C9ADAD1BB9E72D8B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_98CF768C05729E19B005AD1BB9E75BCD" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_888CE95B398288A7C9ADAD1BB9E72D8B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_58D5E851957CDF355FA3AD1BB9E81BC1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_58D5E851957CDF355FA3AD1BB9E81BC1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_202D555B12134F164659AD1BB9E8FF04" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_202D555B12134F164659AD1BB9E8FF04" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_311B575F97540F5520CDAD1BB9E89F04" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:to="loc_us-gaap_SharePrice_311B575F97540F5520CDAD1BB9E89F04" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_69539654E9233C564318AD1BB9E8FF79" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_69539654E9233C564318AD1BB9E8FF79" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_0BBFAFC6F00D2F171D9AAD1BB9E8DECD" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F62A99A63BE163DFD753AD1BB9E7588C" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_0BBFAFC6F00D2F171D9AAD1BB9E8DECD" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_29DA3AC89C917A4F3007CDD407ADBB85" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_29DA3AC89C917A4F3007CDD407ADBB85" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_92195EA72A1259EDEB3FCDD407AD67D3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_29DA3AC89C917A4F3007CDD407ADBB85" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_92195EA72A1259EDEB3FCDD407AD67D3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_92195EA72A1259EDEB3FCDD407AD67D3" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_92195EA72A1259EDEB3FCDD407AD67D3" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ExercisePriceRangeOneMember" xlink:label="loc_hsy_ExercisePriceRangeOneMember_D405BFEB90CE58CC583FCDD407ADA21B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E" xlink:to="loc_hsy_ExercisePriceRangeOneMember_D405BFEB90CE58CC583FCDD407ADA21B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ExercisePriceRangeTwoMember" xlink:label="loc_hsy_ExercisePriceRangeTwoMember_D1A14E868EEC66B8EFEACDD407AD5695" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E" xlink:to="loc_hsy_ExercisePriceRangeTwoMember_D1A14E868EEC66B8EFEACDD407AD5695" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ExercisePriceRangeThreeMember" xlink:label="loc_hsy_ExercisePriceRangeThreeMember_CA2BE50F1B29C1D69C07CDD407AD67D0" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E" xlink:to="loc_hsy_ExercisePriceRangeThreeMember_CA2BE50F1B29C1D69C07CDD407AD67D0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ExercisePriceRangeFourMember" xlink:label="loc_hsy_ExercisePriceRangeFourMember_3533B1284A019A582004CDD407ADD5BF" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_922B5B9C1B7C55F4AB8CCDD407ADBF7E" xlink:to="loc_hsy_ExercisePriceRangeFourMember_3533B1284A019A582004CDD407ADD5BF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit_1181286CA869E2C41112CDD407AD7B68" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit_1181286CA869E2C41112CDD407AD7B68" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit_55085D6E2C34CBBCA880CDD407ADA5F0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit_55085D6E2C34CBBCA880CDD407ADA5F0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions_ECB8446721A3620EA04DCDD407ADE08F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions_ECB8446721A3620EA04DCDD407ADE08F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2_37E4BE3ED69F27F7A489CDD407AD2192" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2_37E4BE3ED69F27F7A489CDD407AD2192" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1_FDA8A8906E773860256DCDD407AD26A5" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1_FDA8A8906E773860256DCDD407AD26A5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions_4975C471E616760C306DCDD407ADDE45" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions_4975C471E616760C306DCDD407ADDE45" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1_8A4201FF1DC9ABE2E35CCDD407AD3D8B" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_D085453038CBDCB02530CDD407AD00F9" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1_8A4201FF1DC9ABE2E35CCDD407AD3D8B" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_AB2AC1DA416A9AE63256D310C0D8E61A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_AB2AC1DA416A9AE63256D310C0D8E61A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_B02CA2AE88FF6C3FD8B0D310C0D8DC3F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_AB2AC1DA416A9AE63256D310C0D8E61A" xlink:to="loc_us-gaap_AwardTypeAxis_B02CA2AE88FF6C3FD8B0D310C0D8DC3F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_B02CA2AE88FF6C3FD8B0D310C0D8DC3F" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_B02CA2AE88FF6C3FD8B0D310C0D8DC3F" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_C0792B29A6F694A8B5B7D310C0D933A9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D" xlink:to="loc_us-gaap_EmployeeStockOptionMember_C0792B29A6F694A8B5B7D310C0D933A9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PerformanceSharesMember" xlink:label="loc_us-gaap_PerformanceSharesMember_888D72607A1D1C90698ED310C0D9DCB2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D" xlink:to="loc_us-gaap_PerformanceSharesMember_888D72607A1D1C90698ED310C0D9DCB2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PerformanceStockUnitsandRestrictedStockUnitsMember" xlink:label="loc_hsy_PerformanceStockUnitsandRestrictedStockUnitsMember_233CDB3A36560A230A5ED310C0D9BB62" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_34840FADD8A27D234FBFD310C0D98E5D" xlink:to="loc_hsy_PerformanceStockUnitsandRestrictedStockUnitsMember_233CDB3A36560A230A5ED310C0D9BB62" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_860295F17237E535DFB1D310C0DA4AA8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_AB2AC1DA416A9AE63256D310C0D8E61A" xlink:to="loc_srt_RangeAxis_860295F17237E535DFB1D310C0DA4AA8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_160982BED9180D2B0073D310C0DADCE4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_860295F17237E535DFB1D310C0DA4AA8" xlink:to="loc_srt_RangeMember_160982BED9180D2B0073D310C0DADCE4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_160982BED9180D2B0073D310C0DADCE4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_860295F17237E535DFB1D310C0DA4AA8" xlink:to="loc_srt_RangeMember_160982BED9180D2B0073D310C0DADCE4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_4D9090B1A8DA7A109A95D310C0DA0611" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_160982BED9180D2B0073D310C0DADCE4" xlink:to="loc_srt_MinimumMember_4D9090B1A8DA7A109A95D310C0DA0611" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_0EF1D17C468B12017A2FD310C0DAE384" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_160982BED9180D2B0073D310C0DADCE4" xlink:to="loc_srt_MaximumMember_0EF1D17C468B12017A2FD310C0DAE384" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized_16FDA7E1C8EF7A3AEB8AD310C0DB337C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized_16FDA7E1C8EF7A3AEB8AD310C0DB337C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_3AFC203E3F2A4C5A4295D310C0DB1C7F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_3AFC203E3F2A4C5A4295D310C0DB1C7F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_22A317E7AF94B5FB7136D310C0DB96F7" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_22A317E7AF94B5FB7136D310C0DB96F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod" xlink:label="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_517B2188350EB550E3D3D310C0DB771E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_517B2188350EB550E3D3D310C0DB771E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_C8355C224EEC8B0AADD9D310C0DCBBB6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_C8355C224EEC8B0AADD9D310C0DCBBB6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_2D46F65FE1B9F3CE3377D310C0DBE5D5" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_2D46F65FE1B9F3CE3377D310C0DBE5D5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_ED9654A993AC27241B70D310C0DC72D5" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_ED9654A993AC27241B70D310C0DC72D5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions_753646AC443390CA0B82D310C0DCBBE2" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions_753646AC443390CA0B82D310C0DCBBE2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage_C1FE27D15F5C931F20F8D310C0DCC88B" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage_C1FE27D15F5C931F20F8D310C0DCC88B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested_DE5F78B56B6E23A9F2CCD310C0DCC96E" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested_DE5F78B56B6E23A9F2CCD310C0DCC96E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued" xlink:label="loc_us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued_179C34B4CBB808B4EA23D310C0DC988B" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued_179C34B4CBB808B4EA23D310C0DC988B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_DeferredCompensationArrangementwithIndividualConversionBasis" xlink:label="loc_hsy_DeferredCompensationArrangementwithIndividualConversionBasis_5B201DFBB4312C51578ED310C0DD7714" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_486E557FE1275B228DDAD310C0DA0053" xlink:to="loc_hsy_DeferredCompensationArrangementwithIndividualConversionBasis_5B201DFBB4312C51578ED310C0DD7714" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/StockCompensationPlansTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPolicies" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EntityWideRevenueMajorCustomerLineItems" xlink:label="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_56F9FFCC0B98FB2892E8D4071E120782" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable" xlink:label="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_8659D2153870D969BD2ED4071E12F465" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_56F9FFCC0B98FB2892E8D4071E120782" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_8659D2153870D969BD2ED4071E12F465" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MajorCustomersAxis" xlink:label="loc_srt_MajorCustomersAxis_221C40496A5C62A7DA78D4071E12BB3B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_8659D2153870D969BD2ED4071E12F465" xlink:to="loc_srt_MajorCustomersAxis_221C40496A5C62A7DA78D4071E12BB3B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_4E52B0466C309ED2814FD4071E12E8FF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_MajorCustomersAxis_221C40496A5C62A7DA78D4071E12BB3B" xlink:to="loc_srt_NameOfMajorCustomerDomain_4E52B0466C309ED2814FD4071E12E8FF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_4E52B0466C309ED2814FD4071E12E8FF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_MajorCustomersAxis_221C40496A5C62A7DA78D4071E12BB3B" xlink:to="loc_srt_NameOfMajorCustomerDomain_4E52B0466C309ED2814FD4071E12E8FF" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_McLaneCompanyInc.Member" xlink:label="loc_hsy_McLaneCompanyInc.Member_3E89DFAFAEED6F63DE1ED4071E12F4D7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_NameOfMajorCustomerDomain_4E52B0466C309ED2814FD4071E12E8FF" xlink:to="loc_hsy_McLaneCompanyInc.Member_3E89DFAFAEED6F63DE1ED4071E12F4D7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_6D6C36ED12829ACE25F7D4071E128967" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_8659D2153870D969BD2ED4071E12F465" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_6D6C36ED12829ACE25F7D4071E128967" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_3EEED0D0BA03EDCC3C99D4071E121A0E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_6D6C36ED12829ACE25F7D4071E128967" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_3EEED0D0BA03EDCC3C99D4071E121A0E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_3EEED0D0BA03EDCC3C99D4071E121A0E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_6D6C36ED12829ACE25F7D4071E128967" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_3EEED0D0BA03EDCC3C99D4071E121A0E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CustomerConcentrationRiskMember" xlink:label="loc_us-gaap_CustomerConcentrationRiskMember_465A2DC50462FE89446AD4071E12F170" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_3EEED0D0BA03EDCC3C99D4071E121A0E" xlink:to="loc_us-gaap_CustomerConcentrationRiskMember_465A2DC50462FE89446AD4071E12F170" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_FAFBA7C8DC1AB46EDC61D4071E129243" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_8659D2153870D969BD2ED4071E12F465" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_FAFBA7C8DC1AB46EDC61D4071E129243" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D28E2A8697035D629DAD4071E12F8C6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_FAFBA7C8DC1AB46EDC61D4071E129243" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D28E2A8697035D629DAD4071E12F8C6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D28E2A8697035D629DAD4071E12F8C6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_FAFBA7C8DC1AB46EDC61D4071E129243" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D28E2A8697035D629DAD4071E12F8C6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccountsReceivableMember" xlink:label="loc_us-gaap_AccountsReceivableMember_AAF4B5C5E80D4EC774EED4071E128798" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D28E2A8697035D629DAD4071E12F8C6" xlink:to="loc_us-gaap_AccountsReceivableMember_AAF4B5C5E80D4EC774EED4071E128798" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_CF3759D7A17CAFB5FB3ED4071E12B351" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_56F9FFCC0B98FB2892E8D4071E120782" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_CF3759D7A17CAFB5FB3ED4071E12B351" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent" xlink:label="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_CAB15682928A3C4BF114D4071E129B44" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_56F9FFCC0B98FB2892E8D4071E120782" xlink:to="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_CAB15682928A3C4BF114D4071E129B44" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_ABED5631485322407128356A63198185" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_8F148C19A4567BEEDE43356A6317D719" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_ABED5631485322407128356A63198185" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_8F148C19A4567BEEDE43356A6317D719" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_4311422ECCE6BB704A5B356A63189D17" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_8F148C19A4567BEEDE43356A6317D719" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_4311422ECCE6BB704A5B356A63189D17" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_615DC2CBBE434EDDBFEB356A63187488_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_4311422ECCE6BB704A5B356A63189D17" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_615DC2CBBE434EDDBFEB356A63187488_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_615DC2CBBE434EDDBFEB356A63187488" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_4311422ECCE6BB704A5B356A63189D17" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_615DC2CBBE434EDDBFEB356A63187488" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_SoftwareAndSoftwareDevelopmentCostsMember" xlink:label="loc_us-gaap_SoftwareAndSoftwareDevelopmentCostsMember_B48EF322E288DC8F298A356A6318E20A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_615DC2CBBE434EDDBFEB356A63187488" xlink:to="loc_us-gaap_SoftwareAndSoftwareDevelopmentCostsMember_B48EF322E288DC8F298A356A6318E20A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_3E38171D1B11364E46BD356A6318D913" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_8F148C19A4567BEEDE43356A6317D719" xlink:to="loc_srt_RangeAxis_3E38171D1B11364E46BD356A6318D913" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_3A0B750AC9716AF2EDBA356A63194316_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_3E38171D1B11364E46BD356A6318D913" xlink:to="loc_srt_RangeMember_3A0B750AC9716AF2EDBA356A63194316_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_3A0B750AC9716AF2EDBA356A63194316" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_3E38171D1B11364E46BD356A6318D913" xlink:to="loc_srt_RangeMember_3A0B750AC9716AF2EDBA356A63194316" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_213FC6C57C4D25AB25B2356A6319E83B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_3A0B750AC9716AF2EDBA356A63194316" xlink:to="loc_srt_MinimumMember_213FC6C57C4D25AB25B2356A6319E83B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_0743F6F7D0B09E7A6D7B356A631957FB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_3A0B750AC9716AF2EDBA356A63194316" xlink:to="loc_srt_MaximumMember_0743F6F7D0B09E7A6D7B356A631957FB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CapitalizedComputerSoftwareNet" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareNet_64C9D2714460C44EA0F5356A6319784B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_ABED5631485322407128356A63198185" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareNet_64C9D2714460C44EA0F5356A6319784B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_C77D691F8A5146EDDFF4356A631AF670" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_ABED5631485322407128356A63198185" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_C77D691F8A5146EDDFF4356A631AF670" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization_067E73402ADA6EA153DB356A631A7C9E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_ABED5631485322407128356A63198185" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization_067E73402ADA6EA153DB356A631A7C9E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_09FDF601AE98D93C03393451FA5FBA15" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5180991B8AD7CDD75BB23451FA5CEB57" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_09FDF601AE98D93C03393451FA5FBA15" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5180991B8AD7CDD75BB23451FA5CEB57" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C47A0ED119DFE86081CF3451FA5D3EA5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5180991B8AD7CDD75BB23451FA5CEB57" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C47A0ED119DFE86081CF3451FA5D3EA5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_7225C7C08B2EBB1A294A3451FA5D7D01_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C47A0ED119DFE86081CF3451FA5D3EA5" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_7225C7C08B2EBB1A294A3451FA5D7D01_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_7225C7C08B2EBB1A294A3451FA5D7D01" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C47A0ED119DFE86081CF3451FA5D3EA5" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_7225C7C08B2EBB1A294A3451FA5D7D01" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_MachineryAndEquipmentMember" xlink:label="loc_us-gaap_MachineryAndEquipmentMember_04DE87F4F7D2028278423451FA5D84BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_7225C7C08B2EBB1A294A3451FA5D7D01" xlink:to="loc_us-gaap_MachineryAndEquipmentMember_04DE87F4F7D2028278423451FA5D84BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_BuildingAndBuildingImprovementsMember" xlink:label="loc_us-gaap_BuildingAndBuildingImprovementsMember_F17433D737E17FEEDD133451FA5EF572" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_7225C7C08B2EBB1A294A3451FA5D7D01" xlink:to="loc_us-gaap_BuildingAndBuildingImprovementsMember_F17433D737E17FEEDD133451FA5EF572" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_309D02E124FCE1FA797C3451FA5E518C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5180991B8AD7CDD75BB23451FA5CEB57" xlink:to="loc_srt_RangeAxis_309D02E124FCE1FA797C3451FA5E518C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_0ED2D1BCE7452FFB23B33451FA5EC2D8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_309D02E124FCE1FA797C3451FA5E518C" xlink:to="loc_srt_RangeMember_0ED2D1BCE7452FFB23B33451FA5EC2D8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_0ED2D1BCE7452FFB23B33451FA5EC2D8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_309D02E124FCE1FA797C3451FA5E518C" xlink:to="loc_srt_RangeMember_0ED2D1BCE7452FFB23B33451FA5EC2D8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_8B7E6407E39C60300A0E3451FA5E029F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_0ED2D1BCE7452FFB23B33451FA5EC2D8" xlink:to="loc_srt_MinimumMember_8B7E6407E39C60300A0E3451FA5E029F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_23F7CE3EEB8A4EB4FA3E3451FA5EBD9B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_0ED2D1BCE7452FFB23B33451FA5EC2D8" xlink:to="loc_srt_MaximumMember_23F7CE3EEB8A4EB4FA3E3451FA5EBD9B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_F178293B037161BCA8023451FA5F223E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_09FDF601AE98D93C03393451FA5FBA15" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_F178293B037161BCA8023451FA5F223E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_FinanceLeaseRightOfUseAsset" xlink:label="loc_us-gaap_FinanceLeaseRightOfUseAsset_58872FEB0C475BCC7267345916423459" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_09FDF601AE98D93C03393451FA5FBA15" xlink:to="loc_us-gaap_FinanceLeaseRightOfUseAsset_58872FEB0C475BCC7267345916423459" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_CapitalLeasedAssetsNet" xlink:label="loc_hsy_CapitalLeasedAssetsNet_C919ACD70C1A6EEE142E3451FA5F8BAB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_09FDF601AE98D93C03393451FA5FBA15" xlink:to="loc_hsy_CapitalLeasedAssetsNet_C919ACD70C1A6EEE142E3451FA5F8BAB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_Depreciation" xlink:label="loc_us-gaap_Depreciation_6F8320677B34DD45D89F3451FA60AC03" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_09FDF601AE98D93C03393451FA5FBA15" xlink:to="loc_us-gaap_Depreciation_6F8320677B34DD45D89F3451FA60AC03" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems" xlink:label="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_D9FF97E4F6900DCDFAEED2F2E63DB358" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable" xlink:label="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_545D10EC8B809DF9C5C0D2F2E63B87D3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_D9FF97E4F6900DCDFAEED2F2E63DB358" xlink:to="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_545D10EC8B809DF9C5C0D2F2E63B87D3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AdjustmentsForNewAccountingPronouncementsAxis" xlink:label="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_872A408331F8D1972A31D2F2E63B63E4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_545D10EC8B809DF9C5C0D2F2E63B87D3" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_872A408331F8D1972A31D2F2E63B63E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_E9F78A18D2B88610AF22D2F2E63C3D7E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_872A408331F8D1972A31D2F2E63B63E4" xlink:to="loc_us-gaap_TypeOfAdoptionMember_E9F78A18D2B88610AF22D2F2E63C3D7E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_E9F78A18D2B88610AF22D2F2E63C3D7E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_872A408331F8D1972A31D2F2E63B63E4" xlink:to="loc_us-gaap_TypeOfAdoptionMember_E9F78A18D2B88610AF22D2F2E63C3D7E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_AccountingStandardsUpdate201602Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201602Member_0EB6D82DD7F43E56153CD2F2E63C2C57" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_E9F78A18D2B88610AF22D2F2E63C3D7E" xlink:to="loc_us-gaap_AccountingStandardsUpdate201602Member_0EB6D82DD7F43E56153CD2F2E63C2C57" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_37DD1D1D513D52F58D4ED2F2E63C64B2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_545D10EC8B809DF9C5C0D2F2E63B87D3" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_37DD1D1D513D52F58D4ED2F2E63C64B2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_CC0C59BBC023C3A86943D2F2E63DFF95_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_37DD1D1D513D52F58D4ED2F2E63C64B2" xlink:to="loc_us-gaap_EquityComponentDomain_CC0C59BBC023C3A86943D2F2E63DFF95_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_CC0C59BBC023C3A86943D2F2E63DFF95" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_37DD1D1D513D52F58D4ED2F2E63C64B2" xlink:to="loc_us-gaap_EquityComponentDomain_CC0C59BBC023C3A86943D2F2E63DFF95" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_78A80079BF6E3E0E4882D2F2E63DF054" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_CC0C59BBC023C3A86943D2F2E63DFF95" xlink:to="loc_us-gaap_RetainedEarningsMember_78A80079BF6E3E0E4882D2F2E63DF054" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingLeaseRightOfUseAsset" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_02A518CF7D19E835FF51D2F2E63D8E9C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_D9FF97E4F6900DCDFAEED2F2E63DB358" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_02A518CF7D19E835FF51D2F2E63D8E9C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_OperatingLeaseLiability" xlink:label="loc_us-gaap_OperatingLeaseLiability_F3DA717BBDB5DCBFA3E7D2F2E63E0A57" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_D9FF97E4F6900DCDFAEED2F2E63DB358" xlink:to="loc_us-gaap_OperatingLeaseLiability_F3DA717BBDB5DCBFA3E7D2F2E63E0A57" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_0D73958A8813CC02C410D2F2E63E3162" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_D9FF97E4F6900DCDFAEED2F2E63DB358" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_0D73958A8813CC02C410D2F2E63E3162" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_B1F73A3F01140B58B73AD2FE53FEF656" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_40232B3EB174BD520E17D2FE53F9B3D4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_B1F73A3F01140B58B73AD2FE53FEF656" xlink:to="loc_us-gaap_StatementTable_40232B3EB174BD520E17D2FE53F9B3D4" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_3BFDAC390CF85EEDA4CBD2FE53F9710D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_40232B3EB174BD520E17D2FE53F9B3D4" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_3BFDAC390CF85EEDA4CBD2FE53F9710D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_6A3088EFA73F51011896D2FE53FAA40A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_3BFDAC390CF85EEDA4CBD2FE53F9710D" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_6A3088EFA73F51011896D2FE53FAA40A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_6A3088EFA73F51011896D2FE53FAA40A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_3BFDAC390CF85EEDA4CBD2FE53F9710D" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_6A3088EFA73F51011896D2FE53FAA40A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_RevenueFromContractWithCustomerMember" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerMember_2A26EFC3C8BA3999411BD2FE53FB6940" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_6A3088EFA73F51011896D2FE53FAA40A" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerMember_2A26EFC3C8BA3999411BD2FE53FB6940" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_1D1861D5C33C222BA198D2FE53FC767E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_40232B3EB174BD520E17D2FE53F9B3D4" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_1D1861D5C33C222BA198D2FE53FC767E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_1A98E1A00CF09626F2A6D2FE53FCEA51_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_1D1861D5C33C222BA198D2FE53FC767E" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_1A98E1A00CF09626F2A6D2FE53FCEA51_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_1A98E1A00CF09626F2A6D2FE53FCEA51" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_1D1861D5C33C222BA198D2FE53FC767E" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_1A98E1A00CF09626F2A6D2FE53FCEA51" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_CustomerConcentrationRiskMember" xlink:label="loc_us-gaap_CustomerConcentrationRiskMember_14D18725C46E2C0AACCDD2FE53FCB743" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_1A98E1A00CF09626F2A6D2FE53FCEA51" xlink:to="loc_us-gaap_CustomerConcentrationRiskMember_14D18725C46E2C0AACCDD2FE53FCB743" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_MajorCustomersAxis" xlink:label="loc_srt_MajorCustomersAxis_35E69264504B27478FC3D2FE53FDFCBF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_40232B3EB174BD520E17D2FE53F9B3D4" xlink:to="loc_srt_MajorCustomersAxis_35E69264504B27478FC3D2FE53FDFCBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_90B56B9C30F1A3930BF3D2FE53FD8CC7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_MajorCustomersAxis_35E69264504B27478FC3D2FE53FDFCBF" xlink:to="loc_srt_NameOfMajorCustomerDomain_90B56B9C30F1A3930BF3D2FE53FD8CC7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2019/elts/srt-2019-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_90B56B9C30F1A3930BF3D2FE53FD8CC7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_MajorCustomersAxis_35E69264504B27478FC3D2FE53FDFCBF" xlink:to="loc_srt_NameOfMajorCustomerDomain_90B56B9C30F1A3930BF3D2FE53FD8CC7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_McLaneCompanyInc.Member" xlink:label="loc_hsy_McLaneCompanyInc.Member_D5C957FB59EB314097B6D2FE53FDF141" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_NameOfMajorCustomerDomain_90B56B9C30F1A3930BF3D2FE53FD8CC7" xlink:to="loc_hsy_McLaneCompanyInc.Member_D5C957FB59EB314097B6D2FE53FDF141" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_PromotionalCostsEstimateDeviationPercentage" xlink:label="loc_hsy_PromotionalCostsEstimateDeviationPercentage_6A75C5DD9A47F73CB6C5D2FE53FEF6B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B1F73A3F01140B58B73AD2FE53FEF656" xlink:to="loc_hsy_PromotionalCostsEstimateDeviationPercentage_6A75C5DD9A47F73CB6C5D2FE53FEF6B0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20191231.xsd#hsy_UnsettledAccruedLiabilities" xlink:label="loc_hsy_UnsettledAccruedLiabilities_75E1A1A44831F020F0F3D2FE53FE7C68" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B1F73A3F01140B58B73AD2FE53FEF656" xlink:to="loc_hsy_UnsettledAccruedLiabilities_75E1A1A44831F020F0F3D2FE53FE7C68" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2019/elts/us-gaap-2019-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_B74508E0CEDB306FFCD3D2FE53FFA19E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B1F73A3F01140B58B73AD2FE53FEF656" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_B74508E0CEDB306FFCD3D2FE53FFA19E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SupplementalBalanceSheetInformation" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SupplementalBalanceSheetInformationScheduleOfSupplementalBalanceSheetInformationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/SupplementalBalanceSheetInformationTables" xlink:type="extended" />
</link:linkbase>
</XBRL>
