

<!--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/AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleDetails" xlink:href="hsy-20181231.xsd#AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleNotes" xlink:href="hsy-20181231.xsd#AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleNotes" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleTables" xlink:href="hsy-20181231.xsd#AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitions" xlink:href="hsy-20181231.xsd#BusinessAcquisitions" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAmplifySnackBrandsIncAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsAmplifySnackBrandsIncAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAmplifySnackBrandsIncNarrativeDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsAmplifySnackBrandsIncNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsPirateBrandsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsPirateBrandsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsPirateBrandsNarrativeDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsPirateBrandsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsRippleBrandCollectiveLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsRippleBrandCollectiveLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsRippleBrandCollectiveLlcNarrativeDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsRippleBrandCollectiveLlcNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsShanghaiGoldenMonkeyNarrativeDetails" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsShanghaiGoldenMonkeyNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsTables" xlink:href="hsy-20181231.xsd#BusinessAcquisitionsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivities" xlink:href="hsy-20181231.xsd#BusinessRealignmentActivities" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:href="hsy-20181231.xsd#BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:href="hsy-20181231.xsd#BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:href="hsy-20181231.xsd#BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesTables" xlink:href="hsy-20181231.xsd#BusinessRealignmentActivitiesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingencies" xlink:href="hsy-20181231.xsd#CommitmentsAndContingencies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:href="hsy-20181231.xsd#CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:href="hsy-20181231.xsd#CommitmentsAndContingenciesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:href="hsy-20181231.xsd#CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesTables" xlink:href="hsy-20181231.xsd#CommitmentsAndContingenciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedBalanceSheets" xlink:href="hsy-20181231.xsd#ConsolidatedBalanceSheets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedBalanceSheetsParenthetical" xlink:href="hsy-20181231.xsd#ConsolidatedBalanceSheetsParenthetical" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfCashFlows" xlink:href="hsy-20181231.xsd#ConsolidatedStatementsOfCashFlows" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfComprehensiveIncome" xlink:href="hsy-20181231.xsd#ConsolidatedStatementsOfComprehensiveIncome" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfIncome" xlink:href="hsy-20181231.xsd#ConsolidatedStatementsOfIncome" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquity" xlink:href="hsy-20181231.xsd#ConsolidatedStatementsOfStockholdersEquity" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:href="hsy-20181231.xsd#ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstruments" xlink:href="hsy-20181231.xsd#DerivativeInstruments" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsDerivativeInstrumentsNarrativeDetails" xlink:href="hsy-20181231.xsd#DerivativeInstrumentsDerivativeInstrumentsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:href="hsy-20181231.xsd#DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:href="hsy-20181231.xsd#DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsTables" xlink:href="hsy-20181231.xsd#DerivativeInstrumentsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/DocumentAndEntityInformation" xlink:href="hsy-20181231.xsd#DocumentAndEntityInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShare" xlink:href="hsy-20181231.xsd#EarningsPerShare" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareEarningsPerShareNarrativeDetails" xlink:href="hsy-20181231.xsd#EarningsPerShareEarningsPerShareNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareTables" xlink:href="hsy-20181231.xsd#EarningsPerShareTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterest" xlink:href="hsy-20181231.xsd#EquityAndNoncontrollingInterest" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:href="hsy-20181231.xsd#EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:href="hsy-20181231.xsd#EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:href="hsy-20181231.xsd#EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestTables" xlink:href="hsy-20181231.xsd#EquityAndNoncontrollingInterestTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurements" xlink:href="hsy-20181231.xsd#FairValueMeasurementsFairValueMeasurements" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:href="hsy-20181231.xsd#FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsTables" xlink:href="hsy-20181231.xsd#FairValueMeasurementsFairValueMeasurementsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:href="hsy-20181231.xsd#FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:href="hsy-20181231.xsd#FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssets" xlink:href="hsy-20181231.xsd#GoodwillAndIntangibleAssets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:href="hsy-20181231.xsd#GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:href="hsy-20181231.xsd#GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:href="hsy-20181231.xsd#GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:href="hsy-20181231.xsd#GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsTables" xlink:href="hsy-20181231.xsd#GoodwillAndIntangibleAssetsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxes" xlink:href="hsy-20181231.xsd#IncomeTaxes" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesIncomeTaxesNarrativeDetails" xlink:href="hsy-20181231.xsd#IncomeTaxesIncomeTaxesNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:href="hsy-20181231.xsd#IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:href="hsy-20181231.xsd#IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:href="hsy-20181231.xsd#IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:href="hsy-20181231.xsd#IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:href="hsy-20181231.xsd#IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesTables" xlink:href="hsy-20181231.xsd#IncomeTaxesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:href="hsy-20181231.xsd#OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:href="hsy-20181231.xsd#OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:href="hsy-20181231.xsd#OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlans" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlans" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfAmountsExpectedToBeAmortizedFromAociIntoNetPeriodicBenefitDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfAmountsExpectedToBeAmortizedFromAociIntoNetPeriodicBenefitDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfEffectOfOnePercentChangeInAssumedHealthCareTrendRatesDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfEffectOfOnePercentChangeInAssumedHealthCareTrendRatesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansTables" xlink:href="hsy-20181231.xsd#PensionAndOtherPostRetirementBenefitPlansTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataTables" xlink:href="hsy-20181231.xsd#QuarterlyDataTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataUnaudited" xlink:href="hsy-20181231.xsd#QuarterlyDataUnaudited" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsScheduleIiValuationAndQualifyingAccounts" xlink:href="hsy-20181231.xsd#ScheduleIiValuationAndQualifyingAccountsScheduleIiValuationAndQualifyingAccounts" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsScheduleIiValuationAndQualifyingAccountsDetails" xlink:href="hsy-20181231.xsd#ScheduleIiValuationAndQualifyingAccountsScheduleIiValuationAndQualifyingAccountsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:href="hsy-20181231.xsd#ScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:href="hsy-20181231.xsd#ScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:href="hsy-20181231.xsd#ScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfQuarterlyFinancialInformationDetails" xlink:href="hsy-20181231.xsd#ScheduleOfQuarterlyFinancialInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfSegmentInformationByGeographyDetails" xlink:href="hsy-20181231.xsd#ScheduleOfSegmentInformationByGeographyDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfSupplementalBalanceSheetInformationDetails" xlink:href="hsy-20181231.xsd#ScheduleOfSupplementalBalanceSheetInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformation" xlink:href="hsy-20181231.xsd#SegmentInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationNarrativeDetails" xlink:href="hsy-20181231.xsd#SegmentInformationNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfAdditionalProductLineSalesDetails" xlink:href="hsy-20181231.xsd#SegmentInformationScheduleOfAdditionalProductLineSalesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:href="hsy-20181231.xsd#SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationTables" xlink:href="hsy-20181231.xsd#SegmentInformationTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebt" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebt" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtTables" xlink:href="hsy-20181231.xsd#ShortAndLongTermDebtTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlans" xlink:href="hsy-20181231.xsd#StockCompensationPlans" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:href="hsy-20181231.xsd#StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansTables" xlink:href="hsy-20181231.xsd#StockCompensationPlansTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPolicies" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesTables" xlink:href="hsy-20181231.xsd#SummaryOfSignificantAccountingPoliciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformation" xlink:href="hsy-20181231.xsd#SupplementalBalanceSheetInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformationTables" xlink:href="hsy-20181231.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/AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_7B5A7779D50F0FC6EAABE8D2248AF132" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_7B5A7779D50F0FC6EAABE8D2248AF132" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A302880F8F3341D31A17E8D2248BDCE3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_7B5A7779D50F0FC6EAABE8D2248AF132" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A302880F8F3341D31A17E8D2248BDCE3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_03889D1190F643A63F6BE8D2248B2E7C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A302880F8F3341D31A17E8D2248BDCE3" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_03889D1190F643A63F6BE8D2248B2E7C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_03889D1190F643A63F6BE8D2248B2E7C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_A302880F8F3341D31A17E8D2248BDCE3" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_03889D1190F643A63F6BE8D2248B2E7C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LicensingAgreementsMember" xlink:label="loc_us-gaap_LicensingAgreementsMember_1B91D89133E2E4A80AA2E8D2248B4867" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_03889D1190F643A63F6BE8D2248B2E7C" xlink:to="loc_us-gaap_LicensingAgreementsMember_1B91D89133E2E4A80AA2E8D2248B4867" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_2455BB0ABA6D14F0336BE8D2248CB105" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_7B5A7779D50F0FC6EAABE8D2248AF132" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_2455BB0ABA6D14F0336BE8D2248CB105" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BCFC2407BFA5B918F570E8D2248C1490_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_2455BB0ABA6D14F0336BE8D2248CB105" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BCFC2407BFA5B918F570E8D2248C1490_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BCFC2407BFA5B918F570E8D2248C1490" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_2455BB0ABA6D14F0336BE8D2248CB105" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BCFC2407BFA5B918F570E8D2248C1490" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_TyrrellsandShanghaiGoldenMonkeySGMMember" xlink:label="loc_hsy_TyrrellsandShanghaiGoldenMonkeySGMMember_F76952F5370E4C71EF38E8D2248C35D8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_BCFC2407BFA5B918F570E8D2248C1490" xlink:to="loc_hsy_TyrrellsandShanghaiGoldenMonkeySGMMember_F76952F5370E4C71EF38E8D2248C35D8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_F424AEB78BA9F11BD3A0E8D2248C71CB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_7B5A7779D50F0FC6EAABE8D2248AF132" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_F424AEB78BA9F11BD3A0E8D2248C71CB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_ADA3533B5B762B573180E8D2248C52B6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_F424AEB78BA9F11BD3A0E8D2248C71CB" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_ADA3533B5B762B573180E8D2248C52B6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_ADA3533B5B762B573180E8D2248C52B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_F424AEB78BA9F11BD3A0E8D2248C71CB" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_ADA3533B5B762B573180E8D2248C52B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_76ECD4CF3EDB4B87642CE8D2248DF388" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_ADA3533B5B762B573180E8D2248C52B6" xlink:to="loc_us-gaap_FacilityClosingMember_76ECD4CF3EDB4B87642CE8D2248DF388" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_96CBFC6587087FDAA8DAE8D2248D993F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_7B5A7779D50F0FC6EAABE8D2248AF132" xlink:to="loc_us-gaap_RestructuringPlanAxis_96CBFC6587087FDAA8DAE8D2248D993F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_217B10D03E9FC498B757E8D2248D21EC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_96CBFC6587087FDAA8DAE8D2248D993F" xlink:to="loc_us-gaap_RestructuringPlanDomain_217B10D03E9FC498B757E8D2248D21EC_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_217B10D03E9FC498B757E8D2248D21EC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_96CBFC6587087FDAA8DAE8D2248D993F" xlink:to="loc_us-gaap_RestructuringPlanDomain_217B10D03E9FC498B757E8D2248D21EC" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_BB0D16904C194E2F4F8FE8D2248D8620" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_217B10D03E9FC498B757E8D2248D21EC" xlink:to="loc_hsy_OperationalOptimizationProgramMember_BB0D16904C194E2F4F8FE8D2248D8620" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationPropertyPlantAndEquipment" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationPropertyPlantAndEquipment_7EB75A512C7430EEF859E8D227D01D65" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationPropertyPlantAndEquipment_7EB75A512C7430EEF859E8D227D01D65" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationOtherAssets" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationOtherAssets_7B1D004343FAB3A79A4CE9791014D48C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationOtherAssets_7B1D004343FAB3A79A4CE9791014D48C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation" xlink:label="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_658DCA115BE8EAD9D805E8D2248EE216" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_658DCA115BE8EAD9D805E8D2248EE216" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationAccountsPayableAndAccruedLiabilities" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationAccountsPayableAndAccruedLiabilities_8FFA65EB8EB1149FC5C9E8D2248FD271" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationAccountsPayableAndAccruedLiabilities_8FFA65EB8EB1149FC5C9E8D2248FD271" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation" xlink:label="loc_us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation_4C1AE20C28D4556076A0E8D2248FD2B8" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation_4C1AE20C28D4556076A0E8D2248FD2B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ProceedsFromSaleOfIntangibleAssets" xlink:label="loc_us-gaap_ProceedsFromSaleOfIntangibleAssets_C166C9773FDCC37C6685E8D2248F9B70" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_ProceedsFromSaleOfIntangibleAssets_C166C9773FDCC37C6685E8D2248F9B70" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GainLossOnDispositionOfIntangibleAssets" xlink:label="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_0475F98A26147E03E11EE8D2248F49AA" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_0475F98A26147E03E11EE8D2248F49AA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment" xlink:label="loc_us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment_831B20A1FB9261E4E647E8D2248F16B5" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment_831B20A1FB9261E4E647E8D2248F16B5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GainLossOnSaleOfPropertyPlantEquipment" xlink:label="loc_us-gaap_GainLossOnSaleOfPropertyPlantEquipment_187F785BBD0D5BE4B6F0E8D2248F3624" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_GainLossOnSaleOfPropertyPlantEquipment_187F785BBD0D5BE4B6F0E8D2248F3624" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ProceedsFromDivestitureOfBusinesses" xlink:label="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_A7568809DF46F515BEADE8D224904020" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_A7568809DF46F515BEADE8D224904020" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_A816E9AE24297965EE9DE8D22490EA8D" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_B59D9DEFF6810FF54C91E8D2248E9C21" xlink:to="loc_us-gaap_AssetImpairmentCharges_A816E9AE24297965EE9DE8D22490EA8D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleNotes" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/AssetsAndLiabilitiesHeldForSaleAssetsAndLiabilitiesHeldForSaleTables" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_A2F484F2D69AB20981D1C99CDF395FBF" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3BA617360C7A4F9CD3D1C99CDF383722" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_A2F484F2D69AB20981D1C99CDF395FBF" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3BA617360C7A4F9CD3D1C99CDF383722" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_5FC2A0B8D2D74D20F114C99CDF382EEC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3BA617360C7A4F9CD3D1C99CDF383722" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_5FC2A0B8D2D74D20F114C99CDF382EEC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_BF88D6921C5FAD89D435C99CDF38D4D6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_5FC2A0B8D2D74D20F114C99CDF382EEC" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_BF88D6921C5FAD89D435C99CDF38D4D6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_BF88D6921C5FAD89D435C99CDF38D4D6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_5FC2A0B8D2D74D20F114C99CDF382EEC" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_BF88D6921C5FAD89D435C99CDF38D4D6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupClassificationAxis" xlink:label="loc_us-gaap_DisposalGroupClassificationAxis_019D6395DCF8CE93B68EC99CDF38011C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3BA617360C7A4F9CD3D1C99CDF383722" xlink:to="loc_us-gaap_DisposalGroupClassificationAxis_019D6395DCF8CE93B68EC99CDF38011C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_4FAB567209521B96A796C99CDF393EE3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_019D6395DCF8CE93B68EC99CDF38011C" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_4FAB567209521B96A796C99CDF393EE3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_4FAB567209521B96A796C99CDF393EE3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_019D6395DCF8CE93B68EC99CDF38011C" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_4FAB567209521B96A796C99CDF393EE3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_3AA5B24A1CF542590929C99CDF39F62C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_3BA617360C7A4F9CD3D1C99CDF383722" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_3AA5B24A1CF542590929C99CDF39F62C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_3395F44AAF1153614708C99CDF392582_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_3AA5B24A1CF542590929C99CDF39F62C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_3395F44AAF1153614708C99CDF392582_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_3395F44AAF1153614708C99CDF392582" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_3AA5B24A1CF542590929C99CDF39F62C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_3395F44AAF1153614708C99CDF392582" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDisposalGroupsIncludingDiscontinuedOperationsIncomeStatementBalanceSheetAndAdditionalDisclosuresTextBlock" xlink:label="loc_us-gaap_ScheduleOfDisposalGroupsIncludingDiscontinuedOperationsIncomeStatementBalanceSheetAndAdditionalDisclosuresTextBlock_A12C7480ED40956619B2C99CDF390537" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_A2F484F2D69AB20981D1C99CDF395FBF" xlink:to="loc_us-gaap_ScheduleOfDisposalGroupsIncludingDiscontinuedOperationsIncomeStatementBalanceSheetAndAdditionalDisclosuresTextBlock_A12C7480ED40956619B2C99CDF390537" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_D20A41FFEDA55CB99631C534A2F4431D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_D20A41FFEDA55CB99631C534A2F4431D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_173D08ED8C4807B4099FC534A2F512E4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_D20A41FFEDA55CB99631C534A2F4431D" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_173D08ED8C4807B4099FC534A2F512E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B07E07FEF6416B91D128C534A2FA49A3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_173D08ED8C4807B4099FC534A2F512E4" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B07E07FEF6416B91D128C534A2FA49A3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B07E07FEF6416B91D128C534A2FA49A3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_173D08ED8C4807B4099FC534A2F512E4" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B07E07FEF6416B91D128C534A2FA49A3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_3366FF90012F0818D235C534A2FB5F6E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B07E07FEF6416B91D128C534A2FA49A3" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_3366FF90012F0818D235C534A2FB5F6E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_D48F64AFFFEB8BEF311DC534A2FB64AE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_D20A41FFEDA55CB99631C534A2F4431D" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_D48F64AFFFEB8BEF311DC534A2FB64AE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_6CBEF482CCDD090B4FD2C534A2FB7949_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_D48F64AFFFEB8BEF311DC534A2FB64AE" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_6CBEF482CCDD090B4FD2C534A2FB7949_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_6CBEF482CCDD090B4FD2C534A2FB7949" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_D48F64AFFFEB8BEF311DC534A2FB64AE" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_6CBEF482CCDD090B4FD2C534A2FB7949" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_C53EE1DDBB42C1DD00BBC534A2FBA4F2" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_D20A41FFEDA55CB99631C534A2F4431D" xlink:to="loc_srt_OwnershipAxis_C53EE1DDBB42C1DD00BBC534A2FBA4F2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_2AFD42442DC0A8DFFE45C534A2FBFC92_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_C53EE1DDBB42C1DD00BBC534A2FBA4F2" xlink:to="loc_srt_OwnershipDomain_2AFD42442DC0A8DFFE45C534A2FBFC92_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_2AFD42442DC0A8DFFE45C534A2FBFC92" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_C53EE1DDBB42C1DD00BBC534A2FBA4F2" xlink:to="loc_srt_OwnershipDomain_2AFD42442DC0A8DFFE45C534A2FBFC92" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_F7407DD056DB1CD02404C534A2FCD397" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_D20A41FFEDA55CB99631C534A2F4431D" xlink:to="loc_us-gaap_StatementClassOfStockAxis_F7407DD056DB1CD02404C534A2FCD397" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_30CFAD86B3D05A932BEEC534A2FC17A8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_F7407DD056DB1CD02404C534A2FCD397" xlink:to="loc_us-gaap_ClassOfStockDomain_30CFAD86B3D05A932BEEC534A2FC17A8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_30CFAD86B3D05A932BEEC534A2FC17A8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_F7407DD056DB1CD02404C534A2FCD397" xlink:to="loc_us-gaap_ClassOfStockDomain_30CFAD86B3D05A932BEEC534A2FC17A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_9C44530FA214BE2C9438C534A2FCF44A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_9C44530FA214BE2C9438C534A2FCF44A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssets" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssets_DFA5D253147256B0B591C534A2FD98FF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssets_DFA5D253147256B0B591C534A2FD98FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_12E2C4A0B3709FCB61E4C534A2FD2600" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_12E2C4A0B3709FCB61E4C534A2FD2600" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_4DC0413FB1A6A3AD9D46C534A2FD9EA3" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_4DC0413FB1A6A3AD9D46C534A2FD9EA3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_F20DC6C18329AAB62D3BC534A2FD28F1" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_Goodwill_F20DC6C18329AAB62D3BC534A2FD28F1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_4761E8321CD6A0964F6DC534A2FD9D41" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_4761E8321CD6A0964F6DC534A2FD9D41" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentAssets" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentAssets_EBA94EE59E362F6C6019C534A2FDD021" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentAssets_EBA94EE59E362F6C6019C534A2FDD021" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesAccountsPayable" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesAccountsPayable_985C314F19CF3BD18DBFC534A2FE36FD" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesAccountsPayable_985C314F19CF3BD18DBFC534A2FE36FD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities" xlink:label="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_85983E739618B2EE5446C534A2FE32F6" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_85983E739618B2EE5446C534A2FE32F6" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesDebt" xlink:label="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesDebt_08F0D4107B0190A168CAC534A2FE4490" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesDebt_08F0D4107B0190A168CAC534A2FE4490" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther_67759271057FC1BF129FC534A2FE2AC8" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilitiesOther_67759271057FC1BF129FC534A2FE2AC8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilitiesNoncurrent" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilitiesNoncurrent_87542E1186F1F9E075CBC534A2FEC1BD" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilitiesNoncurrent_87542E1186F1F9E075CBC534A2FEC1BD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilities" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilities_378925EC3CE1670E3352C534A2FE1CFD" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilities_378925EC3CE1670E3352C534A2FE1CFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_98F78C2540A436D5CC36C534A2FF992A" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_925E2127829C1BAE2E30C534A2FCE1C5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_98F78C2540A436D5CC36C534A2FF992A" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_68C24A66DAA4DF460C47CE58B4D35CC7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:to="loc_srt_RangeAxis_68C24A66DAA4DF460C47CE58B4D35CC7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_2172FA22B794DD835FA2CE58B4D3FBA8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_68C24A66DAA4DF460C47CE58B4D35CC7" xlink:to="loc_srt_RangeMember_2172FA22B794DD835FA2CE58B4D3FBA8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_2172FA22B794DD835FA2CE58B4D3FBA8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_68C24A66DAA4DF460C47CE58B4D35CC7" xlink:to="loc_srt_RangeMember_2172FA22B794DD835FA2CE58B4D3FBA8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_3B070523ABCE6D3A807BCE58B4D32772" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_2172FA22B794DD835FA2CE58B4D3FBA8" xlink:to="loc_srt_MinimumMember_3B070523ABCE6D3A807BCE58B4D32772" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_1CA7F4ED719DE046C943CE58B4D32D5C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_2172FA22B794DD835FA2CE58B4D3FBA8" xlink:to="loc_srt_MaximumMember_1CA7F4ED719DE046C943CE58B4D32D5C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FC9D86C6F5AEBBCF3823CE58B4D41861" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FC9D86C6F5AEBBCF3823CE58B4D41861" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_CFF21A6E00803B18F397CE58B4D4959B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FC9D86C6F5AEBBCF3823CE58B4D41861" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_CFF21A6E00803B18F397CE58B4D4959B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_CFF21A6E00803B18F397CE58B4D4959B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_FC9D86C6F5AEBBCF3823CE58B4D41861" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_CFF21A6E00803B18F397CE58B4D4959B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_913188AF0C8FA0AE3B16CE58B4D4F378" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_CFF21A6E00803B18F397CE58B4D4959B" xlink:to="loc_us-gaap_TrademarksMember_913188AF0C8FA0AE3B16CE58B4D4F378" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_D3711A5D6313C885C2D4CE58B4D50F53" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_CFF21A6E00803B18F397CE58B4D4959B" xlink:to="loc_us-gaap_CustomerRelationshipsMember_D3711A5D6313C885C2D4CE58B4D50F53" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_65D9624D2F80D9811A36CE58B4D55019" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_65D9624D2F80D9811A36CE58B4D55019" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_33640B7DA38BC8AD000FCE58B4D5A3B0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_65D9624D2F80D9811A36CE58B4D55019" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_33640B7DA38BC8AD000FCE58B4D5A3B0_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_33640B7DA38BC8AD000FCE58B4D5A3B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_65D9624D2F80D9811A36CE58B4D55019" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_33640B7DA38BC8AD000FCE58B4D5A3B0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_8669F8D9FD534F516008CE58B4D58C50" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_33640B7DA38BC8AD000FCE58B4D5A3B0" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_8669F8D9FD534F516008CE58B4D58C50" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_1453E4D4CDCDF2C07899CE58B4D5DEBF" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_1453E4D4CDCDF2C07899CE58B4D5DEBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_05A2ABC62C9DEB0436ADCE58B4DB5383_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_1453E4D4CDCDF2C07899CE58B4D5DEBF" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_05A2ABC62C9DEB0436ADCE58B4DB5383_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_05A2ABC62C9DEB0436ADCE58B4DB5383" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_1453E4D4CDCDF2C07899CE58B4D5DEBF" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_05A2ABC62C9DEB0436ADCE58B4DB5383" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_4209A92E8D8A1E69825DCE58B4DB10D0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:to="loc_srt_OwnershipAxis_4209A92E8D8A1E69825DCE58B4DB10D0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_348B18BBE27D3958CE16CE58B4DB0219_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_4209A92E8D8A1E69825DCE58B4DB10D0" xlink:to="loc_srt_OwnershipDomain_348B18BBE27D3958CE16CE58B4DB0219_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_348B18BBE27D3958CE16CE58B4DB0219" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_4209A92E8D8A1E69825DCE58B4DB10D0" xlink:to="loc_srt_OwnershipDomain_348B18BBE27D3958CE16CE58B4DB0219" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_88493F53203546187910CE58B4DC56BE" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_AE8AF31BDE870F27160FCE58B4D2D943" xlink:to="loc_us-gaap_StatementClassOfStockAxis_88493F53203546187910CE58B4DC56BE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_EB1660A6CEC0343522B3CE58B4DC3A4A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_88493F53203546187910CE58B4DC56BE" xlink:to="loc_us-gaap_ClassOfStockDomain_EB1660A6CEC0343522B3CE58B4DC3A4A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_EB1660A6CEC0343522B3CE58B4DC3A4A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_88493F53203546187910CE58B4DC56BE" xlink:to="loc_us-gaap_ClassOfStockDomain_EB1660A6CEC0343522B3CE58B4DC3A4A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationConsiderationTransferred1" xlink:label="loc_us-gaap_BusinessCombinationConsiderationTransferred1_B1D7E3C7458617B811E1CE58B9BD1492" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_BusinessCombinationConsiderationTransferred1_B1D7E3C7458617B811E1CE58B9BD1492" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionSharePrice" xlink:label="loc_us-gaap_BusinessAcquisitionSharePrice_FE14D45CD22F7F0802C1CE58B4DD5DEE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_BusinessAcquisitionSharePrice_FE14D45CD22F7F0802C1CE58B4DD5DEE" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_BusinessAcquisitionEquityInterestsReceivedCommonStockValue" xlink:label="loc_hsy_BusinessAcquisitionEquityInterestsReceivedCommonStockValue_D567207F3312436CDEBECE58B4DDF668" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_hsy_BusinessAcquisitionEquityInterestsReceivedCommonStockValue_D567207F3312436CDEBECE58B4DDF668" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillPurchaseAccountingAdjustments" xlink:label="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_EEBC38E2F411BB8E2723CE58B4DDBE3C" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_EEBC38E2F411BB8E2723CE58B4DDBE3C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedTrademarksGross" xlink:label="loc_us-gaap_FiniteLivedTrademarksGross_8E193C0E3057A1DA7F7ACE58B4DDB0DA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_FiniteLivedTrademarksGross_8E193C0E3057A1DA7F7ACE58B4DDB0DA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedCustomerRelationshipsGross" xlink:label="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_F70EF7BEE1E842FF7B04CE58B4DDF802" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_F70EF7BEE1E842FF7B04CE58B4DDF802" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_03219FB75E2B09EFB39DCE58B4DE1430" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_03219FB75E2B09EFB39DCE58B4DE1430" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationAcquisitionRelatedCosts" xlink:label="loc_us-gaap_BusinessCombinationAcquisitionRelatedCosts_9A39FEB6A45ED2B8E00DCE58B4DE8072" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_5ADD71D3229A9C578771CE58B4DC4A47" xlink:to="loc_us-gaap_BusinessCombinationAcquisitionRelatedCosts_9A39FEB6A45ED2B8E00DCE58B4DE8072" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2F1BFB697AD618BE5FF7C534A32D48FC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2F1BFB697AD618BE5FF7C534A32D48FC" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_8DCB1435D014F0E795C9C534A32D8B73" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2F1BFB697AD618BE5FF7C534A32D48FC" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_8DCB1435D014F0E795C9C534A32D8B73" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_832183FBAB6743CD86F2C534A32D0551_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_8DCB1435D014F0E795C9C534A32D8B73" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_832183FBAB6743CD86F2C534A32D0551_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_832183FBAB6743CD86F2C534A32D0551" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_8DCB1435D014F0E795C9C534A32D8B73" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_832183FBAB6743CD86F2C534A32D0551" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PirateBrandsMember" xlink:label="loc_hsy_PirateBrandsMember_A006B6E23430CB31F390C534A32E6F34" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_832183FBAB6743CD86F2C534A32D0551" xlink:to="loc_hsy_PirateBrandsMember_A006B6E23430CB31F390C534A32E6F34" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_8B9BAEE2647DA7DBE9F8C534A32E52DE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2F1BFB697AD618BE5FF7C534A32D48FC" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_8B9BAEE2647DA7DBE9F8C534A32E52DE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_616DA645AF9B1927EAF0C534A32EF18E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_8B9BAEE2647DA7DBE9F8C534A32E52DE" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_616DA645AF9B1927EAF0C534A32EF18E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_616DA645AF9B1927EAF0C534A32EF18E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_8B9BAEE2647DA7DBE9F8C534A32E52DE" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_616DA645AF9B1927EAF0C534A32EF18E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_AFDCAED7A42FBF4BB300C534A32F3A5E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2F1BFB697AD618BE5FF7C534A32D48FC" xlink:to="loc_srt_OwnershipAxis_AFDCAED7A42FBF4BB300C534A32F3A5E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_58EF8DF297EC7B8684D4C534A32F9957_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_AFDCAED7A42FBF4BB300C534A32F3A5E" xlink:to="loc_srt_OwnershipDomain_58EF8DF297EC7B8684D4C534A32F9957_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_58EF8DF297EC7B8684D4C534A32F9957" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_AFDCAED7A42FBF4BB300C534A32F3A5E" xlink:to="loc_srt_OwnershipDomain_58EF8DF297EC7B8684D4C534A32F9957" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_52CEA98ACCC2A3DBCD17C534A32F357E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2F1BFB697AD618BE5FF7C534A32D48FC" xlink:to="loc_us-gaap_StatementClassOfStockAxis_52CEA98ACCC2A3DBCD17C534A32F357E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_3D75CB43AE3C10DADB1EC534A32F731A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_52CEA98ACCC2A3DBCD17C534A32F357E" xlink:to="loc_us-gaap_ClassOfStockDomain_3D75CB43AE3C10DADB1EC534A32F731A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_3D75CB43AE3C10DADB1EC534A32F731A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_52CEA98ACCC2A3DBCD17C534A32F357E" xlink:to="loc_us-gaap_ClassOfStockDomain_3D75CB43AE3C10DADB1EC534A32F731A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedInventory" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedInventory_4A34C47A90311500FFCBC534A330900C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedInventory_4A34C47A90311500FFCBC534A330900C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_3E0360FF29142E4D5178C534A330A161" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedEquipment_3E0360FF29142E4D5178C534A330A161" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_A288C300805DCBF5471FC534A3306A89" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_us-gaap_Goodwill_A288C300805DCBF5471FC534A3306A89" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_490E2916FDA6C551CC81C534A330EDC8" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_490E2916FDA6C551CC81C534A330EDC8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities" xlink:label="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_1385390E1EEE27D26C91C534A3303FC1" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_hsy_BusinessCombinationRecognizedIdentifiableAssetsAcquiredandLiabilitiesAssumedCurrentLiabilitiesAccruedLiabilities_1385390E1EEE27D26C91C534A3303FC1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_A2BA08FAE893B9A79C5CC534A33137A0" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_075BC93165565A8DB797C534A32F077F" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_A2BA08FAE893B9A79C5CC534A33137A0" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_3B264EE7B54260676AFAE9BB6159F05E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_us-gaap_StatementScenarioAxis_3B264EE7B54260676AFAE9BB6159F05E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_18D1FEC07E58A62F0A0BE9BB65759A2E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_3B264EE7B54260676AFAE9BB6159F05E" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_18D1FEC07E58A62F0A0BE9BB65759A2E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_18D1FEC07E58A62F0A0BE9BB65759A2E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_3B264EE7B54260676AFAE9BB6159F05E" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_18D1FEC07E58A62F0A0BE9BB65759A2E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_7223EA4BD78C6FD05116E9BBA0E84C52" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_18D1FEC07E58A62F0A0BE9BB65759A2E" xlink:to="loc_us-gaap_ScenarioForecastMember_7223EA4BD78C6FD05116E9BBA0E84C52" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_5D7B34C655561F4DD10DE9BB147D690B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_srt_RangeAxis_5D7B34C655561F4DD10DE9BB147D690B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_986DCA7B4139E0775EAFE9BB147E068D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_5D7B34C655561F4DD10DE9BB147D690B" xlink:to="loc_srt_RangeMember_986DCA7B4139E0775EAFE9BB147E068D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_986DCA7B4139E0775EAFE9BB147E068D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_5D7B34C655561F4DD10DE9BB147D690B" xlink:to="loc_srt_RangeMember_986DCA7B4139E0775EAFE9BB147E068D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_F75C0460B837BEE40341E9BB147EC8D1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_986DCA7B4139E0775EAFE9BB147E068D" xlink:to="loc_srt_MinimumMember_F75C0460B837BEE40341E9BB147EC8D1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_1BEA3DE005E80F3657D3E9BB147F6F2A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_986DCA7B4139E0775EAFE9BB147E068D" xlink:to="loc_srt_MaximumMember_1BEA3DE005E80F3657D3E9BB147F6F2A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22689CDC08E83F72B525E9BB147FF59B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22689CDC08E83F72B525E9BB147FF59B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_70CDE1930708963CBDC4E9BB147FDCF6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22689CDC08E83F72B525E9BB147FF59B" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_70CDE1930708963CBDC4E9BB147FDCF6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_70CDE1930708963CBDC4E9BB147FDCF6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22689CDC08E83F72B525E9BB147FF59B" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_70CDE1930708963CBDC4E9BB147FDCF6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_56D723AB377A7737F3B5E9BB147FE605" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_70CDE1930708963CBDC4E9BB147FDCF6" xlink:to="loc_us-gaap_TrademarksMember_56D723AB377A7737F3B5E9BB147FE605" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_D02F50D232374DC68A89E9BB1480781A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_70CDE1930708963CBDC4E9BB147FDCF6" xlink:to="loc_us-gaap_CustomerRelationshipsMember_D02F50D232374DC68A89E9BB1480781A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_CBF0273CC3D1F6C02FC1E9BB148052BE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_CBF0273CC3D1F6C02FC1E9BB148052BE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_19EB046BA58FB4D6DC27E9BB14805E7A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_CBF0273CC3D1F6C02FC1E9BB148052BE" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_19EB046BA58FB4D6DC27E9BB14805E7A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_19EB046BA58FB4D6DC27E9BB14805E7A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_CBF0273CC3D1F6C02FC1E9BB148052BE" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_19EB046BA58FB4D6DC27E9BB14805E7A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PirateBrandsMember" xlink:label="loc_hsy_PirateBrandsMember_E35676270C7688AAC2D1E9BB14819EA1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_19EB046BA58FB4D6DC27E9BB14805E7A" xlink:to="loc_hsy_PirateBrandsMember_E35676270C7688AAC2D1E9BB14819EA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_5E011DB74CA117692EA9E9BB1481CCBB" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_5E011DB74CA117692EA9E9BB1481CCBB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_47ABAFCDCC7DDB84A928E9BB1481CDFF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_5E011DB74CA117692EA9E9BB1481CCBB" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_47ABAFCDCC7DDB84A928E9BB1481CDFF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_47ABAFCDCC7DDB84A928E9BB1481CDFF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_5E011DB74CA117692EA9E9BB1481CCBB" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_47ABAFCDCC7DDB84A928E9BB1481CDFF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_5CBC4B2A20FA9B6237AEE9BB148251CF" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_srt_OwnershipAxis_5CBC4B2A20FA9B6237AEE9BB148251CF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_9E5407EF51FEDB91CBA8E9BB148267EA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_5CBC4B2A20FA9B6237AEE9BB148251CF" xlink:to="loc_srt_OwnershipDomain_9E5407EF51FEDB91CBA8E9BB148267EA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_9E5407EF51FEDB91CBA8E9BB148267EA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_5CBC4B2A20FA9B6237AEE9BB148251CF" xlink:to="loc_srt_OwnershipDomain_9E5407EF51FEDB91CBA8E9BB148267EA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_62272A5C11F7269566EFE9BB14823DC6" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_CB7B1B1C0F5B25FF4CC0E9BB147D2C9B" xlink:to="loc_us-gaap_StatementClassOfStockAxis_62272A5C11F7269566EFE9BB14823DC6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_829AF68DF4DC3C09E87DE9BB14837C61_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_62272A5C11F7269566EFE9BB14823DC6" xlink:to="loc_us-gaap_ClassOfStockDomain_829AF68DF4DC3C09E87DE9BB14837C61_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_829AF68DF4DC3C09E87DE9BB14837C61" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_62272A5C11F7269566EFE9BB14823DC6" xlink:to="loc_us-gaap_ClassOfStockDomain_829AF68DF4DC3C09E87DE9BB14837C61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_62278EBA8E28AF3FDF26E9BB14830B15" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:to="loc_us-gaap_Revenues_62278EBA8E28AF3FDF26E9BB14830B15" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationConsiderationTransferred1" xlink:label="loc_us-gaap_BusinessCombinationConsiderationTransferred1_F0FDB2B2BD7726873A94E9BB1483342C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:to="loc_us-gaap_BusinessCombinationConsiderationTransferred1_F0FDB2B2BD7726873A94E9BB1483342C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedTrademarksGross" xlink:label="loc_us-gaap_FiniteLivedTrademarksGross_5F20718CDCC4A569AC26E9BB1484516B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:to="loc_us-gaap_FiniteLivedTrademarksGross_5F20718CDCC4A569AC26E9BB1484516B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedCustomerRelationshipsGross" xlink:label="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_150A0C4DD0B426816DE7E9BB1484B527" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:to="loc_us-gaap_FiniteLivedCustomerRelationshipsGross_150A0C4DD0B426816DE7E9BB1484B527" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_7AB95563FD18DD5FC48EE9BB14845C67" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_862EEF7F141C5FB53DB0E9BB14838F27" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_7AB95563FD18DD5FC48EE9BB14845C67" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsRippleBrandCollectiveLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3DF91CF0F08A2EDED957C534A2DE6A2F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3DF91CF0F08A2EDED957C534A2DE6A2F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_B310347DF5A081D93DFFC534A2DF8B28_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3DF91CF0F08A2EDED957C534A2DE6A2F" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_B310347DF5A081D93DFFC534A2DF8B28_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_B310347DF5A081D93DFFC534A2DF8B28" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3DF91CF0F08A2EDED957C534A2DE6A2F" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_B310347DF5A081D93DFFC534A2DF8B28" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_A077B816E86722208230C534A2DFD06B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_B310347DF5A081D93DFFC534A2DF8B28" xlink:to="loc_us-gaap_TrademarksMember_A077B816E86722208230C534A2DFD06B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherIntangibleAssetsMember" xlink:label="loc_us-gaap_OtherIntangibleAssetsMember_E34CD59D2D754E56F20DC534A2DFF3EC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_B310347DF5A081D93DFFC534A2DF8B28" xlink:to="loc_us-gaap_OtherIntangibleAssetsMember_E34CD59D2D754E56F20DC534A2DFF3EC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_40C56AE62BB4D99DAF77C534A2DF6C72" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:to="loc_srt_RangeAxis_40C56AE62BB4D99DAF77C534A2DF6C72" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_6A71607DDAAB71BF7B84C534A2E01508_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_40C56AE62BB4D99DAF77C534A2DF6C72" xlink:to="loc_srt_RangeMember_6A71607DDAAB71BF7B84C534A2E01508_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_6A71607DDAAB71BF7B84C534A2E01508" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_40C56AE62BB4D99DAF77C534A2DF6C72" xlink:to="loc_srt_RangeMember_6A71607DDAAB71BF7B84C534A2E01508" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_1C6A705FE137E886FE6FC534A2E0E95F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:to="loc_us-gaap_StatementScenarioAxis_1C6A705FE137E886FE6FC534A2E0E95F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_B0D497E5F17A1B398A2FC534A2E09D74_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_1C6A705FE137E886FE6FC534A2E0E95F" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_B0D497E5F17A1B398A2FC534A2E09D74_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_B0D497E5F17A1B398A2FC534A2E09D74" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_1C6A705FE137E886FE6FC534A2E0E95F" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_B0D497E5F17A1B398A2FC534A2E09D74" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_664868ABD5081A2A7CB5C534A2E0361F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_664868ABD5081A2A7CB5C534A2E0361F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8B2C02382A4D81B99AEBC534A2E19658_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_664868ABD5081A2A7CB5C534A2E0361F" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8B2C02382A4D81B99AEBC534A2E19658_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8B2C02382A4D81B99AEBC534A2E19658" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_664868ABD5081A2A7CB5C534A2E0361F" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8B2C02382A4D81B99AEBC534A2E19658" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RippleBrandCollectiveLLCMember" xlink:label="loc_hsy_RippleBrandCollectiveLLCMember_27EE7D0A8049BF813231C534A2E12580" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8B2C02382A4D81B99AEBC534A2E19658" xlink:to="loc_hsy_RippleBrandCollectiveLLCMember_27EE7D0A8049BF813231C534A2E12580" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_236C81065FD8A0073D32C534A2E1BFA7" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_90EE5C76F6D122CAEDB8C534A2DEC369" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_236C81065FD8A0073D32C534A2E1BFA7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_0D7C585D046F2F74BD24C534A2E1FBD7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_236C81065FD8A0073D32C534A2E1BFA7" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_0D7C585D046F2F74BD24C534A2E1FBD7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_0D7C585D046F2F74BD24C534A2E1FBD7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_236C81065FD8A0073D32C534A2E1BFA7" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_0D7C585D046F2F74BD24C534A2E1FBD7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_53CEE53FBE1458F25513C534A2E29651" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_Goodwill_53CEE53FBE1458F25513C534A2E29651" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_3B7A6031E8123C30F6E5C534A2E2DB88" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_3B7A6031E8123C30F6E5C534A2E2DB88" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_9D23A0244C1D1AD5B8E1C534A2E2A8B9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_9D23A0244C1D1AD5B8E1C534A2E2A8B9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_710457D9CF3C5F62B7B6C534A2E2041A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_710457D9CF3C5F62B7B6C534A2E2041A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities_583B2E91786A332D8A1FC534A2E313B5" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities_583B2E91786A332D8A1FC534A2E313B5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_74222AE8043DADA0FDF4C534A2E3B601" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BDA0ABE683EBEF4A7332C534A2E261A4" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_74222AE8043DADA0FDF4C534A2E3B601" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsRippleBrandCollectiveLlcNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_9114B0CED03115A1BA4FC534A2C75A23" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_200169417E813EC5A30CC534A2C44843" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9114B0CED03115A1BA4FC534A2C75A23" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_200169417E813EC5A30CC534A2C44843" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_70D5A5D52E4F20B1F199C534A2C57433" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_200169417E813EC5A30CC534A2C44843" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_70D5A5D52E4F20B1F199C534A2C57433" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1BB6F19641090BF1CF64C534A2C5E2CD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_70D5A5D52E4F20B1F199C534A2C57433" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1BB6F19641090BF1CF64C534A2C5E2CD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1BB6F19641090BF1CF64C534A2C5E2CD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_70D5A5D52E4F20B1F199C534A2C57433" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1BB6F19641090BF1CF64C534A2C5E2CD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RippleBrandCollectiveLLCMember" xlink:label="loc_hsy_RippleBrandCollectiveLLCMember_C3F941BD7F44E6D964E8C534A2C5B5AE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1BB6F19641090BF1CF64C534A2C5E2CD" xlink:to="loc_hsy_RippleBrandCollectiveLLCMember_C3F941BD7F44E6D964E8C534A2C5B5AE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_27FA3FFEB2B49D05EFEAC534A2C516D9" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_200169417E813EC5A30CC534A2C44843" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_27FA3FFEB2B49D05EFEAC534A2C516D9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4BE6A2E126B9FFF4E043C534A2C6F78F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_27FA3FFEB2B49D05EFEAC534A2C516D9" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4BE6A2E126B9FFF4E043C534A2C6F78F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4BE6A2E126B9FFF4E043C534A2C6F78F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_27FA3FFEB2B49D05EFEAC534A2C516D9" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4BE6A2E126B9FFF4E043C534A2C6F78F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_ACCFE694C49409455848C534A2C64894" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4BE6A2E126B9FFF4E043C534A2C6F78F" xlink:to="loc_us-gaap_TrademarksMember_ACCFE694C49409455848C534A2C64894" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherIntangibleAssetsMember" xlink:label="loc_us-gaap_OtherIntangibleAssetsMember_292C5FEC3F0E42E4BD9AC534A2C631F1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4BE6A2E126B9FFF4E043C534A2C6F78F" xlink:to="loc_us-gaap_OtherIntangibleAssetsMember_292C5FEC3F0E42E4BD9AC534A2C631F1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_1137B4D05C63B6E17076C534A2C6FD6B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_200169417E813EC5A30CC534A2C44843" xlink:to="loc_srt_RangeAxis_1137B4D05C63B6E17076C534A2C6FD6B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_C4EA5AB956DB375808FDC534A2C6AFF9_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_1137B4D05C63B6E17076C534A2C6FD6B" xlink:to="loc_srt_RangeMember_C4EA5AB956DB375808FDC534A2C6AFF9_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_C4EA5AB956DB375808FDC534A2C6AFF9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_1137B4D05C63B6E17076C534A2C6FD6B" xlink:to="loc_srt_RangeMember_C4EA5AB956DB375808FDC534A2C6AFF9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_B7D38999CD87EB91EAF0C534A2C7A834" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_C4EA5AB956DB375808FDC534A2C6AFF9" xlink:to="loc_srt_MinimumMember_B7D38999CD87EB91EAF0C534A2C7A834" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_0B24988354611944FA96C534A2C70CDE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_C4EA5AB956DB375808FDC534A2C6AFF9" xlink:to="loc_srt_MaximumMember_0B24988354611944FA96C534A2C70CDE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_703644FE77FDD2564EE1C534A2C72CF9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_9114B0CED03115A1BA4FC534A2C75A23" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_703644FE77FDD2564EE1C534A2C72CF9" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsShanghaiGoldenMonkeyNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_EB5A4D848D36D5DCD6F7DCEB435833DC" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2C76513D986C2E69C8AFDCEB4356046E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_EB5A4D848D36D5DCD6F7DCEB435833DC" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2C76513D986C2E69C8AFDCEB4356046E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_D1E9CB9BFDC1431BA0D4DCEB43564922" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2C76513D986C2E69C8AFDCEB4356046E" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_D1E9CB9BFDC1431BA0D4DCEB43564922" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8953E8FE4FC5F8E576CCDCEB435640AD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_D1E9CB9BFDC1431BA0D4DCEB43564922" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8953E8FE4FC5F8E576CCDCEB435640AD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8953E8FE4FC5F8E576CCDCEB435640AD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_D1E9CB9BFDC1431BA0D4DCEB43564922" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8953E8FE4FC5F8E576CCDCEB435640AD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member" xlink:label="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_6F4015C8BAB20E040571DCEB43573A29" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_8953E8FE4FC5F8E576CCDCEB435640AD" xlink:to="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_6F4015C8BAB20E040571DCEB43573A29" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_377BF1AA1D11D4DEF2CDDCEB4357012C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2C76513D986C2E69C8AFDCEB4356046E" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_377BF1AA1D11D4DEF2CDDCEB4357012C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_097C24EE955F1AB58C8BDCEB43570E76_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_377BF1AA1D11D4DEF2CDDCEB4357012C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_097C24EE955F1AB58C8BDCEB43570E76_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_097C24EE955F1AB58C8BDCEB43570E76" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_377BF1AA1D11D4DEF2CDDCEB4357012C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_097C24EE955F1AB58C8BDCEB43570E76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipAxis" xlink:label="loc_srt_OwnershipAxis_4D04DE3957E5639EBCBBDCEB435879FE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2C76513D986C2E69C8AFDCEB4356046E" xlink:to="loc_srt_OwnershipAxis_4D04DE3957E5639EBCBBDCEB435879FE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_B7EB653F9DAAC99BF6FDDCEB435831A5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_OwnershipAxis_4D04DE3957E5639EBCBBDCEB435879FE" xlink:to="loc_srt_OwnershipDomain_B7EB653F9DAAC99BF6FDDCEB435831A5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_OwnershipDomain" xlink:label="loc_srt_OwnershipDomain_B7EB653F9DAAC99BF6FDDCEB435831A5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_OwnershipAxis_4D04DE3957E5639EBCBBDCEB435879FE" xlink:to="loc_srt_OwnershipDomain_B7EB653F9DAAC99BF6FDDCEB435831A5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_5A6FE35CB5767F0F33DDDCEB43582749" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_2C76513D986C2E69C8AFDCEB4356046E" xlink:to="loc_us-gaap_StatementClassOfStockAxis_5A6FE35CB5767F0F33DDDCEB43582749" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_399EDF2694541568A2D8DCEB43587AA6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_5A6FE35CB5767F0F33DDDCEB43582749" xlink:to="loc_us-gaap_ClassOfStockDomain_399EDF2694541568A2D8DCEB43587AA6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_399EDF2694541568A2D8DCEB43587AA6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_5A6FE35CB5767F0F33DDDCEB43582749" xlink:to="loc_us-gaap_ClassOfStockDomain_399EDF2694541568A2D8DCEB43587AA6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionPercentageOfVotingInterestsAcquired" xlink:label="loc_us-gaap_BusinessAcquisitionPercentageOfVotingInterestsAcquired_696C3EA94E76EA58D454DCEB435924A6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_EB5A4D848D36D5DCD6F7DCEB435833DC" xlink:to="loc_us-gaap_BusinessAcquisitionPercentageOfVotingInterestsAcquired_696C3EA94E76EA58D454DCEB435924A6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PaymentsToAcquireBusinessesGross" xlink:label="loc_us-gaap_PaymentsToAcquireBusinessesGross_28BCB7A542BF8EA6F853DCEB435955AC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_EB5A4D848D36D5DCD6F7DCEB435833DC" xlink:to="loc_us-gaap_PaymentsToAcquireBusinessesGross_28BCB7A542BF8EA6F853DCEB435955AC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount" xlink:label="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_CC5B04CD4C0B9327CCA7DCEB43590B28" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_EB5A4D848D36D5DCD6F7DCEB435833DC" xlink:to="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_CC5B04CD4C0B9327CCA7DCEB43590B28" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_F1FA0D675A786DC60F1AC534A35F540D" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5F333B4CBB2ED80B8A3FC534A35CEFB0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F1FA0D675A786DC60F1AC534A35F540D" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5F333B4CBB2ED80B8A3FC534A35CEFB0" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_7C026BA07B90E4DB9EABC534A35D152D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5F333B4CBB2ED80B8A3FC534A35CEFB0" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_7C026BA07B90E4DB9EABC534A35D152D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_7C026BA07B90E4DB9EABC534A35D152D" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_7C026BA07B90E4DB9EABC534A35D152D" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PirateBrandsMember" xlink:label="loc_hsy_PirateBrandsMember_D9C9E37655A3A1A344CAC534A35D1725" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D" xlink:to="loc_hsy_PirateBrandsMember_D9C9E37655A3A1A344CAC534A35D1725" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_820D45DA5893568848D3C534A35E3F87" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_820D45DA5893568848D3C534A35E3F87" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RippleBrandCollectiveLLCMember" xlink:label="loc_hsy_RippleBrandCollectiveLLCMember_CC8ED05265F23B109930C534A35E9346" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_A43627F20F0178A0B1E2C534A35DFF1D" xlink:to="loc_hsy_RippleBrandCollectiveLLCMember_CC8ED05265F23B109930C534A35E9346" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_6D147808B1DC878BD775C534A35E6E44" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5F333B4CBB2ED80B8A3FC534A35CEFB0" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_6D147808B1DC878BD775C534A35E6E44" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_526ED1D40E76404D004BC534A35E64F4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_6D147808B1DC878BD775C534A35E6E44" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_526ED1D40E76404D004BC534A35E64F4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_526ED1D40E76404D004BC534A35E64F4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_6D147808B1DC878BD775C534A35E6E44" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_526ED1D40E76404D004BC534A35E64F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupClassificationAxis" xlink:label="loc_us-gaap_DisposalGroupClassificationAxis_C91D383853A701032712C534A35EE62C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_5F333B4CBB2ED80B8A3FC534A35CEFB0" xlink:to="loc_us-gaap_DisposalGroupClassificationAxis_C91D383853A701032712C534A35EE62C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_7C2F2C1B5F77DBC605DBC534A35F5369_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_C91D383853A701032712C534A35EE62C" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_7C2F2C1B5F77DBC605DBC534A35F5369_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_7C2F2C1B5F77DBC605DBC534A35F5369" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_C91D383853A701032712C534A35EE62C" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_7C2F2C1B5F77DBC605DBC534A35F5369" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock" xlink:label="loc_us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock_FECFB45E404F97387531C534A35F2176" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_F1FA0D675A786DC60F1AC534A35F540D" xlink:to="loc_us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock_FECFB45E404F97387531C534A35F2176" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_0D05AF3EAAB05CD4A61BECCFC1333771" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:to="loc_srt_RangeAxis_0D05AF3EAAB05CD4A61BECCFC1333771" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_9938FD1CFC7FF2B9257EECCFC134B528_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_0D05AF3EAAB05CD4A61BECCFC1333771" xlink:to="loc_srt_RangeMember_9938FD1CFC7FF2B9257EECCFC134B528_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_9938FD1CFC7FF2B9257EECCFC134B528" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_0D05AF3EAAB05CD4A61BECCFC1333771" xlink:to="loc_srt_RangeMember_9938FD1CFC7FF2B9257EECCFC134B528" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_CB52F2017970A6A49594ECCFC13581EA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_9938FD1CFC7FF2B9257EECCFC134B528" xlink:to="loc_srt_MinimumMember_CB52F2017970A6A49594ECCFC13581EA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_1A46C72140AA9C0F7419ECCFC135A8BC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_9938FD1CFC7FF2B9257EECCFC134B528" xlink:to="loc_srt_MaximumMember_1A46C72140AA9C0F7419ECCFC135A8BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_BFC17DEBBAEC97A35436ECCFC1354F91" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_BFC17DEBBAEC97A35436ECCFC1354F91" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_399ACAD99855842EF894ECCFC1357558_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_BFC17DEBBAEC97A35436ECCFC1354F91" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_399ACAD99855842EF894ECCFC1357558_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_399ACAD99855842EF894ECCFC1357558" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_BFC17DEBBAEC97A35436ECCFC1354F91" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_399ACAD99855842EF894ECCFC1357558" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringChargesMember" xlink:label="loc_us-gaap_RestructuringChargesMember_4126184D1A27C89A8378ECCFC1366DA6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_399ACAD99855842EF894ECCFC1357558" xlink:to="loc_us-gaap_RestructuringChargesMember_4126184D1A27C89A8378ECCFC1366DA6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_6FCD3CFF92438801FB79ECCFC1360C21" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_6FCD3CFF92438801FB79ECCFC1360C21" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_6349194CE5F92D3B5DBDECCFC136E523_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_6FCD3CFF92438801FB79ECCFC1360C21" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_6349194CE5F92D3B5DBDECCFC136E523_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_6349194CE5F92D3B5DBDECCFC136E523" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_6FCD3CFF92438801FB79ECCFC1360C21" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_6349194CE5F92D3B5DBDECCFC136E523" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GeographicConcentrationRiskMember" xlink:label="loc_us-gaap_GeographicConcentrationRiskMember_510206145B137803766AECCFC1362AF3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_6349194CE5F92D3B5DBDECCFC136E523" xlink:to="loc_us-gaap_GeographicConcentrationRiskMember_510206145B137803766AECCFC1362AF3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_694EEEA391D4BED664ACECCFC137227F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_694EEEA391D4BED664ACECCFC137227F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_EECDC14CA58DE60EACFFECCFC1372E20_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_694EEEA391D4BED664ACECCFC137227F" xlink:to="loc_us-gaap_SegmentDomain_EECDC14CA58DE60EACFFECCFC1372E20_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_EECDC14CA58DE60EACFFECCFC1372E20" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_694EEEA391D4BED664ACECCFC137227F" xlink:to="loc_us-gaap_SegmentDomain_EECDC14CA58DE60EACFFECCFC1372E20" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_NorthAmericaMember" xlink:label="loc_srt_NorthAmericaMember_8BFEBDB0E189755A95E1ECCFC1371800" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_EECDC14CA58DE60EACFFECCFC1372E20" xlink:to="loc_srt_NorthAmericaMember_8BFEBDB0E189755A95E1ECCFC1371800" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_235AC25CB31E9C6A26E9ECCFC137EB9B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_EECDC14CA58DE60EACFFECCFC1372E20" xlink:to="loc_hsy_InternationalandOtherSegmentMember_235AC25CB31E9C6A26E9ECCFC137EB9B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_247C525C6E1D34F3997DECCFC1378C8C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:to="loc_us-gaap_RestructuringPlanAxis_247C525C6E1D34F3997DECCFC1378C8C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_247C525C6E1D34F3997DECCFC1378C8C" xlink:to="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_247C525C6E1D34F3997DECCFC1378C8C" xlink:to="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_NorthAmericaMember" xlink:label="loc_srt_NorthAmericaMember_EA84180F0E141D76D233ECCFC138FC81" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C" xlink:to="loc_srt_NorthAmericaMember_EA84180F0E141D76D233ECCFC138FC81" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_7118D58CB20B798CB1B8ECCFC1382070" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C" xlink:to="loc_hsy_MarginforGrowthProgramMember_7118D58CB20B798CB1B8ECCFC1382070" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_7773DB0033AD630342ADECCFC138DD7B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C" xlink:to="loc_hsy_OperationalOptimizationProgramMember_7773DB0033AD630342ADECCFC138DD7B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ProductivityInitiative2015Member" xlink:label="loc_hsy_ProductivityInitiative2015Member_7857F95028CD2C714A5BECCFC139A481" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_8F6F3CF456A80256D534ECCFC138924C" xlink:to="loc_hsy_ProductivityInitiative2015Member_7857F95028CD2C714A5BECCFC139A481" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_108D05CA451A8E34CEF1ECCFC1394E9A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_B83C1C2BD73A3E580D1EECCFC133FEF6" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_108D05CA451A8E34CEF1ECCFC1394E9A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_108D05CA451A8E34CEF1ECCFC1394E9A" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_108D05CA451A8E34CEF1ECCFC1394E9A" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeSeveranceMember" xlink:label="loc_us-gaap_EmployeeSeveranceMember_A507BEB837F3312CD492ECCFC1391183" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620" xlink:to="loc_us-gaap_EmployeeSeveranceMember_A507BEB837F3312CD492ECCFC1391183" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherRestructuringMember" xlink:label="loc_us-gaap_OtherRestructuringMember_D2863DABCB58DD6E2A2CECCFC13A96CC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620" xlink:to="loc_us-gaap_OtherRestructuringMember_D2863DABCB58DD6E2A2CECCFC13A96CC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_D78032F8A30E730B2132ECCFC13AA43E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_0C6C7A4E0C4FC3A57EF9ECCFC139D620" xlink:to="loc_us-gaap_FacilityClosingMember_D78032F8A30E730B2132ECCFC13AA43E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_DD0BE7CBA2F933E27941ECCFC13A302E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_DD0BE7CBA2F933E27941ECCFC13A302E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringAndRelatedCostExpectedCost1" xlink:label="loc_us-gaap_RestructuringAndRelatedCostExpectedCost1_52A90310EEB3C7E923F4ECCFC13A8328" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_RestructuringAndRelatedCostExpectedCost1_52A90310EEB3C7E923F4ECCFC13A8328" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringAndRelatedCostCostIncurredToDate1" xlink:label="loc_us-gaap_RestructuringAndRelatedCostCostIncurredToDate1_B2DE206834459A6610D3ECCFC13AED0C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_RestructuringAndRelatedCostCostIncurredToDate1_B2DE206834459A6610D3ECCFC13AED0C" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RestructuringandRelatedCostExpectedCostCashPortion" xlink:label="loc_hsy_RestructuringandRelatedCostExpectedCostCashPortion_7FB5D95843CE924F20C6ECD1A26BF61E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_hsy_RestructuringandRelatedCostExpectedCostCashPortion_7FB5D95843CE924F20C6ECD1A26BF61E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_5507A8574EFCFBE0CCD2ECCFC13B4FED" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_AssetImpairmentCharges_5507A8574EFCFBE0CCD2ECCFC13B4FED" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent" xlink:label="loc_hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent_C74E437D2A9A444DABE4ECCFC13B6A43" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent_C74E437D2A9A444DABE4ECCFC13B6A43" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_133F8A5A4A285485D883ECCFC13B9765" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_RestructuringCharges_133F8A5A4A285485D883ECCFC13B9765" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_5F27D1502F061D37D3A7ECCFC13BBAD9" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_5F27D1502F061D37D3A7ECCFC13BBAD9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsHeldForUse" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_87A1C0B943C5EE181CEFECCFC13B8F46" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_87A1C0B943C5EE181CEFECCFC13B8F46" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringAndRelatedCostExpectedNumberOfPositionsEliminated" xlink:label="loc_us-gaap_RestructuringAndRelatedCostExpectedNumberOfPositionsEliminated_B5B168C4C7F9E8E91818ECCFC13BA017" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_A3C3A41F9083E6C14B3BECCFC13A3A06" xlink:to="loc_us-gaap_RestructuringAndRelatedCostExpectedNumberOfPositionsEliminated_B5B168C4C7F9E8E91818ECCFC13BA017" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_1A5119766E2D646006DCE8D3D83FCD41" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_7A109FCED36E9E820F3FE8D3D83B0BD8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_1A5119766E2D646006DCE8D3D83FCD41" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_7A109FCED36E9E820F3FE8D3D83B0BD8" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_03233B72EFC9767C06CAE8D3D83B2C2B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_7A109FCED36E9E820F3FE8D3D83B0BD8" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_03233B72EFC9767C06CAE8D3D83B2C2B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_03233B72EFC9767C06CAE8D3D83B2C2B" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_03233B72EFC9767C06CAE8D3D83B2C2B" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CostOfSalesMember" xlink:label="loc_us-gaap_CostOfSalesMember_2B8A1CA807421156EEADE8D3D83C361E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C" xlink:to="loc_us-gaap_CostOfSalesMember_2B8A1CA807421156EEADE8D3D83C361E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_896EA25D99584D3F18DEE8D3D83CFD0C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_896EA25D99584D3F18DEE8D3D83CFD0C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringChargesMember" xlink:label="loc_us-gaap_RestructuringChargesMember_8BF0389ECAF9B2FB0E05E8D3D83C24D8" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_29E561515D48AE85642BE8D3D83B887C" xlink:to="loc_us-gaap_RestructuringChargesMember_8BF0389ECAF9B2FB0E05E8D3D83C24D8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_68DDF14D16F47F4ABDADE8D3D83C5E06" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_7A109FCED36E9E820F3FE8D3D83B0BD8" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_68DDF14D16F47F4ABDADE8D3D83C5E06" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_68DDF14D16F47F4ABDADE8D3D83C5E06" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_68DDF14D16F47F4ABDADE8D3D83C5E06" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeSeveranceMember" xlink:label="loc_us-gaap_EmployeeSeveranceMember_F66085C7155431922FF4E8D3D83D950F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2" xlink:to="loc_us-gaap_EmployeeSeveranceMember_F66085C7155431922FF4E8D3D83D950F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_AcceleratedDepreciationandAmortizationMember" xlink:label="loc_hsy_AcceleratedDepreciationandAmortizationMember_8E9E0F039627E20B9C8CE8D3D83D4E51" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2" xlink:to="loc_hsy_AcceleratedDepreciationandAmortizationMember_8E9E0F039627E20B9C8CE8D3D83D4E51" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherRestructuringMember" xlink:label="loc_us-gaap_OtherRestructuringMember_9F62730E0EAA5CC34A3FE8D3D83D49C5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2" xlink:to="loc_us-gaap_OtherRestructuringMember_9F62730E0EAA5CC34A3FE8D3D83D49C5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_D93C016734765FE5607DE8D3D83DB008" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_E7FE9077CF60C92A928CE8D3D83C9CA2" xlink:to="loc_us-gaap_FacilityClosingMember_D93C016734765FE5607DE8D3D83DB008" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_2AC4FCF7F5B2ADB52F08E8D3D83E1D29" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_7A109FCED36E9E820F3FE8D3D83B0BD8" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_2AC4FCF7F5B2ADB52F08E8D3D83E1D29" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_8DFB42123809904696B5E8D3D83EDBC2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_2AC4FCF7F5B2ADB52F08E8D3D83E1D29" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_8DFB42123809904696B5E8D3D83EDBC2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_8DFB42123809904696B5E8D3D83EDBC2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_2AC4FCF7F5B2ADB52F08E8D3D83E1D29" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_8DFB42123809904696B5E8D3D83EDBC2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_18ADF110A5F280980DD2E8D3D83E4A0A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_7A109FCED36E9E820F3FE8D3D83B0BD8" xlink:to="loc_us-gaap_RestructuringPlanAxis_18ADF110A5F280980DD2E8D3D83E4A0A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_18ADF110A5F280980DD2E8D3D83E4A0A" xlink:to="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_18ADF110A5F280980DD2E8D3D83E4A0A" xlink:to="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_DEB093E772F4AC6BD04CE8D3D83FAD18" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179" xlink:to="loc_hsy_MarginforGrowthProgramMember_DEB093E772F4AC6BD04CE8D3D83FAD18" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_OperationalOptimizationProgramMember" xlink:label="loc_hsy_OperationalOptimizationProgramMember_C10C5DD1A378A1D0CFC0E8D3D83F89F8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179" xlink:to="loc_hsy_OperationalOptimizationProgramMember_C10C5DD1A378A1D0CFC0E8D3D83F89F8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ProductivityInitiative2015Member" xlink:label="loc_hsy_ProductivityInitiative2015Member_EA9D9851948ADFE25573E8D3D83FD6CE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_50D48D59C265227E8FB7E8D3D83F8179" xlink:to="loc_hsy_ProductivityInitiative2015Member_EA9D9851948ADFE25573E8D3D83FD6CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_5205152A87B5FA4B4C23E8D3D840506A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_1A5119766E2D646006DCE8D3D83FCD41" xlink:to="loc_us-gaap_RestructuringCharges_5205152A87B5FA4B4C23E8D3D840506A" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_B7D2F8CA9F171CB6DA9BC534A189587E" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_EBB1E502FD797EFF8772C534A18805B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_B7D2F8CA9F171CB6DA9BC534A189587E" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_EBB1E502FD797EFF8772C534A18805B6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_5E7736BE4C73E188DE62C534A1881091" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_EBB1E502FD797EFF8772C534A18805B6" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_5E7736BE4C73E188DE62C534A1881091" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_DE6F64D5627F45DEC000C534A188407B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_5E7736BE4C73E188DE62C534A1881091" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_DE6F64D5627F45DEC000C534A188407B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_DE6F64D5627F45DEC000C534A188407B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_5E7736BE4C73E188DE62C534A1881091" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_DE6F64D5627F45DEC000C534A188407B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringReserveRollForward" xlink:label="loc_us-gaap_RestructuringReserveRollForward_FDE8B7229A3F855F2282C534A189807F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_B7D2F8CA9F171CB6DA9BC534A189587E" xlink:to="loc_us-gaap_RestructuringReserveRollForward_FDE8B7229A3F855F2282C534A189807F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringReserve" xlink:label="loc_us-gaap_RestructuringReserve_62E930FBD6FB510CE587C534A189D83E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FDE8B7229A3F855F2282C534A189807F" xlink:to="loc_us-gaap_RestructuringReserve_62E930FBD6FB510CE587C534A189D83E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RestructuringChargesBusinessRealignmentReserve" xlink:label="loc_hsy_RestructuringChargesBusinessRealignmentReserve_F16FF77E78EB6CFFB2DDC534A189236B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FDE8B7229A3F855F2282C534A189807F" xlink:to="loc_hsy_RestructuringChargesBusinessRealignmentReserve_F16FF77E78EB6CFFB2DDC534A189236B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PaymentsForRestructuring" xlink:label="loc_us-gaap_PaymentsForRestructuring_841846386647788C735DC534A189B0FC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FDE8B7229A3F855F2282C534A189807F" xlink:to="loc_us-gaap_PaymentsForRestructuring_841846386647788C735DC534A189B0FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringReserveAccrualAdjustment1" xlink:label="loc_us-gaap_RestructuringReserveAccrualAdjustment1_2902ED630DB2FE3943C0C534A18A6920" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_FDE8B7229A3F855F2282C534A189807F" xlink:to="loc_us-gaap_RestructuringReserveAccrualAdjustment1_2902ED630DB2FE3943C0C534A18A6920" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskLineItems" xlink:label="loc_us-gaap_ConcentrationRiskLineItems_522E8AFF649207AF4919C534A01FD768" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTable" xlink:label="loc_us-gaap_ConcentrationRiskTable_E375BF200B03340790FFC534A01DE3E3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_522E8AFF649207AF4919C534A01FD768" xlink:to="loc_us-gaap_ConcentrationRiskTable_E375BF200B03340790FFC534A01DE3E3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_2441FF9A77720CC332F2C534A01DD28B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ConcentrationRiskTable_E375BF200B03340790FFC534A01DE3E3" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_2441FF9A77720CC332F2C534A01DD28B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_8BBD23CC257E65FA94E1C534A01E0003_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_2441FF9A77720CC332F2C534A01DD28B" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_8BBD23CC257E65FA94E1C534A01E0003_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_8BBD23CC257E65FA94E1C534A01E0003" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_2441FF9A77720CC332F2C534A01DD28B" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_8BBD23CC257E65FA94E1C534A01E0003" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember" xlink:label="loc_us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember_C532E125F2EC2BD539C5C534A01E7C66" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_8BBD23CC257E65FA94E1C534A01E0003" xlink:to="loc_us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember_C532E125F2EC2BD539C5C534A01E7C66" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_D2CC8CBE41FC91CD0B2EC534A01ECEBB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ConcentrationRiskTable_E375BF200B03340790FFC534A01DE3E3" xlink:to="loc_us-gaap_StatementScenarioAxis_D2CC8CBE41FC91CD0B2EC534A01ECEBB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_D2F9D0AA5AFB0FBD932FC534A01E53DB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_D2CC8CBE41FC91CD0B2EC534A01ECEBB" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_D2F9D0AA5AFB0FBD932FC534A01E53DB_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_D2F9D0AA5AFB0FBD932FC534A01E53DB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_D2CC8CBE41FC91CD0B2EC534A01ECEBB" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_D2F9D0AA5AFB0FBD932FC534A01E53DB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_6D1636A4815B12BC3F62C534A01F2E95" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_D2F9D0AA5AFB0FBD932FC534A01E53DB" xlink:to="loc_us-gaap_ScenarioForecastMember_6D1636A4815B12BC3F62C534A01F2E95" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityNumberOfEmployees" xlink:label="loc_dei_EntityNumberOfEmployees_0CEDF60C6213B2AC124DC534A01FB3BE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_522E8AFF649207AF4919C534A01FD768" xlink:to="loc_dei_EntityNumberOfEmployees_0CEDF60C6213B2AC124DC534A01FB3BE" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_EntityNumberofPartTimeEmployees" xlink:label="loc_hsy_EntityNumberofPartTimeEmployees_B9DF910D3A52638935BFC534A0204081" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_522E8AFF649207AF4919C534A01FD768" xlink:to="loc_hsy_EntityNumberofPartTimeEmployees_B9DF910D3A52638935BFC534A0204081" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_C942B82C4DBF02B53916C534A020F85A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_522E8AFF649207AF4919C534A01FD768" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_C942B82C4DBF02B53916C534A020F85A" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_C1770DFF75DCDC9DCAEDC534A02C0E23" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationTable" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_3C29FE9011FF530BF068C534A02BCC7B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_C1770DFF75DCDC9DCAEDC534A02C0E23" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_3C29FE9011FF530BF068C534A02BCC7B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_B882F87726CA844EBCE0C534A02B6B50" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_3C29FE9011FF530BF068C534A02BCC7B" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_B882F87726CA844EBCE0C534A02B6B50" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain" xlink:label="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_979F42DDBB3FD7B827E5C534A02B14E8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_B882F87726CA844EBCE0C534A02B6B50" xlink:to="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_979F42DDBB3FD7B827E5C534A02B14E8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain" xlink:label="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_979F42DDBB3FD7B827E5C534A02B14E8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_B882F87726CA844EBCE0C534A02B6B50" xlink:to="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_979F42DDBB3FD7B827E5C534A02B14E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InventoriesMember" xlink:label="loc_us-gaap_InventoriesMember_2DB0CF0C98DB07957C36C534A02B0DAB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_979F42DDBB3FD7B827E5C534A02B14E8" xlink:to="loc_us-gaap_InventoriesMember_2DB0CF0C98DB07957C36C534A02B0DAB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_C1770DFF75DCDC9DCAEDC534A02C0E23" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary_F6F4D8E292958F1B610AC534A02C82FA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary_F6F4D8E292958F1B610AC534A02C82FA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary_FB44CBBA099665546B09C534A02CC71A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary_FB44CBBA099665546B09C534A02CC71A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary_F08D53551E4A28905C9AC534A02D0556" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary_F08D53551E4A28905C9AC534A02D0556" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary_54EEE760F78EB40C2CF8C534A02D52B9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary_54EEE760F78EB40C2CF8C534A02D52B9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary_E2FC45744C8A9BB5F648C534A02DD58E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_23BC97FDA189E0BF1245C534A02C8012" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary_E2FC45744C8A9BB5F648C534A02DD58E" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_F983D95B67637FB74F3BC534A3FF81C8" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_68417658C36E04BEA979C534A3FEABB3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_F983D95B67637FB74F3BC534A3FF81C8" xlink:to="loc_us-gaap_StatementTable_68417658C36E04BEA979C534A3FEABB3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_1239EA643BA3416412D0C534A3FE2DD7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_68417658C36E04BEA979C534A3FEABB3" xlink:to="loc_us-gaap_StatementClassOfStockAxis_1239EA643BA3416412D0C534A3FE2DD7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_ADBA72ED2E32592E1454C534A3FEE4BD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_1239EA643BA3416412D0C534A3FE2DD7" xlink:to="loc_us-gaap_ClassOfStockDomain_ADBA72ED2E32592E1454C534A3FEE4BD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_ADBA72ED2E32592E1454C534A3FEE4BD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_1239EA643BA3416412D0C534A3FE2DD7" xlink:to="loc_us-gaap_ClassOfStockDomain_ADBA72ED2E32592E1454C534A3FEE4BD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_49071078FAF222F037B9C534A3FFFBCC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_ADBA72ED2E32592E1454C534A3FEE4BD" xlink:to="loc_hsy_HersheyCommonStockMember_49071078FAF222F037B9C534A3FFFBCC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_777574603703459DA3B7C534A3FF7FC5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_ADBA72ED2E32592E1454C534A3FEE4BD" xlink:to="loc_us-gaap_CommonClassBMember_777574603703459DA3B7C534A3FF7FC5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetsAbstract" xlink:label="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F983D95B67637FB74F3BC534A3FF81C8" xlink:to="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetsCurrentAbstract" xlink:label="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_ADD51A8AE0C77EF59756C534A400D76C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_ADD51A8AE0C77EF59756C534A400D76C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccountsReceivableNetCurrent" xlink:label="loc_us-gaap_AccountsReceivableNetCurrent_21B7C8C6B71AE2F96480C534A4000282" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_21B7C8C6B71AE2F96480C534A4000282" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InventoryNet" xlink:label="loc_us-gaap_InventoryNet_BAF4B7C82F21FC6680B0C534A400226E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:to="loc_us-gaap_InventoryNet_BAF4B7C82F21FC6680B0C534A400226E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PrepaidExpenseAndOtherAssetsCurrent" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_6C09788967E2B412172DC534A400051D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_6C09788967E2B412172DC534A400051D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetsCurrent" xlink:label="loc_us-gaap_AssetsCurrent_DEF336EF90B64A5CCC25C534A4007D05" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_F8834158ABB81DD31ADCC534A4007B3B" xlink:to="loc_us-gaap_AssetsCurrent_DEF336EF90B64A5CCC25C534A4007D05" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_597EDC3ADE542D9EDAAAC534A406C5C2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_597EDC3ADE542D9EDAAAC534A406C5C2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_969AC6C4A45982C247A0C534A4060CBF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_Goodwill_969AC6C4A45982C247A0C534A4060CBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_D56739F7DECA2D920626C534A40680E2" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_D56739F7DECA2D920626C534A40680E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherAssetsNoncurrent" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_45A8F4FBA8126988759EC534A407245B" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_45A8F4FBA8126988759EC534A407245B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DeferredTaxAssetsLiabilitiesNetNoncurrent" xlink:label="loc_us-gaap_DeferredTaxAssetsLiabilitiesNetNoncurrent_60139B68460C51A7E908C534A4076D50" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_DeferredTaxAssetsLiabilitiesNetNoncurrent_60139B68460C51A7E908C534A4076D50" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Assets" xlink:label="loc_us-gaap_Assets_6AA8503F6AD414D08387C534A4073EBA" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_1700AAF292371FF4C3EDC534A3FFC318" xlink:to="loc_us-gaap_Assets_6AA8503F6AD414D08387C534A4073EBA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LiabilitiesAndStockholdersEquityAbstract" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F983D95B67637FB74F3BC534A3FF81C8" xlink:to="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LiabilitiesCurrentAbstract" xlink:label="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccountsPayableCurrent" xlink:label="loc_us-gaap_AccountsPayableCurrent_F4D912996452552A2AE8C534A4085679" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:to="loc_us-gaap_AccountsPayableCurrent_F4D912996452552A2AE8C534A4085679" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccruedLiabilitiesCurrent" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_557253CCC0A6D4D74951C534A40827F4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:to="loc_us-gaap_AccruedLiabilitiesCurrent_557253CCC0A6D4D74951C534A40827F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccruedIncomeTaxesCurrent" xlink:label="loc_us-gaap_AccruedIncomeTaxesCurrent_47FD78E5CD05C728F55BC534A4086D6C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:to="loc_us-gaap_AccruedIncomeTaxesCurrent_47FD78E5CD05C728F55BC534A4086D6C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShortTermBorrowings" xlink:label="loc_us-gaap_ShortTermBorrowings_72E566EE3BFD19907976C534A4085CB0" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:to="loc_us-gaap_ShortTermBorrowings_72E566EE3BFD19907976C534A4085CB0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_F9C40DE86596692B15E0C534A4086DD4" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:to="loc_us-gaap_LongTermDebtCurrent_F9C40DE86596692B15E0C534A4086DD4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LiabilitiesCurrent" xlink:label="loc_us-gaap_LiabilitiesCurrent_E135CA65B0C97B7167BFC534A40884F4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_BA3AC9FC8EC293A5B92CC534A4079165" xlink:to="loc_us-gaap_LiabilitiesCurrent_E135CA65B0C97B7167BFC534A40884F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtAndCapitalLeaseObligations" xlink:label="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_9DBEDC46F44CA7D76BFCC534A4093938" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_9DBEDC46F44CA7D76BFCC534A4093938" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherLiabilitiesNoncurrent" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_7476830470B6F70ACE75C534A409CE18" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_7476830470B6F70ACE75C534A409CE18" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DeferredTaxLiabilitiesNoncurrent" xlink:label="loc_us-gaap_DeferredTaxLiabilitiesNoncurrent_93909F70E91E452F1AD6C534A4095DD1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_DeferredTaxLiabilitiesNoncurrent_93909F70E91E452F1AD6C534A4095DD1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Liabilities" xlink:label="loc_us-gaap_Liabilities_D4903F5E02B3EA691CDFC534A4094C27" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_Liabilities_D4903F5E02B3EA691CDFC534A4094C27" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PreferredStockValue" xlink:label="loc_us-gaap_PreferredStockValue_22821410D1389FFC1877C534A40AD343" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_PreferredStockValue_22821410D1389FFC1877C534A40AD343" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockValue" xlink:label="loc_us-gaap_CommonStockValue_C33F02E5954577085228C534A40A1DCC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_CommonStockValue_C33F02E5954577085228C534A40A1DCC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AdditionalPaidInCapital" xlink:label="loc_us-gaap_AdditionalPaidInCapital_EB6AD920F1926F22E17BC534A40AB4D4" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_AdditionalPaidInCapital_EB6AD920F1926F22E17BC534A40AB4D4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetainedEarningsAccumulatedDeficit" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_8BB1AFEFFC9C127F8BF4C534A40A7613" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_8BB1AFEFFC9C127F8BF4C534A40A7613" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockValue" xlink:label="loc_us-gaap_TreasuryStockValue_AA9FCF5AF5282A7EA9F6C534A40A3152" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_TreasuryStockValue_AA9FCF5AF5282A7EA9F6C534A40A3152" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_FED50599E3460AE2098AC534A40B39BA" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_FED50599E3460AE2098AC534A40B39BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockholdersEquity" xlink:label="loc_us-gaap_StockholdersEquity_DE455261D13E822BC2E0C534A40B2808" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_StockholdersEquity_DE455261D13E822BC2E0C534A40B2808" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MinorityInterest" xlink:label="loc_us-gaap_MinorityInterest_2C63EF43CB9AE5707F92C534A40B69DD" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_MinorityInterest_2C63EF43CB9AE5707F92C534A40B69DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_8C1DA971E151C8C862CDC534A40BE475" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_B940C52830C3D164BD96C534A409322A" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_8C1DA971E151C8C862CDC534A40BE475" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LiabilitiesAndStockholdersEquity" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_0AF613B8C46299B5EA48C534A40BFB5A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_DD343C2BECB6ED451A61C534A4078C5E" xlink:to="loc_us-gaap_LiabilitiesAndStockholdersEquity_0AF613B8C46299B5EA48C534A40BFB5A" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_2F7D3212D3C386911E8AC534A3DC769E" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_190A85DBCCF677150A5BC534A3DBDB9E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_2F7D3212D3C386911E8AC534A3DC769E" xlink:to="loc_us-gaap_StatementTable_190A85DBCCF677150A5BC534A3DBDB9E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_5B239649DBD871580039C534A3DBE59E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_190A85DBCCF677150A5BC534A3DBDB9E" xlink:to="loc_us-gaap_StatementClassOfStockAxis_5B239649DBD871580039C534A3DBE59E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_A910033D39B26F85C181C534A3DCED14_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_5B239649DBD871580039C534A3DBE59E" xlink:to="loc_us-gaap_ClassOfStockDomain_A910033D39B26F85C181C534A3DCED14_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_A910033D39B26F85C181C534A3DCED14" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_5B239649DBD871580039C534A3DBE59E" xlink:to="loc_us-gaap_ClassOfStockDomain_A910033D39B26F85C181C534A3DCED14" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_58B27B41D3FC4D2C184CC534A3DC9FE5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_A910033D39B26F85C181C534A3DCED14" xlink:to="loc_hsy_HersheyCommonStockMember_58B27B41D3FC4D2C184CC534A3DC9FE5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_273CF03D549E9BC7D7DAC534A3DCD3AD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_A910033D39B26F85C181C534A3DCED14" xlink:to="loc_us-gaap_CommonClassBMember_273CF03D549E9BC7D7DAC534A3DCD3AD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PreferredStockSharesIssued" xlink:label="loc_us-gaap_PreferredStockSharesIssued_CCFB2B127D71D30A2940C534A3DD3571" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_2F7D3212D3C386911E8AC534A3DC769E" xlink:to="loc_us-gaap_PreferredStockSharesIssued_CCFB2B127D71D30A2940C534A3DD3571" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockSharesIssued" xlink:label="loc_us-gaap_CommonStockSharesIssued_5640441E4799110D05CFC534A3DDB882" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_2F7D3212D3C386911E8AC534A3DC769E" xlink:to="loc_us-gaap_CommonStockSharesIssued_5640441E4799110D05CFC534A3DDB882" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockShares" xlink:label="loc_us-gaap_TreasuryStockShares_7BFDC112D25DE007DA24C534A3DD207C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_2F7D3212D3C386911E8AC534A3DC769E" xlink:to="loc_us-gaap_TreasuryStockShares_7BFDC112D25DE007DA24C534A3DD207C" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_F1DAA695AF6AE533C731C534A459E76D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_StatementTable_F1DAA695AF6AE533C731C534A459E76D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_ADDA94F7B586C8B03300C534A4593410" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_F1DAA695AF6AE533C731C534A459E76D" xlink:to="loc_us-gaap_StatementClassOfStockAxis_ADDA94F7B586C8B03300C534A4593410" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_28C4A8CC63BBD4246945C534A45A8DA9_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_ADDA94F7B586C8B03300C534A4593410" xlink:to="loc_us-gaap_ClassOfStockDomain_28C4A8CC63BBD4246945C534A45A8DA9_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_28C4A8CC63BBD4246945C534A45A8DA9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_ADDA94F7B586C8B03300C534A4593410" xlink:to="loc_us-gaap_ClassOfStockDomain_28C4A8CC63BBD4246945C534A45A8DA9" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_F231F69C0DBE1011D72AC534A45A20DC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_28C4A8CC63BBD4246945C534A45A8DA9" xlink:to="loc_hsy_HersheyCommonStockMember_F231F69C0DBE1011D72AC534A45A20DC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_6299836AC268E69EE1C9C534A46099A0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_28C4A8CC63BBD4246945C534A45A8DA9" xlink:to="loc_us-gaap_CommonClassBMember_6299836AC268E69EE1C9C534A46099A0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_36FFE621C126FC8BB76FC534A46060E6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_Revenues_36FFE621C126FC8BB76FC534A46060E6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CostOfGoodsAndServicesSold" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_4EE4713D599395D9095CC534A4616F76" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_4EE4713D599395D9095CC534A4616F76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GrossProfit" xlink:label="loc_us-gaap_GrossProfit_A194F4697CF89199988CC534A461F112" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_GrossProfit_A194F4697CF89199988CC534A461F112" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpense" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_D654A252560AE8225AD4C534A4613B8F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_D654A252560AE8225AD4C534A4613B8F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_28C6C473073B3BB5D204C534A4617019" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_AssetImpairmentCharges_28C6C473073B3BB5D204C534A4617019" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RestructuringChargesBusinessRealignment" xlink:label="loc_hsy_RestructuringChargesBusinessRealignment_1CBEA8F7A994FD063BCFC534A461CF27" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_hsy_RestructuringChargesBusinessRealignment_1CBEA8F7A994FD063BCFC534A461CF27" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_07D448611FFC3EA6C70AC534A462CC88" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_OperatingIncomeLoss_07D448611FFC3EA6C70AC534A462CC88" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_C35444E04D58DD94E7D0C534A4625410" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_C35444E04D58DD94E7D0C534A4625410" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_03167B76A51E98BA7387C534A4626C84" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_03167B76A51E98BA7387C534A4626C84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_93BB5F8D891AE43F28C3C534A46292B0" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_93BB5F8D891AE43F28C3C534A46292B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeTaxExpenseBenefit" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_4CAC49CE783297721013C534A462B712" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_4CAC49CE783297721013C534A462B712" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ProfitLoss" xlink:label="loc_us-gaap_ProfitLoss_321A619227B825A349ABC534A4639834" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_ProfitLoss_321A619227B825A349ABC534A4639834" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_C1F8E1B99335534BE17DC534A4632566" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_C1F8E1B99335534BE17DC534A4632566" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_7F92C7CF08379AD6061DC534A463B00E" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_NetIncomeLoss_7F92C7CF08379AD6061DC534A463B00E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareBasicAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicAbstract_B63157DA34E4675309F3C534A4639742" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_EarningsPerShareBasicAbstract_B63157DA34E4675309F3C534A4639742" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_A77A61E5AA5CF7FF9603C534A46376DE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicAbstract_B63157DA34E4675309F3C534A4639742" xlink:to="loc_us-gaap_EarningsPerShareBasic_A77A61E5AA5CF7FF9603C534A46376DE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareDilutedAbstract" xlink:label="loc_us-gaap_EarningsPerShareDilutedAbstract_79A72D604618801BF3F9C534A46386B8" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_EarningsPerShareDilutedAbstract_79A72D604618801BF3F9C534A46386B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_C8B20EF565D59658611BC534A46446DF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedAbstract_79A72D604618801BF3F9C534A46386B8" xlink:to="loc_us-gaap_EarningsPerShareDiluted_C8B20EF565D59658611BC534A46446DF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DividendsCommonStockAbstract" xlink:label="loc_us-gaap_DividendsCommonStockAbstract_19BFE110F6C027F358E7C534A464B2BF" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4293F58B85C73A7AC2CC534A460B259" xlink:to="loc_us-gaap_DividendsCommonStockAbstract_19BFE110F6C027F358E7C534A464B2BF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_F5DD1207FBF14E065D3DC534A46486FD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DividendsCommonStockAbstract_19BFE110F6C027F358E7C534A464B2BF" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_F5DD1207FBF14E065D3DC534A46486FD" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_4EA97DE614D93E0BF382E8A59B29639E" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_F48D3C6F8E7B971D99C2E8A59B2207AD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_4EA97DE614D93E0BF382E8A59B29639E" xlink:to="loc_us-gaap_StatementTable_F48D3C6F8E7B971D99C2E8A59B2207AD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_4524035004173D113E30E8A59B23FB83" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_F48D3C6F8E7B971D99C2E8A59B2207AD" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_4524035004173D113E30E8A59B23FB83" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_EE544F4484CDBE5D9AD7E8A59B23E71D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_4524035004173D113E30E8A59B23FB83" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_EE544F4484CDBE5D9AD7E8A59B23E71D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_EE544F4484CDBE5D9AD7E8A59B23E71D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_4524035004173D113E30E8A59B23FB83" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_EE544F4484CDBE5D9AD7E8A59B23E71D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_3E9BD170ADD87E10622CE8A59B2402C4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_EE544F4484CDBE5D9AD7E8A59B23E71D" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_3E9BD170ADD87E10622CE8A59B2402C4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_77A9B89AF90BF2E814EBE8A59B24D49C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_F48D3C6F8E7B971D99C2E8A59B2207AD" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_77A9B89AF90BF2E814EBE8A59B24D49C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_77A9B89AF90BF2E814EBE8A59B24D49C" xlink:to="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_77A9B89AF90BF2E814EBE8A59B24D49C" xlink:to="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PreferredStockMember" xlink:label="loc_us-gaap_PreferredStockMember_B2FEC75CDDAAC5BBD933E8A59B2547B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_PreferredStockMember_B2FEC75CDDAAC5BBD933E8A59B2547B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_B828F2B98378DC92D651E8A59B27231A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_CommonStockMember_B828F2B98378DC92D651E8A59B27231A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AdditionalPaidInCapitalMember" xlink:label="loc_us-gaap_AdditionalPaidInCapitalMember_B6C811BF37F0F5FD73E0E8A59B273831" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_AdditionalPaidInCapitalMember_B6C811BF37F0F5FD73E0E8A59B273831" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_1ACED5AD56CF364D00B5E8A59B27DF6A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_RetainedEarningsMember_1ACED5AD56CF364D00B5E8A59B27DF6A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockMember" xlink:label="loc_us-gaap_TreasuryStockMember_2898768353C0D0936657E8A59B288D35" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_TreasuryStockMember_2898768353C0D0936657E8A59B288D35" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeMember" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_F212A2E355D01C32E066E8A59B283E50" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_F212A2E355D01C32E066E8A59B283E50" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_2B841E2B5F6D0955C7DCE8A59B282AFF" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D2E5C3EB771C19C69045E8A59B24CA65" xlink:to="loc_us-gaap_NoncontrollingInterestMember_2B841E2B5F6D0955C7DCE8A59B282AFF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_6822FE6DA53E584DE766E8A59B286F60" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_F48D3C6F8E7B971D99C2E8A59B2207AD" xlink:to="loc_us-gaap_StatementClassOfStockAxis_6822FE6DA53E584DE766E8A59B286F60" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_9A8D06FAAD3A71C8A6CFE8A59B2835AB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_6822FE6DA53E584DE766E8A59B286F60" xlink:to="loc_us-gaap_ClassOfStockDomain_9A8D06FAAD3A71C8A6CFE8A59B2835AB_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_9A8D06FAAD3A71C8A6CFE8A59B2835AB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_6822FE6DA53E584DE766E8A59B286F60" xlink:to="loc_us-gaap_ClassOfStockDomain_9A8D06FAAD3A71C8A6CFE8A59B2835AB" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_C11F4F68B6144EBCDEC7E8A59B29DBD0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_9A8D06FAAD3A71C8A6CFE8A59B2835AB" xlink:to="loc_hsy_HersheyCommonStockMember_C11F4F68B6144EBCDEC7E8A59B29DBD0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_4A8D71DED9BBCCBEC37EE8A59B29B0D5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_9A8D06FAAD3A71C8A6CFE8A59B2835AB" xlink:to="loc_us-gaap_CommonClassBMember_4A8D71DED9BBCCBEC37EE8A59B29B0D5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncreaseDecreaseInStockholdersEquityRollForward" xlink:label="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_4EA97DE614D93E0BF382E8A59B29639E" xlink:to="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_D90899ABA7C092AE6767E8A59B2A61C6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_D90899ABA7C092AE6767E8A59B2A61C6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_EEBA72EA286FD5EF4331E8A59B2A1CBD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_NetIncomeLoss_EEBA72EA286FD5EF4331E8A59B2A1CBD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_B9E4162404196973DD38E8A59B2A55C0" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_B9E4162404196973DD38E8A59B2A55C0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ProfitLoss" xlink:label="loc_us-gaap_ProfitLoss_2731D2F0F6F72E3A44EFE8A59B2A807E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_ProfitLoss_2731D2F0F6F72E3A44EFE8A59B2A807E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsNetOfTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsNetOfTax_1767F7CD289AB1388485E8A59B2BD8F2" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsNetOfTax_1767F7CD289AB1388485E8A59B2BD8F2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DividendsCommonStockAbstract" xlink:label="loc_us-gaap_DividendsCommonStockAbstract_8B8218B35C49C76A767CE8A59B2BBAFD" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_DividendsCommonStockAbstract_8B8218B35C49C76A767CE8A59B2BBAFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DividendsCommonStockCash" xlink:label="loc_us-gaap_DividendsCommonStockCash_2788DCF3FA2C38B80915E8A59B2BEB92" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DividendsCommonStockAbstract_8B8218B35C49C76A767CE8A59B2BBAFD" xlink:to="loc_us-gaap_DividendsCommonStockCash_2788DCF3FA2C38B80915E8A59B2BEB92" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueConversionOfConvertibleSecurities" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueConversionOfConvertibleSecurities_3D64F1D7F7708DAF3D49E8A59F3C553E" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueConversionOfConvertibleSecurities_3D64F1D7F7708DAF3D49E8A59F3C553E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue" xlink:label="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_178D9B274AFBD0B0E482E8A59B2BE10C" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_178D9B274AFBD0B0E482E8A59B2BE10C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_4546E844EFD773D47984E8A59B2C0375" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_4546E844EFD773D47984E8A59B2C0375" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockValueAcquiredCostMethod" xlink:label="loc_us-gaap_TreasuryStockValueAcquiredCostMethod_42A80D2BD7F78F9850B9E8A59B2C7B81" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_us-gaap_TreasuryStockValueAcquiredCostMethod_42A80D2BD7F78F9850B9E8A59B2C7B81" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_TaxCutsandJobsActReclassificationFromAOCIToRetainedEarningsTaxEffect" xlink:label="loc_hsy_TaxCutsandJobsActReclassificationFromAOCIToRetainedEarningsTaxEffect_D30F626847605BE9ADCBE8A59B2C10B4" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_0D929EA50B4354435C79E8A59B2904DC" xlink:to="loc_hsy_TaxCutsandJobsActReclassificationFromAOCIToRetainedEarningsTaxEffect_D30F626847605BE9ADCBE8A59B2C10B4" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_413E298C64995D15D84FC534A372F042" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_324863DF5F23D1980396C534A370C65C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_413E298C64995D15D84FC534A372F042" xlink:to="loc_us-gaap_StatementTable_324863DF5F23D1980396C534A370C65C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_BBB311886FA5FE9A7408C534A371ADC3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_324863DF5F23D1980396C534A370C65C" xlink:to="loc_us-gaap_StatementClassOfStockAxis_BBB311886FA5FE9A7408C534A371ADC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_ED13E460CF4D11E390E4C534A3717A68_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_BBB311886FA5FE9A7408C534A371ADC3" xlink:to="loc_us-gaap_ClassOfStockDomain_ED13E460CF4D11E390E4C534A3717A68_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_ED13E460CF4D11E390E4C534A3717A68" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_BBB311886FA5FE9A7408C534A371ADC3" xlink:to="loc_us-gaap_ClassOfStockDomain_ED13E460CF4D11E390E4C534A3717A68" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_18AAAD2FAF7426C019EFC534A371534C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_ED13E460CF4D11E390E4C534A3717A68" xlink:to="loc_hsy_HersheyCommonStockMember_18AAAD2FAF7426C019EFC534A371534C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_0A707A480B3BF319292AC534A372ADCB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_ED13E460CF4D11E390E4C534A3717A68" xlink:to="loc_us-gaap_CommonClassBMember_0A707A480B3BF319292AC534A372ADCB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_C878A82FBA5BB3C08B81C534A3727AAB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_413E298C64995D15D84FC534A372F042" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_C878A82FBA5BB3C08B81C534A3727AAB" 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/DerivativeInstrumentsDerivativeInstrumentsNarrativeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_60A7068E0284A240AB05C534A203499E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_60A7068E0284A240AB05C534A203499E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_60A7068E0284A240AB05C534A203499E" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_60A7068E0284A240AB05C534A203499E" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_C2C59FF2C05329BC5115C534A2041C87" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:to="loc_us-gaap_CommodityContractMember_C2C59FF2C05329BC5115C534A2041C87" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_F5FDD1DEE907CFF8132AC534A204DA95" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:to="loc_us-gaap_ForeignExchangeContractMember_F5FDD1DEE907CFF8132AC534A204DA95" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_EA9C056236CC52FDECBCC534A204A6D3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:to="loc_us-gaap_InterestRateContractMember_EA9C056236CC52FDECBCC534A204A6D3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_31ACF919C1FCAE3B3D52C534A2044515" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:to="loc_us-gaap_EquitySwapMember_31ACF919C1FCAE3B3D52C534A2044515" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestRateSwapMember" xlink:label="loc_us-gaap_InterestRateSwapMember_EE1FE8AC82EB0EC0A461C534A205C292" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_E9ED8E629E043859C8FDC534A203299E" xlink:to="loc_us-gaap_InterestRateSwapMember_EE1FE8AC82EB0EC0A461C534A205C292" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_10ACE37FDE843C4D138AC534A205587F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:to="loc_us-gaap_HedgingDesignationAxis_10ACE37FDE843C4D138AC534A205587F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_1E190B9FA1F2B09AD298C534A205B585_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_10ACE37FDE843C4D138AC534A205587F" xlink:to="loc_us-gaap_HedgingDesignationDomain_1E190B9FA1F2B09AD298C534A205B585_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_1E190B9FA1F2B09AD298C534A205B585" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_10ACE37FDE843C4D138AC534A205587F" xlink:to="loc_us-gaap_HedgingDesignationDomain_1E190B9FA1F2B09AD298C534A205B585" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_908B01004EB023124231C534A205BE51" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_1E190B9FA1F2B09AD298C534A205B585" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_908B01004EB023124231C534A205BE51" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_24A9B013798B583748E8C534A205CED2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_1E190B9FA1F2B09AD298C534A205B585" xlink:to="loc_us-gaap_NondesignatedMember_24A9B013798B583748E8C534A205CED2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_1C7BC500F8563F98279FC534A2065026" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_1C7BC500F8563F98279FC534A2065026" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_71C9663973FBB108A31FC534A206DEFE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_1C7BC500F8563F98279FC534A2065026" xlink:to="loc_us-gaap_HedgingRelationshipDomain_71C9663973FBB108A31FC534A206DEFE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_71C9663973FBB108A31FC534A206DEFE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_1C7BC500F8563F98279FC534A2065026" xlink:to="loc_us-gaap_HedgingRelationshipDomain_71C9663973FBB108A31FC534A206DEFE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_934AA9AEE5666FFD6428C534A2069B84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_71C9663973FBB108A31FC534A206DEFE" xlink:to="loc_us-gaap_CashFlowHedgingMember_934AA9AEE5666FFD6428C534A2069B84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_4ADA628B57682D380BF8C534A20686A3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_71C9663973FBB108A31FC534A206DEFE" xlink:to="loc_us-gaap_FairValueHedgingMember_4ADA628B57682D380BF8C534A20686A3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_7D0AF09836B11F11E3D1C534A2070633" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:to="loc_srt_RangeAxis_7D0AF09836B11F11E3D1C534A2070633" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_4B6F6FC221FDF2820F78C534A207E0A9_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_7D0AF09836B11F11E3D1C534A2070633" xlink:to="loc_srt_RangeMember_4B6F6FC221FDF2820F78C534A207E0A9_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_4B6F6FC221FDF2820F78C534A207E0A9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_7D0AF09836B11F11E3D1C534A2070633" xlink:to="loc_srt_RangeMember_4B6F6FC221FDF2820F78C534A207E0A9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_FC82FB7878491FC8629CC534A20784F8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_4B6F6FC221FDF2820F78C534A207E0A9" xlink:to="loc_srt_MinimumMember_FC82FB7878491FC8629CC534A20784F8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_B3202EA5A826B0D82E06C534A2081454" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_4B6F6FC221FDF2820F78C534A207E0A9" xlink:to="loc_srt_MaximumMember_B3202EA5A826B0D82E06C534A2081454" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_484453C0725D3C22E8DDC534A208EC5E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_F85095979F5A9D762530C534A203E742" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_484453C0725D3C22E8DDC534A208EC5E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_43E0713FB21A698EB1B9C534A2088902_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_484453C0725D3C22E8DDC534A208EC5E" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_43E0713FB21A698EB1B9C534A2088902_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_43E0713FB21A698EB1B9C534A2088902" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_484453C0725D3C22E8DDC534A208EC5E" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_43E0713FB21A698EB1B9C534A2088902" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestExpenseMember" xlink:label="loc_us-gaap_InterestExpenseMember_D50034B7E7CDBFFD3F72C534A20873B1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_43E0713FB21A698EB1B9C534A2088902" xlink:to="loc_us-gaap_InterestExpenseMember_D50034B7E7CDBFFD3F72C534A20873B1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeTermOfContract" xlink:label="loc_us-gaap_DerivativeTermOfContract_1944CAB4499632C33A3EC534A20944F7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_us-gaap_DerivativeTermOfContract_1944CAB4499632C33A3EC534A20944F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.sec.gov/invest/2013/invest-2013-01-31.xsd#invest_DerivativeNotionalAmount" xlink:label="loc_invest_DerivativeNotionalAmount_248D472604D2F3007EC6C534A209C791" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_invest_DerivativeNotionalAmount_248D472604D2F3007EC6C534A209C791" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_MinimumLengthofTimeHedgedinCashFlowHedge" xlink:label="loc_hsy_MinimumLengthofTimeHedgedinCashFlowHedge_197BC1F2E82EE1042146C534A20961E1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_hsy_MinimumLengthofTimeHedgedinCashFlowHedge_197BC1F2E82EE1042146C534A20961E1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1" xlink:label="loc_us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1_AA9AE6391962EE0BB54AC534A20A9608" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1_AA9AE6391962EE0BB54AC534A20A9608" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncreaseDecreaseInDerivativeAssetsAndLiabilities" xlink:label="loc_us-gaap_IncreaseDecreaseInDerivativeAssetsAndLiabilities_BF8C10C9ED0ADD6D1D3BC534A20A5545" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_us-gaap_IncreaseDecreaseInDerivativeAssetsAndLiabilities_BF8C10C9ED0ADD6D1D3BC534A20A5545" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths" xlink:label="loc_us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths_002FA9C58DF96D23C4C1C534A20A7F7A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths_002FA9C58DF96D23C4C1C534A20A7F7A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1" xlink:label="loc_us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1_1F64FD16800274874F56C534A20A0B28" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_C8A954BB7C194E6FED2AC534A2091444" xlink:to="loc_us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1_1F64FD16800274874F56C534A20A0B28" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativesFairValueLineItems" xlink:label="loc_us-gaap_DerivativesFairValueLineItems_6539784BD30E9DBA1FA3C534A1FA69BD" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable" xlink:label="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_9CC7E6814EFBD98E5271C534A1F7E44F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_6539784BD30E9DBA1FA3C534A1FA69BD" xlink:to="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_9CC7E6814EFBD98E5271C534A1F7E44F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_F7C14EF78E2A92FAF091C534A1F77152" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_9CC7E6814EFBD98E5271C534A1F7E44F" xlink:to="loc_us-gaap_HedgingDesignationAxis_F7C14EF78E2A92FAF091C534A1F77152" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_D95F31CFD0391FB81F16C534A1F7F867_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_F7C14EF78E2A92FAF091C534A1F77152" xlink:to="loc_us-gaap_HedgingDesignationDomain_D95F31CFD0391FB81F16C534A1F7F867_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_D95F31CFD0391FB81F16C534A1F7F867" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_F7C14EF78E2A92FAF091C534A1F77152" xlink:to="loc_us-gaap_HedgingDesignationDomain_D95F31CFD0391FB81F16C534A1F7F867" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_23FB0F677EC6B6A3AFF1C534A1F836C9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_D95F31CFD0391FB81F16C534A1F7F867" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_23FB0F677EC6B6A3AFF1C534A1F836C9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_070DE0E1857E02A76278C534A1F8EE77" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_D95F31CFD0391FB81F16C534A1F7F867" xlink:to="loc_us-gaap_NondesignatedMember_070DE0E1857E02A76278C534A1F8EE77" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_33D2589562F6795EA4DDC534A1F84E70" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_9CC7E6814EFBD98E5271C534A1F7E44F" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_33D2589562F6795EA4DDC534A1F84E70" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_411A7E11B7BA1A074BD3C534A1F8200E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_33D2589562F6795EA4DDC534A1F84E70" xlink:to="loc_us-gaap_HedgingRelationshipDomain_411A7E11B7BA1A074BD3C534A1F8200E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_411A7E11B7BA1A074BD3C534A1F8200E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_33D2589562F6795EA4DDC534A1F84E70" xlink:to="loc_us-gaap_HedgingRelationshipDomain_411A7E11B7BA1A074BD3C534A1F8200E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_1B7F1289A76C9099192FC534A1F92EB7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_411A7E11B7BA1A074BD3C534A1F8200E" xlink:to="loc_us-gaap_CashFlowHedgingMember_1B7F1289A76C9099192FC534A1F92EB7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_E717396D4F80C6473E2DC534A1F9131F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_411A7E11B7BA1A074BD3C534A1F8200E" xlink:to="loc_us-gaap_FairValueHedgingMember_E717396D4F80C6473E2DC534A1F9131F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_2AEDD5C52DDED5015EB0C534A1F99F57" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_9CC7E6814EFBD98E5271C534A1F7E44F" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_2AEDD5C52DDED5015EB0C534A1F99F57" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_2AEDD5C52DDED5015EB0C534A1F99F57" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_2AEDD5C52DDED5015EB0C534A1F99F57" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_0086F338CB4D07BD3BDBC534A1FA95B9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4" xlink:to="loc_us-gaap_CommodityContractMember_0086F338CB4D07BD3BDBC534A1FA95B9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_F3FBF90CFF30FD27C7E8C534A1FA11FB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4" xlink:to="loc_us-gaap_ForeignExchangeContractMember_F3FBF90CFF30FD27C7E8C534A1FA11FB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_37C0A5A90241338E98EFC534A1FA6244" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4" xlink:to="loc_us-gaap_InterestRateContractMember_37C0A5A90241338E98EFC534A1FA6244" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_FC01BC2BF170B9ECB133C534A1FAF0CA" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A579384947272B633FD4C534A1F9E5F4" xlink:to="loc_us-gaap_EquitySwapMember_FC01BC2BF170B9ECB133C534A1FAF0CA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_4AF0EC279CF2B30FE23BC534A1FBB52C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_6539784BD30E9DBA1FA3C534A1FA69BD" xlink:to="loc_us-gaap_DerivativeAssets_4AF0EC279CF2B30FE23BC534A1FBB52C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_EBA2714F0341490D8DBAC534A1FBE45A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_6539784BD30E9DBA1FA3C534A1FA69BD" xlink:to="loc_us-gaap_DerivativeLiabilities_EBA2714F0341490D8DBAC534A1FBE45A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading" xlink:label="loc_hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_217877590537BF806E4FC534A1FB8CD3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_6539784BD30E9DBA1FA3C534A1FA69BD" xlink:to="loc_hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_217877590537BF806E4FC534A1FB8CD3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading" xlink:label="loc_hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_EDF2A9E474442031EE98C534A1FB9CC6" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_6539784BD30E9DBA1FA3C534A1FA69BD" xlink:to="loc_hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_EDF2A9E474442031EE98C534A1FB9CC6" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_EA584C0B5839A359DB38C534A1F0C4EE" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_D3F7201CE76A9D3643AAC534A1EDE572" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_EA584C0B5839A359DB38C534A1F0C4EE" xlink:to="loc_us-gaap_DerivativeTable_D3F7201CE76A9D3643AAC534A1EDE572" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_CEF403C7DFA076EAE77DC534A1ED67E7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_D3F7201CE76A9D3643AAC534A1EDE572" xlink:to="loc_us-gaap_HedgingDesignationAxis_CEF403C7DFA076EAE77DC534A1ED67E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_A3AAC865F0947A792314C534A1EE11B6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_CEF403C7DFA076EAE77DC534A1ED67E7" xlink:to="loc_us-gaap_HedgingDesignationDomain_A3AAC865F0947A792314C534A1EE11B6_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_A3AAC865F0947A792314C534A1EE11B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_CEF403C7DFA076EAE77DC534A1ED67E7" xlink:to="loc_us-gaap_HedgingDesignationDomain_A3AAC865F0947A792314C534A1EE11B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_FCD8276DC513FB146518C534A1EE179F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_A3AAC865F0947A792314C534A1EE11B6" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_FCD8276DC513FB146518C534A1EE179F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C3720F659318EE80E6C6C534A1EE056A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_D3F7201CE76A9D3643AAC534A1EDE572" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C3720F659318EE80E6C6C534A1EE056A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_6719450634DC0CF6A563C534A1EE5678_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C3720F659318EE80E6C6C534A1EE056A" xlink:to="loc_us-gaap_HedgingRelationshipDomain_6719450634DC0CF6A563C534A1EE5678_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_6719450634DC0CF6A563C534A1EE5678" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C3720F659318EE80E6C6C534A1EE056A" xlink:to="loc_us-gaap_HedgingRelationshipDomain_6719450634DC0CF6A563C534A1EE5678" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_E127572B0634E8472488C534A1EF4500" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_6719450634DC0CF6A563C534A1EE5678" xlink:to="loc_us-gaap_CashFlowHedgingMember_E127572B0634E8472488C534A1EF4500" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_808C3DCFBA6EF680880AC534A1EFC5C5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_D3F7201CE76A9D3643AAC534A1EDE572" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_808C3DCFBA6EF680880AC534A1EFC5C5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_808C3DCFBA6EF680880AC534A1EFC5C5" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_808C3DCFBA6EF680880AC534A1EFC5C5" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_EF5FF6E098C358C657B9C534A1F0750E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE" xlink:to="loc_us-gaap_CommodityContractMember_EF5FF6E098C358C657B9C534A1F0750E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_5C12463A7E45CF70A74CC534A1F0AA2C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE" xlink:to="loc_us-gaap_ForeignExchangeContractMember_5C12463A7E45CF70A74CC534A1F0AA2C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_0757CE7040B60F1CFD77C534A1F034DD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE" xlink:to="loc_us-gaap_InterestRateContractMember_0757CE7040B60F1CFD77C534A1F034DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_B03CB997D5FFFCF69CE3C534A1F06C12" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_756F9194F8414A3A31AAC534A1EF03CE" xlink:to="loc_us-gaap_EquitySwapMember_B03CB997D5FFFCF69CE3C534A1F06C12" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet" xlink:label="loc_us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet_E517C7F8EA0E5FC79B63C534A1F0CD2D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_EA584C0B5839A359DB38C534A1F0C4EE" xlink:to="loc_us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet_E517C7F8EA0E5FC79B63C534A1F0CD2D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodBeforeTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodBeforeTax_D3914C70F547E9B2F7E8C534A1F1BF48" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_EA584C0B5839A359DB38C534A1F0C4EE" xlink:to="loc_us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodBeforeTax_D3914C70F547E9B2F7E8C534A1F1BF48" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossReclassifiedFromAccumulatedOCIIntoIncomeEffectivePortionNet" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossReclassifiedFromAccumulatedOCIIntoIncomeEffectivePortionNet_6E9EB0F78188896D380FC534A1F1D54B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_EA584C0B5839A359DB38C534A1F0C4EE" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossReclassifiedFromAccumulatedOCIIntoIncomeEffectivePortionNet_6E9EB0F78188896D380FC534A1F1D54B" 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/DocumentAndEntityInformation" xlink:type="extended">
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_DocumentInformationLineItems" xlink:label="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:type="locator" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_DocumentInformationTable" xlink:label="loc_dei_DocumentInformationTable_D43D068B550093AB762AC534A476C516" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_DocumentInformationTable_D43D068B550093AB762AC534A476C516" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_49E10DADAAA108711664C534A4763827" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_dei_DocumentInformationTable_D43D068B550093AB762AC534A476C516" xlink:to="loc_us-gaap_StatementClassOfStockAxis_49E10DADAAA108711664C534A4763827" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_1429489F22BDA2C28726C534A47676B8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_49E10DADAAA108711664C534A4763827" xlink:to="loc_us-gaap_ClassOfStockDomain_1429489F22BDA2C28726C534A47676B8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_1429489F22BDA2C28726C534A47676B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_49E10DADAAA108711664C534A4763827" xlink:to="loc_us-gaap_ClassOfStockDomain_1429489F22BDA2C28726C534A47676B8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_2C27D2644193942856EDC534A4772421" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_1429489F22BDA2C28726C534A47676B8" xlink:to="loc_hsy_HersheyCommonStockMember_2C27D2644193942856EDC534A4772421" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_6D412458256DDE8EE13CC534A477AD3B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_1429489F22BDA2C28726C534A47676B8" xlink:to="loc_us-gaap_CommonClassBMember_6D412458256DDE8EE13CC534A477AD3B" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityRegistrantName" xlink:label="loc_dei_EntityRegistrantName_664374ADAA6A3DAAC18BC534A478A8A9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityRegistrantName_664374ADAA6A3DAAC18BC534A478A8A9" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityCentralIndexKey" xlink:label="loc_dei_EntityCentralIndexKey_101211A2A9EC5FEC4E63C534A478E2B3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityCentralIndexKey_101211A2A9EC5FEC4E63C534A478E2B3" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_CurrentFiscalYearEndDate" xlink:label="loc_dei_CurrentFiscalYearEndDate_9BDC1BEB0A5BBF24218DC534A4780A44" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_CurrentFiscalYearEndDate_9BDC1BEB0A5BBF24218DC534A4780A44" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityFilerCategory" xlink:label="loc_dei_EntityFilerCategory_C5586BAE1067E3505924C534A479121B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityFilerCategory_C5586BAE1067E3505924C534A479121B" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_DocumentType" xlink:label="loc_dei_DocumentType_210B0AE36FF24D0D5A3FC534A4793B10" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_DocumentType_210B0AE36FF24D0D5A3FC534A4793B10" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_DocumentPeriodEndDate" xlink:label="loc_dei_DocumentPeriodEndDate_6DEC8C9003BC9E02F8F8C534A4796F6A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_DocumentPeriodEndDate_6DEC8C9003BC9E02F8F8C534A4796F6A" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_DocumentFiscalYearFocus" xlink:label="loc_dei_DocumentFiscalYearFocus_4D4959231E4159EA158BC534A479C03C" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_DocumentFiscalYearFocus_4D4959231E4159EA158BC534A479C03C" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_DocumentFiscalPeriodFocus" xlink:label="loc_dei_DocumentFiscalPeriodFocus_9CFFEEE815C79E5F010EC534A479B11A" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_DocumentFiscalPeriodFocus_9CFFEEE815C79E5F010EC534A479B11A" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_AmendmentFlag" xlink:label="loc_dei_AmendmentFlag_39C12BE6B11CCC6AACBCC534A4797C1B" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_AmendmentFlag_39C12BE6B11CCC6AACBCC534A4797C1B" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityCommonStockSharesOutstanding" xlink:label="loc_dei_EntityCommonStockSharesOutstanding_4F879717F5B2F1766FC2C534A47AC06D" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityCommonStockSharesOutstanding_4F879717F5B2F1766FC2C534A47AC06D" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityWellKnownSeasonedIssuer" xlink:label="loc_dei_EntityWellKnownSeasonedIssuer_84473162821801E3F627C534A47F9214" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityWellKnownSeasonedIssuer_84473162821801E3F627C534A47F9214" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityVoluntaryFilers" xlink:label="loc_dei_EntityVoluntaryFilers_C4F3EAC37EFABC309D8BC534A47F3C7A" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityVoluntaryFilers_C4F3EAC37EFABC309D8BC534A47F3C7A" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityCurrentReportingStatus" xlink:label="loc_dei_EntityCurrentReportingStatus_56E902A6DE4A795274AFC534A47F350F" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityCurrentReportingStatus_56E902A6DE4A795274AFC534A47F350F" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityPublicFloat" xlink:label="loc_dei_EntityPublicFloat_28A8C686CD8008B17CA4C534A48023B1" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityPublicFloat_28A8C686CD8008B17CA4C534A48023B1" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntitySmallBusiness" xlink:label="loc_dei_EntitySmallBusiness_0D951347620F3C87F60DC56490E59D57" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntitySmallBusiness_0D951347620F3C87F60DC56490E59D57" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityEmergingGrowthCompany" xlink:label="loc_dei_EntityEmergingGrowthCompany_03861B32AF9F1EC46F53C564AF7AA1D2" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityEmergingGrowthCompany_03861B32AF9F1EC46F53C564AF7AA1D2" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityShellCompany" xlink:label="loc_dei_EntityShellCompany_FC761F2F3117DB247269C564D855418D" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_95DCC0462F88973F0883C534A47845A0" xlink:to="loc_dei_EntityShellCompany_FC761F2F3117DB247269C564D855418D" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_762C472ECC5523A17623C534A0068B61" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable" xlink:label="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_7565A6597CBDF5238FFCC534A0056FA1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_762C472ECC5523A17623C534A0068B61" xlink:to="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_7565A6597CBDF5238FFCC534A0056FA1" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_6DB34B308DBBBD2E659AC534A005B012" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_7565A6597CBDF5238FFCC534A0056FA1" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_6DB34B308DBBBD2E659AC534A005B012" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AntidilutiveSecuritiesNameDomain" xlink:label="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1B71D286978985C3DC9EC534A005BCCF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_6DB34B308DBBBD2E659AC534A005B012" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1B71D286978985C3DC9EC534A005BCCF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AntidilutiveSecuritiesNameDomain" xlink:label="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1B71D286978985C3DC9EC534A005BCCF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_6DB34B308DBBBD2E659AC534A005B012" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1B71D286978985C3DC9EC534A005BCCF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_B84B9EA92335AE7BCDB5C534A00660C6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1B71D286978985C3DC9EC534A005BCCF" xlink:to="loc_us-gaap_EmployeeStockOptionMember_B84B9EA92335AE7BCDB5C534A00660C6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_CAB4B3B8FE52F4D1FF05C534A0069317" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_762C472ECC5523A17623C534A0068B61" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_CAB4B3B8FE52F4D1FF05C534A0069317" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_F2367EEA1A2BAD4A1B23C534A04D5644" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:to="loc_us-gaap_AwardTypeAxis_F2367EEA1A2BAD4A1B23C534A04D5644" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87926CB9D164A320FCF1C534A04DC9F2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_F2367EEA1A2BAD4A1B23C534A04D5644" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87926CB9D164A320FCF1C534A04DC9F2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87926CB9D164A320FCF1C534A04DC9F2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_F2367EEA1A2BAD4A1B23C534A04D5644" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87926CB9D164A320FCF1C534A04DC9F2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_AAEA433501B1F74E0C3BC534A04D69EF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_87926CB9D164A320FCF1C534A04DC9F2" xlink:to="loc_hsy_HersheyTrustCompanyMember_AAEA433501B1F74E0C3BC534A04D69EF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_F87FD3004FAB5434647FC534A04E39C2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:to="loc_us-gaap_StatementClassOfStockAxis_F87FD3004FAB5434647FC534A04E39C2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_8D3ACDFC3C436E2E08E3C534A04E586A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_F87FD3004FAB5434647FC534A04E39C2" xlink:to="loc_us-gaap_ClassOfStockDomain_8D3ACDFC3C436E2E08E3C534A04E586A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_8D3ACDFC3C436E2E08E3C534A04E586A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_F87FD3004FAB5434647FC534A04E39C2" xlink:to="loc_us-gaap_ClassOfStockDomain_8D3ACDFC3C436E2E08E3C534A04E586A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_2FABBF77B984E6A37748C534A04EB255" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_8D3ACDFC3C436E2E08E3C534A04E586A" xlink:to="loc_hsy_HersheyCommonStockMember_2FABBF77B984E6A37748C534A04EB255" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_0C721B21CE48CADD3A49C534A04EEF6B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_8D3ACDFC3C436E2E08E3C534A04E586A" xlink:to="loc_us-gaap_CommonClassBMember_0C721B21CE48CADD3A49C534A04EEF6B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_CounterpartyNameAxis" xlink:label="loc_srt_CounterpartyNameAxis_70D8896399898F3A6425C534A04FE1FC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:to="loc_srt_CounterpartyNameAxis_70D8896399898F3A6425C534A04FE1FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RepurchaseAgreementCounterpartyNameDomain" xlink:label="loc_srt_RepurchaseAgreementCounterpartyNameDomain_E66638FA7A629CC7220AC534A04F0589_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_CounterpartyNameAxis_70D8896399898F3A6425C534A04FE1FC" xlink:to="loc_srt_RepurchaseAgreementCounterpartyNameDomain_E66638FA7A629CC7220AC534A04F0589_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RepurchaseAgreementCounterpartyNameDomain" xlink:label="loc_srt_RepurchaseAgreementCounterpartyNameDomain_E66638FA7A629CC7220AC534A04F0589" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_CounterpartyNameAxis_70D8896399898F3A6425C534A04FE1FC" xlink:to="loc_srt_RepurchaseAgreementCounterpartyNameDomain_E66638FA7A629CC7220AC534A04F0589" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_1BEAA814551D17BFC6E7C534A04F1CDD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RepurchaseAgreementCounterpartyNameDomain_E66638FA7A629CC7220AC534A04F0589" xlink:to="loc_hsy_HersheyTrustCompanyMember_1BEAA814551D17BFC6E7C534A04F1CDD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_B012979B42023E5D85F1C534A04F3304" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_B012979B42023E5D85F1C534A04F3304" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_90050409A7B15BFFFADEC534A0503CFE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_B012979B42023E5D85F1C534A04F3304" xlink:to="loc_us-gaap_EquityComponentDomain_90050409A7B15BFFFADEC534A0503CFE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_90050409A7B15BFFFADEC534A0503CFE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_B012979B42023E5D85F1C534A04F3304" xlink:to="loc_us-gaap_EquityComponentDomain_90050409A7B15BFFFADEC534A0503CFE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_5BB2929F02422DC80011C534A0508D36" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_90050409A7B15BFFFADEC534A0503CFE" xlink:to="loc_us-gaap_NoncontrollingInterestMember_5BB2929F02422DC80011C534A0508D36" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_LegalEntityAxis" xlink:label="loc_dei_LegalEntityAxis_F8DF914B63ED3B2CC445C534A0502FE7" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_D28553F8D7E3CB5B3171C534A04C3B6F" xlink:to="loc_dei_LegalEntityAxis_F8DF914B63ED3B2CC445C534A0502FE7" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_3FBF2C6B6C5CF5EEC8AEC534A050E997_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_dei_LegalEntityAxis_F8DF914B63ED3B2CC445C534A0502FE7" xlink:to="loc_dei_EntityDomain_3FBF2C6B6C5CF5EEC8AEC534A050E997_default" xlink:type="arc" />
    <link:loc xlink:href="https://xbrl.sec.gov/dei/2018/dei-2018-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_3FBF2C6B6C5CF5EEC8AEC534A050E997" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_dei_LegalEntityAxis_F8DF914B63ED3B2CC445C534A0502FE7" xlink:to="loc_dei_EntityDomain_3FBF2C6B6C5CF5EEC8AEC534A050E997" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_LotteShanghaiFoodCompanyMember" xlink:label="loc_hsy_LotteShanghaiFoodCompanyMember_A3A5EFAE64AC77412867C534A051CF3B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityDomain_3FBF2C6B6C5CF5EEC8AEC534A050E997" xlink:to="loc_hsy_LotteShanghaiFoodCompanyMember_A3A5EFAE64AC77412867C534A051CF3B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_CommonandPreferredStockSharesAuthorized" xlink:label="loc_hsy_CommonandPreferredStockSharesAuthorized_38403E44FDEF1DC6D792C534A05170F2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_hsy_CommonandPreferredStockSharesAuthorized_38403E44FDEF1DC6D792C534A05170F2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockSharesAuthorized" xlink:label="loc_us-gaap_CommonStockSharesAuthorized_16CBA884A2F234961443C534A051D8F0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_CommonStockSharesAuthorized_16CBA884A2F234961443C534A051D8F0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PreferredStockSharesAuthorized" xlink:label="loc_us-gaap_PreferredStockSharesAuthorized_EE58C47B950DBBD307FDC534A0527246" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_PreferredStockSharesAuthorized_EE58C47B950DBBD307FDC534A0527246" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockParOrStatedValuePerShare" xlink:label="loc_us-gaap_CommonStockParOrStatedValuePerShare_3EF5287F3EB706ABA585C534A0524052" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_CommonStockParOrStatedValuePerShare_3EF5287F3EB706ABA585C534A0524052" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_CommonStockNumberofVotes" xlink:label="loc_hsy_CommonStockNumberofVotes_7A236304D15440872CFBC534A0527F83" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_hsy_CommonStockNumberofVotes_7A236304D15440872CFBC534A0527F83" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends" xlink:label="loc_hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends_99375AE59280ADEFA21AC534A0527D11" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends_99375AE59280ADEFA21AC534A0527D11" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConversionOfStockSharesConverted1" xlink:label="loc_us-gaap_ConversionOfStockSharesConverted1_FE07C7183DD0622ED08EC534A052954E" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_ConversionOfStockSharesConverted1_FE07C7183DD0622ED08EC534A052954E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockSharesOutstanding" xlink:label="loc_us-gaap_CommonStockSharesOutstanding_A46E1C2A461B929D67D7C534A05355C4" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_A46E1C2A461B929D67D7C534A05355C4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_CommonStockVotingPercentage" xlink:label="loc_hsy_CommonStockVotingPercentage_707AA65F923C8E9869C4C534A0536730" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_hsy_CommonStockVotingPercentage_707AA65F923C8E9869C4C534A0536730" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockSharesAcquired" xlink:label="loc_us-gaap_TreasuryStockSharesAcquired_91E0B02B9EA3064AA9C2C534A0533C1D" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_TreasuryStockSharesAcquired_91E0B02B9EA3064AA9C2C534A0533C1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockAcquiredAverageCostPerShare" xlink:label="loc_us-gaap_TreasuryStockAcquiredAverageCostPerShare_FE0886FE19E3A39F49B7C534A0539EFF" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_TreasuryStockAcquiredAverageCostPerShare_FE0886FE19E3A39F49B7C534A0539EFF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockRepurchasedDuringPeriodValue" xlink:label="loc_us-gaap_StockRepurchasedDuringPeriodValue_0491B76596CA5CF9194DC534A0533F24" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_StockRepurchasedDuringPeriodValue_0491B76596CA5CF9194DC534A0533F24" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MinorityInterestOwnershipPercentageByParent" xlink:label="loc_us-gaap_MinorityInterestOwnershipPercentageByParent_83791454B6724B50D17CC534A053C47A" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_MinorityInterestOwnershipPercentageByParent_83791454B6724B50D17CC534A053C47A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PreferredStockParOrStatedValuePerShare" xlink:label="loc_us-gaap_PreferredStockParOrStatedValuePerShare_0641E69BF96EF61E5DCDC534A0542B5F" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_us-gaap_PreferredStockParOrStatedValuePerShare_0641E69BF96EF61E5DCDC534A0542B5F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_CommonStockVotingRightsBoardElectionPercentage" xlink:label="loc_hsy_CommonStockVotingRightsBoardElectionPercentage_7547DF6366CCCDFE5F72C534A0541CBC" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B82227C39632BA5195C8C534A05170B4" xlink:to="loc_hsy_CommonStockVotingRightsBoardElectionPercentage_7547DF6366CCCDFE5F72C534A0541CBC" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MinorityInterestLineItems" xlink:label="loc_us-gaap_MinorityInterestLineItems_26040FC1AC76CA25C857F198E152D6EA" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MinorityInterestTable" xlink:label="loc_us-gaap_MinorityInterestTable_744EA72A7F19BC0E3D33F198E1509B49" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_MinorityInterestLineItems_26040FC1AC76CA25C857F198E152D6EA" xlink:to="loc_us-gaap_MinorityInterestTable_744EA72A7F19BC0E3D33F198E1509B49" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_A34AD6846D9AAD00133CF198E15146A0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_MinorityInterestTable_744EA72A7F19BC0E3D33F198E1509B49" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_A34AD6846D9AAD00133CF198E15146A0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_F9342A114C07B5A4C237F198E151A12B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_A34AD6846D9AAD00133CF198E15146A0" xlink:to="loc_us-gaap_EquityComponentDomain_F9342A114C07B5A4C237F198E151A12B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_F9342A114C07B5A4C237F198E151A12B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_A34AD6846D9AAD00133CF198E15146A0" xlink:to="loc_us-gaap_EquityComponentDomain_F9342A114C07B5A4C237F198E151A12B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_B0946C95B3BF11157112F198E15137B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_F9342A114C07B5A4C237F198E151A12B" xlink:to="loc_us-gaap_NoncontrollingInterestMember_B0946C95B3BF11157112F198E15137B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MovementInMinorityInterestRollForward" xlink:label="loc_us-gaap_MovementInMinorityInterestRollForward_3AD190DE0DD5E617F36DF198E1520D62" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MinorityInterestLineItems_26040FC1AC76CA25C857F198E152D6EA" xlink:to="loc_us-gaap_MovementInMinorityInterestRollForward_3AD190DE0DD5E617F36DF198E1520D62" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MinorityInterest" xlink:label="loc_us-gaap_MinorityInterest_FE97AC61686CF9FF53CCF198E15230B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_3AD190DE0DD5E617F36DF198E1520D62" xlink:to="loc_us-gaap_MinorityInterest_FE97AC61686CF9FF53CCF198E15230B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_33B61B4278A3275AFCE1F198E152F51D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_3AD190DE0DD5E617F36DF198E1520D62" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_33B61B4278A3275AFCE1F198E152F51D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest_8D89FDC8F221A1F9CF9DF198E153ACD3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_3AD190DE0DD5E617F36DF198E1520D62" xlink:to="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest_8D89FDC8F221A1F9CF9DF198E153ACD3" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_7FCB347AAD109878D7B4C534A04312FA" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_0CF5F3ACDF6C5499A0ADC534A0418E00" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_7FCB347AAD109878D7B4C534A04312FA" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_0CF5F3ACDF6C5499A0ADC534A0418E00" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_23BB24E429ABE218DF70C534A0419342" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_0CF5F3ACDF6C5499A0ADC534A0418E00" xlink:to="loc_us-gaap_StatementClassOfStockAxis_23BB24E429ABE218DF70C534A0419342" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_B75CC90B686140FF9602C534A042D919_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_23BB24E429ABE218DF70C534A0419342" xlink:to="loc_us-gaap_ClassOfStockDomain_B75CC90B686140FF9602C534A042D919_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_B75CC90B686140FF9602C534A042D919" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_23BB24E429ABE218DF70C534A0419342" xlink:to="loc_us-gaap_ClassOfStockDomain_B75CC90B686140FF9602C534A042D919" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_D9860F6FF86D8D70BFFDC534A0427336" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_B75CC90B686140FF9602C534A042D919" xlink:to="loc_hsy_HersheyCommonStockMember_D9860F6FF86D8D70BFFDC534A0427336" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_50531A0CEA8B7D3FD1E6C534A042E4AD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_B75CC90B686140FF9602C534A042D919" xlink:to="loc_hsy_HersheyTrustCompanyMember_50531A0CEA8B7D3FD1E6C534A042E4AD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_B0FC7E7A5D6CDCB663C1C534A042FC9B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_0CF5F3ACDF6C5499A0ADC534A0418E00" xlink:to="loc_us-gaap_AwardTypeAxis_B0FC7E7A5D6CDCB663C1C534A042FC9B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_E062214064F1CD187F7AC534A0436DBF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_B0FC7E7A5D6CDCB663C1C534A042FC9B" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_E062214064F1CD187F7AC534A0436DBF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_E062214064F1CD187F7AC534A0436DBF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_B0FC7E7A5D6CDCB663C1C534A042FC9B" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_E062214064F1CD187F7AC534A0436DBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_3D82F93E731FCD53DCCFC534A0433709" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_E062214064F1CD187F7AC534A0436DBF" xlink:to="loc_us-gaap_EmployeeStockOptionMember_3D82F93E731FCD53DCCFC534A0433709" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockSharesIssued" xlink:label="loc_us-gaap_CommonStockSharesIssued_E36D07400C068520AB84C534A0437F1F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_7FCB347AAD109878D7B4C534A04312FA" xlink:to="loc_us-gaap_CommonStockSharesIssued_E36D07400C068520AB84C534A0437F1F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockShares" xlink:label="loc_us-gaap_TreasuryStockShares_DADEF4B5095D5E3C079AC534A0447838" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_7FCB347AAD109878D7B4C534A04312FA" xlink:to="loc_us-gaap_TreasuryStockShares_DADEF4B5095D5E3C079AC534A0447838" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_TreasuryStockSharesRollForward" xlink:label="loc_hsy_TreasuryStockSharesRollForward_CCEA77C40AAC3EAC47B6C534A0445CE2" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_7FCB347AAD109878D7B4C534A04312FA" xlink:to="loc_hsy_TreasuryStockSharesRollForward_CCEA77C40AAC3EAC47B6C534A0445CE2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShareRepurchaseProgramAbstract" xlink:label="loc_hsy_ShareRepurchaseProgramAbstract_2DDB5EEE2760798C1A6AC534A0442B35" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_CCEA77C40AAC3EAC47B6C534A0445CE2" xlink:to="loc_hsy_ShareRepurchaseProgramAbstract_2DDB5EEE2760798C1A6AC534A0442B35" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TreasuryStockSharesAcquired" xlink:label="loc_us-gaap_TreasuryStockSharesAcquired_15E1E3CBD86A309D2512C534A0442863" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_ShareRepurchaseProgramAbstract_2DDB5EEE2760798C1A6AC534A0442B35" xlink:to="loc_us-gaap_TreasuryStockSharesAcquired_15E1E3CBD86A309D2512C534A0442863" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_8285C150E4CCB7D757E6C534A0454105" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_CCEA77C40AAC3EAC47B6C534A0445CE2" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_8285C150E4CCB7D757E6C534A0454105" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross_7C616418D7A4591A222DC534A0455D71" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_8285C150E4CCB7D757E6C534A0454105" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross_7C616418D7A4591A222DC534A0455D71" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockSharesOutstanding" xlink:label="loc_us-gaap_CommonStockSharesOutstanding_34000C911F5B2CA00692C534A045226C" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_7FCB347AAD109878D7B4C534A04312FA" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_34000C911F5B2CA00692C534A045226C" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_0A310C3AFE6C13951F4EC534A1D2B947" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_AE0228DF4E5A1673437EC534A1CF4E84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_0A310C3AFE6C13951F4EC534A1D2B947" xlink:to="loc_us-gaap_DerivativeTable_AE0228DF4E5A1673437EC534A1CF4E84" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_3F82710F4B85D3155BD2C534A1D0F964" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_AE0228DF4E5A1673437EC534A1CF4E84" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_3F82710F4B85D3155BD2C534A1D0F964" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_4CE4C2C03F08D49CAA60C534A1D06C01_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_3F82710F4B85D3155BD2C534A1D0F964" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_4CE4C2C03F08D49CAA60C534A1D06C01_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_4CE4C2C03F08D49CAA60C534A1D06C01" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_3F82710F4B85D3155BD2C534A1D0F964" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_4CE4C2C03F08D49CAA60C534A1D06C01" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_C18C09FA34C0A21E8A17C534A1D02BD5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_4CE4C2C03F08D49CAA60C534A1D06C01" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_C18C09FA34C0A21E8A17C534A1D02BD5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_9B33AE7EAD481C6EAE27C534A1D15CEB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_AE0228DF4E5A1673437EC534A1CF4E84" xlink:to="loc_us-gaap_RestructuringPlanAxis_9B33AE7EAD481C6EAE27C534A1D15CEB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_F04739B223D6C4A35D6EC534A1D17DBA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_9B33AE7EAD481C6EAE27C534A1D15CEB" xlink:to="loc_us-gaap_RestructuringPlanDomain_F04739B223D6C4A35D6EC534A1D17DBA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_F04739B223D6C4A35D6EC534A1D17DBA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_9B33AE7EAD481C6EAE27C534A1D15CEB" xlink:to="loc_us-gaap_RestructuringPlanDomain_F04739B223D6C4A35D6EC534A1D17DBA" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_27968BDBD28EA9083690C534A1D13357" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_F04739B223D6C4A35D6EC534A1D17DBA" xlink:to="loc_hsy_MarginforGrowthProgramMember_27968BDBD28EA9083690C534A1D13357" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueNetAssetLiability" xlink:label="loc_us-gaap_FairValueNetAssetLiability_B2D81459EBFC0281F470C534A1D233B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_0A310C3AFE6C13951F4EC534A1D2B947" xlink:to="loc_us-gaap_FairValueNetAssetLiability_B2D81459EBFC0281F470C534A1D233B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsToBeDisposedOf" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsToBeDisposedOf_6C0FDF78B720F7EEFAA4C534A1D2BCF2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_0A310C3AFE6C13951F4EC534A1D2B947" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsToBeDisposedOf_6C0FDF78B720F7EEFAA4C534A1D2BCF2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_A7CDD68307E8716CE230C534A1D2DFF8" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_0A310C3AFE6C13951F4EC534A1D2B947" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_A7CDD68307E8716CE230C534A1D2DFF8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsHeldForUse" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_997D885F0040464D8439C534A1D2EE7F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_0A310C3AFE6C13951F4EC534A1D2B947" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_997D885F0040464D8439C534A1D2EE7F" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems" xlink:label="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_3A567BCD54AB3F56B17FC534A1E27B98" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByBalanceSheetGroupingTable" xlink:label="loc_us-gaap_FairValueByBalanceSheetGroupingTable_15ADFE8EB153F1116792C534A1DFACD9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_3A567BCD54AB3F56B17FC534A1E27B98" xlink:to="loc_us-gaap_FairValueByBalanceSheetGroupingTable_15ADFE8EB153F1116792C534A1DFACD9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_991171DCF211B8562132C534A1DF79F8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_15ADFE8EB153F1116792C534A1DFACD9" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_991171DCF211B8562132C534A1DF79F8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_39771693E1C53AC66CB9C534A1DF63D4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_991171DCF211B8562132C534A1DF79F8" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_39771693E1C53AC66CB9C534A1DF63D4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_39771693E1C53AC66CB9C534A1DF63D4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_991171DCF211B8562132C534A1DF79F8" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_39771693E1C53AC66CB9C534A1DF63D4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_6569BDB9DE32B254291EC534A1E091E2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_39771693E1C53AC66CB9C534A1DF63D4" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_6569BDB9DE32B254291EC534A1E091E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_2FD3C94F7F43ABF2DD4AC534A1E0620A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_15ADFE8EB153F1116792C534A1DFACD9" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_2FD3C94F7F43ABF2DD4AC534A1E0620A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_2FD3C94F7F43ABF2DD4AC534A1E0620A" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_2FD3C94F7F43ABF2DD4AC534A1E0620A" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_BA14B8ED1D06477E609CC534A1E0D860" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52" xlink:to="loc_us-gaap_ForeignExchangeContractMember_BA14B8ED1D06477E609CC534A1E0D860" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_23464CA3635D19581543C534A1E112FC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52" xlink:to="loc_us-gaap_InterestRateContractMember_23464CA3635D19581543C534A1E112FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_24C5710B7B13FA5649CCC534A1E1D453" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52" xlink:to="loc_us-gaap_EquitySwapMember_24C5710B7B13FA5649CCC534A1E1D453" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_B79E7CAEAF180B3B9D4CC534A1E1945F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_F813B17FBA2DCBF0065BC534A1E09B52" xlink:to="loc_us-gaap_CommodityContractMember_B79E7CAEAF180B3B9D4CC534A1E1945F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_157B7356C3A9502F3995C534A1E1043D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_15ADFE8EB153F1116792C534A1DFACD9" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_157B7356C3A9502F3995C534A1E1043D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_157B7356C3A9502F3995C534A1E1043D" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_157B7356C3A9502F3995C534A1E1043D" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel1Member" xlink:label="loc_us-gaap_FairValueInputsLevel1Member_1BA0F571991257CB2910C534A1E1F980" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_1BA0F571991257CB2910C534A1E1F980" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_6225D32BEDD77B593863C534A1E25688" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_6225D32BEDD77B593863C534A1E25688" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_EC235CC39C091669AFE6C534A1E2A189" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_13DACFA13AAE89D5DF9FC534A1E19BFD" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_EC235CC39C091669AFE6C534A1E2A189" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_72EA22A3C81D33CB68DBC534A1E20560" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_3A567BCD54AB3F56B17FC534A1E27B98" xlink:to="loc_us-gaap_DerivativeAssets_72EA22A3C81D33CB68DBC534A1E20560" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_E88C262629413E72BA54C534A1E31C94" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_3A567BCD54AB3F56B17FC534A1E27B98" xlink:to="loc_us-gaap_DerivativeLiabilities_E88C262629413E72BA54C534A1E31C94" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_0E5F61593701E31D9A5BC534A1D75E37" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_0E5F61593701E31D9A5BC534A1D75E37" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A57E669BDFECFC21A64FC534A1D799C8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_0E5F61593701E31D9A5BC534A1D75E37" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A57E669BDFECFC21A64FC534A1D799C8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_658D71442408C4B0C6B2C534A1D8E9B0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A57E669BDFECFC21A64FC534A1D799C8" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_658D71442408C4B0C6B2C534A1D8E9B0_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_658D71442408C4B0C6B2C534A1D8E9B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A57E669BDFECFC21A64FC534A1D799C8" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_658D71442408C4B0C6B2C534A1D8E9B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_89D237F72138DA746A6FC534A1D8FF43" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_658D71442408C4B0C6B2C534A1D8E9B0" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_89D237F72138DA746A6FC534A1D8FF43" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_LongtermDebtCurrentMaturitiesFairValue" xlink:label="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_0AF6D96C018D86E70F24C534A1D8BFF8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_0AF6D96C018D86E70F24C534A1D8BFF8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_LongtermDebtExcludingCurrentMaturitiesFairValue" xlink:label="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_68F0156210AC45232533C534A1D9360D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_68F0156210AC45232533C534A1D9360D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtFairValue" xlink:label="loc_us-gaap_LongTermDebtFairValue_00F6B16653801C3EE0DFC534A1D9FD5C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_us-gaap_LongTermDebtFairValue_00F6B16653801C3EE0DFC534A1D9FD5C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_9281ED9CE4F84C24EC6FC534A1D9D338" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_us-gaap_LongTermDebtCurrent_9281ED9CE4F84C24EC6FC534A1D9D338" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtNoncurrent" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_2E4D7BEC881465CCAE44C534A1D988A8" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_2E4D7BEC881465CCAE44C534A1D988A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_FFB9F4D9DF838B414BFDC534A1D932D3" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_E6E3A8EC6E2435164720C534A1D869B6" xlink:to="loc_us-gaap_LongTermDebt_FFB9F4D9DF838B414BFDC534A1D932D3" 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: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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillLineItems" xlink:label="loc_us-gaap_GoodwillLineItems_41F071C4803CDA81305EC534A29496E0" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfGoodwillTable" xlink:label="loc_us-gaap_ScheduleOfGoodwillTable_ECDAE94AB92BD46419B0C534A292BAB1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_GoodwillLineItems_41F071C4803CDA81305EC534A29496E0" xlink:to="loc_us-gaap_ScheduleOfGoodwillTable_ECDAE94AB92BD46419B0C534A292BAB1" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_8F6CBAA5C2AF180C8EE0C534A293A117" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_ECDAE94AB92BD46419B0C534A292BAB1" xlink:to="loc_srt_ConsolidationItemsAxis_8F6CBAA5C2AF180C8EE0C534A293A117" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_091089DE61AB28A626DCC534A29358C4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_8F6CBAA5C2AF180C8EE0C534A293A117" xlink:to="loc_srt_ConsolidationItemsDomain_091089DE61AB28A626DCC534A29358C4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_091089DE61AB28A626DCC534A29358C4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_8F6CBAA5C2AF180C8EE0C534A293A117" xlink:to="loc_srt_ConsolidationItemsDomain_091089DE61AB28A626DCC534A29358C4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_5CF1F0DFE75392051D33C534A293C648" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_091089DE61AB28A626DCC534A29358C4" xlink:to="loc_us-gaap_OperatingSegmentsMember_5CF1F0DFE75392051D33C534A293C648" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_4013E88F371E8D024B61C534A294220C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_ECDAE94AB92BD46419B0C534A292BAB1" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_4013E88F371E8D024B61C534A294220C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_F1DC48F3B3A49C5A33E1C534A2943071_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_4013E88F371E8D024B61C534A294220C" xlink:to="loc_us-gaap_SegmentDomain_F1DC48F3B3A49C5A33E1C534A2943071_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_F1DC48F3B3A49C5A33E1C534A2943071" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_4013E88F371E8D024B61C534A294220C" xlink:to="loc_us-gaap_SegmentDomain_F1DC48F3B3A49C5A33E1C534A2943071" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_6D83203AC9E1E1CE970EC534A294DEF2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_F1DC48F3B3A49C5A33E1C534A2943071" xlink:to="loc_hsy_NorthAmericaSegmentMember_6D83203AC9E1E1CE970EC534A294DEF2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_C104B2D9450390A952ECC534A294B986" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_F1DC48F3B3A49C5A33E1C534A2943071" xlink:to="loc_hsy_InternationalandOtherSegmentMember_C104B2D9450390A952ECC534A294B986" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillGross" xlink:label="loc_us-gaap_GoodwillGross_6B24DAA7C8ADF13B8C43C534A295364D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_41F071C4803CDA81305EC534A29496E0" xlink:to="loc_us-gaap_GoodwillGross_6B24DAA7C8ADF13B8C43C534A295364D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillImpairedAccumulatedImpairmentLoss" xlink:label="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_1ED507452AE16A5CB5E5C534A2955962" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_41F071C4803CDA81305EC534A29496E0" xlink:to="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_1ED507452AE16A5CB5E5C534A2955962" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillRollForward" xlink:label="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_41F071C4803CDA81305EC534A29496E0" xlink:to="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_B1F46CB134E64815CB8DC534A2959612" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:to="loc_us-gaap_Goodwill_B1F46CB134E64815CB8DC534A2959612" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillAcquiredDuringPeriod" xlink:label="loc_us-gaap_GoodwillAcquiredDuringPeriod_728C5371EB5F9F6F2946C534A296B0CC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:to="loc_us-gaap_GoodwillAcquiredDuringPeriod_728C5371EB5F9F6F2946C534A296B0CC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillPurchaseAccountingAdjustments" xlink:label="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_41FD5214A5A9916123D8C534A296332A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:to="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_41FD5214A5A9916123D8C534A296332A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillWrittenOffRelatedToSaleOfBusinessUnit" xlink:label="loc_us-gaap_GoodwillWrittenOffRelatedToSaleOfBusinessUnit_258E2EC179C93F546870C534A296D18E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:to="loc_us-gaap_GoodwillWrittenOffRelatedToSaleOfBusinessUnit_258E2EC179C93F546870C534A296D18E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillForeignCurrencyTranslationGainLoss" xlink:label="loc_us-gaap_GoodwillForeignCurrencyTranslationGainLoss_3529D6B94847E9443223C534A296A5CE" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_2C4E812F57A104DE102BC534A2958CC0" xlink:to="loc_us-gaap_GoodwillForeignCurrencyTranslationGainLoss_3529D6B94847E9443223C534A296A5CE" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_B77E2505AE308CAD1F62C534A2785796" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_0C3A531FC0B847CBC9F8C534A270B6F2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_B77E2505AE308CAD1F62C534A2785796" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_0C3A531FC0B847CBC9F8C534A270B6F2" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DF975E1E6A91ED97932DC534A2703143" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_0C3A531FC0B847CBC9F8C534A270B6F2" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DF975E1E6A91ED97932DC534A2703143" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DF975E1E6A91ED97932DC534A2703143" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DF975E1E6A91ED97932DC534A2703143" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_DF5518B5E9E507777F26C534A27622BB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3" xlink:to="loc_us-gaap_TrademarksMember_DF5518B5E9E507777F26C534A27622BB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CustomerRelatedIntangibleAssetsMember" xlink:label="loc_us-gaap_CustomerRelatedIntangibleAssetsMember_AC18D35A031F99F2CAA2C534A276D990" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3" xlink:to="loc_us-gaap_CustomerRelatedIntangibleAssetsMember_AC18D35A031F99F2CAA2C534A276D990" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PatentsMember" xlink:label="loc_us-gaap_PatentsMember_85F4AC4C0CA6F61FC977C534A277F691" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_BC66B38A7C3CB73159C6C534A27610B3" xlink:to="loc_us-gaap_PatentsMember_85F4AC4C0CA6F61FC977C534A277F691" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_09F6B0E5D0F9DC6D5884C534A2775366" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_0C3A531FC0B847CBC9F8C534A270B6F2" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_09F6B0E5D0F9DC6D5884C534A2775366" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_B9BAE15273E79E45CA27C534A2778C8D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_09F6B0E5D0F9DC6D5884C534A2775366" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_B9BAE15273E79E45CA27C534A2778C8D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_B9BAE15273E79E45CA27C534A2778C8D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_09F6B0E5D0F9DC6D5884C534A2775366" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_B9BAE15273E79E45CA27C534A2778C8D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_347A516D8DB9A4278060C534A277CE0C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_B9BAE15273E79E45CA27C534A2778C8D" xlink:to="loc_us-gaap_TrademarksMember_347A516D8DB9A4278060C534A277CE0C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsGross" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsGross_9D8406C084A4AD974BE0C534A278A821" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_B77E2505AE308CAD1F62C534A2785796" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsGross_9D8406C084A4AD974BE0C534A278A821" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_95F3E56A866CE36AF805C534A278DDF4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_B77E2505AE308CAD1F62C534A2785796" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_95F3E56A866CE36AF805C534A278DDF4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill_7E2E9C2FCC1F7FC54A2BC534A278482B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_B77E2505AE308CAD1F62C534A2785796" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill_7E2E9C2FCC1F7FC54A2BC534A278482B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_F8169FDBC729B03EE8CCC534A27984FE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_B77E2505AE308CAD1F62C534A2785796" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_F8169FDBC729B03EE8CCC534A27984FE" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeTaxContingencyLineItems" xlink:label="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeTaxContingencyTable" xlink:label="loc_us-gaap_IncomeTaxContingencyTable_BFBA8230FB1A8A407994CEA7BE8362F6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_IncomeTaxContingencyTable_BFBA8230FB1A8A407994CEA7BE8362F6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_CBDBEEA89BDBBFA5CC61CEA7BE8363DA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_BFBA8230FB1A8A407994CEA7BE8362F6" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_CBDBEEA89BDBBFA5CC61CEA7BE8363DA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_595873AD20ACA395B519CEA7BE84C3DF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_CBDBEEA89BDBBFA5CC61CEA7BE8363DA" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_595873AD20ACA395B519CEA7BE84C3DF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_595873AD20ACA395B519CEA7BE84C3DF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_CBDBEEA89BDBBFA5CC61CEA7BE8363DA" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_595873AD20ACA395B519CEA7BE84C3DF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpenseMember" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_AD3492D1D8C1E2BB643DCEA7BE846BED" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_595873AD20ACA395B519CEA7BE84C3DF" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_AD3492D1D8C1E2BB643DCEA7BE846BED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis" xlink:label="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_27D2E5C512D02A7F403CCEA7BE84D42C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_BFBA8230FB1A8A407994CEA7BE8362F6" xlink:to="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_27D2E5C512D02A7F403CCEA7BE84D42C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_EquityMethodInvesteeNameDomain" xlink:label="loc_srt_EquityMethodInvesteeNameDomain_C9C5049D59CEBBF4AB13CEA7BE8427FA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_27D2E5C512D02A7F403CCEA7BE84D42C" xlink:to="loc_srt_EquityMethodInvesteeNameDomain_C9C5049D59CEBBF4AB13CEA7BE8427FA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_EquityMethodInvesteeNameDomain" xlink:label="loc_srt_EquityMethodInvesteeNameDomain_C9C5049D59CEBBF4AB13CEA7BE8427FA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_27D2E5C512D02A7F403CCEA7BE84D42C" xlink:to="loc_srt_EquityMethodInvesteeNameDomain_C9C5049D59CEBBF4AB13CEA7BE8427FA" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PartnershipsQualifyingForTaxCreditsMember" xlink:label="loc_hsy_PartnershipsQualifyingForTaxCreditsMember_242602EE45A01D14AB3CCEA7BE859FA1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_EquityMethodInvesteeNameDomain_C9C5049D59CEBBF4AB13CEA7BE8427FA" xlink:to="loc_hsy_PartnershipsQualifyingForTaxCreditsMember_242602EE45A01D14AB3CCEA7BE859FA1" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit" xlink:label="loc_hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit_6AE7845CBF9B9727938FCEA7BE85BE76" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit_6AE7845CBF9B9727938FCEA7BE85BE76" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_TaxCutsandJobsActof2017MeasurementPeriodAdjustmentIncomeTaxExpenseBenefit" xlink:label="loc_hsy_TaxCutsandJobsActof2017MeasurementPeriodAdjustmentIncomeTaxExpenseBenefit_45E133842A3869D950C9CEA7BE85C9C5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_hsy_TaxCutsandJobsActof2017MeasurementPeriodAdjustmentIncomeTaxExpenseBenefit_45E133842A3869D950C9CEA7BE85C9C5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate_9B6DEEFF147EE21A1D97CEA7BE860095" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate_9B6DEEFF147EE21A1D97CEA7BE860095" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense_F3598E7DA561631E3AE2CEA7BE868E1F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense_F3598E7DA561631E3AE2CEA7BE868E1F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_FB36647B34922BB62F62CEA7BE8664F6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_FB36647B34922BB62F62CEA7BE8664F6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit" xlink:label="loc_us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit_9FC050556FC5B6592669CEA7BE8629B4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit_9FC050556FC5B6592669CEA7BE8629B4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UndistributedEarningsOfForeignSubsidiaries" xlink:label="loc_us-gaap_UndistributedEarningsOfForeignSubsidiaries_139CDD7F262E86ED7354CEA7BE8686F5" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_UndistributedEarningsOfForeignSubsidiaries_139CDD7F262E86ED7354CEA7BE8686F5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeTaxCreditsAndAdjustments" xlink:label="loc_us-gaap_IncomeTaxCreditsAndAdjustments_8FBE1A51D65518CC68C7CEA7BE87E13B" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_IncomeTaxCreditsAndAdjustments_8FBE1A51D65518CC68C7CEA7BE87E13B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_C11BE5236D67EFCB4ACACEA7BE878783" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_24A6838F9123BE357197CEA7BE859A84" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_C11BE5236D67EFCB4ACACEA7BE878783" 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/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/2018/elts/srt-2018-01-31.xsd#srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems" xlink:label="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable" xlink:label="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_A2E8C735B0B2C7D9B27AC5349FF8DAD5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:to="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_A2E8C735B0B2C7D9B27AC5349FF8DAD5" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C952882FB8D2ABC4850CC5349FF94867" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_A2E8C735B0B2C7D9B27AC5349FF8DAD5" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C952882FB8D2ABC4850CC5349FF94867" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_A5BDF2F5FB7DBD115543C5349FF90779_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C952882FB8D2ABC4850CC5349FF94867" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_A5BDF2F5FB7DBD115543C5349FF90779_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_A5BDF2F5FB7DBD115543C5349FF90779" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C952882FB8D2ABC4850CC5349FF94867" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_A5BDF2F5FB7DBD115543C5349FF90779" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_47AC0962C81344710F70C5349FFA2156" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_A2E8C735B0B2C7D9B27AC5349FF8DAD5" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_47AC0962C81344710F70C5349FFA2156" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_434713724EA799693A50C5349FFAF3A3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_47AC0962C81344710F70C5349FFA2156" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_434713724EA799693A50C5349FFAF3A3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_434713724EA799693A50C5349FFAF3A3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_47AC0962C81344710F70C5349FFA2156" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_434713724EA799693A50C5349FFAF3A3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member" xlink:label="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_6D7A9BAD22FDB5AA0C2CC5349FFA0452" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_434713724EA799693A50C5349FFAF3A3" xlink:to="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_6D7A9BAD22FDB5AA0C2CC5349FFA0452" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_337A9A3458ABBB356302C5349FFB22F3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_337A9A3458ABBB356302C5349FFB22F3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DefinedBenefitPlanNonServiceCost" xlink:label="loc_hsy_DefinedBenefitPlanNonServiceCost_DDBC53A05BE461A388FEC5349FFBCADD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:to="loc_hsy_DefinedBenefitPlanNonServiceCost_DDBC53A05BE461A388FEC5349FFBCADD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount" xlink:label="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_B9660E835A8A5C96CE29C5349FFB989A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:to="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_B9660E835A8A5C96CE29C5349FFB989A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_OtherNonoperatingGainLoss" xlink:label="loc_hsy_OtherNonoperatingGainLoss_7A773CBAD276E03EE664C5349FFB6AFC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:to="loc_hsy_OtherNonoperatingGainLoss_7A773CBAD276E03EE664C5349FFB6AFC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_D758110C03FAD161559AC5349FFC8E52" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_7AF8C048077855D7509DC5349FFB7F5F" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_D758110C03FAD161559AC5349FFC8E52" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_229BA9D7D9426D3A79B0C534A137B1E4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:to="loc_srt_RangeAxis_229BA9D7D9426D3A79B0C534A137B1E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_8DACD8C6D7C860D8E41AC534A1378165_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_229BA9D7D9426D3A79B0C534A137B1E4" xlink:to="loc_srt_RangeMember_8DACD8C6D7C860D8E41AC534A1378165_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_8DACD8C6D7C860D8E41AC534A1378165" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_229BA9D7D9426D3A79B0C534A137B1E4" xlink:to="loc_srt_RangeMember_8DACD8C6D7C860D8E41AC534A1378165" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_3524EBC60A1C365A44A1C534A1372658" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_8DACD8C6D7C860D8E41AC534A1378165" xlink:to="loc_srt_MinimumMember_3524EBC60A1C365A44A1C534A1372658" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_BA5E619DCB892F2860C1C534A1378F7B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_8DACD8C6D7C860D8E41AC534A1378165" xlink:to="loc_srt_MaximumMember_BA5E619DCB892F2860C1C534A1378F7B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_D906370A0DE7074AD7D3C534A1384BBE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_D906370A0DE7074AD7D3C534A1384BBE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_D906370A0DE7074AD7D3C534A1384BBE" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_D906370A0DE7074AD7D3C534A1384BBE" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_A2EC278E93BDC80B9152C534A13826B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_A2EC278E93BDC80B9152C534A13826B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SupplementalEmployeeRetirementPlanDefinedBenefitMember" xlink:label="loc_us-gaap_SupplementalEmployeeRetirementPlanDefinedBenefitMember_CB13479D6BF08DF12BC2C534A1397E92" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF" xlink:to="loc_us-gaap_SupplementalEmployeeRetirementPlanDefinedBenefitMember_CB13479D6BF08DF12BC2C534A1397E92" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_D56A728F13B65E29BB30C534A139C91A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_3898C8A6D641E557C0BAC534A13864AF" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_D56A728F13B65E29BB30C534A139C91A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_CDB44A8E42FF0F6344DAC534A13923F6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:to="loc_us-gaap_StatementScenarioAxis_CDB44A8E42FF0F6344DAC534A13923F6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_51F8BFA4E68EE2A110AFC534A139E525_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_CDB44A8E42FF0F6344DAC534A13923F6" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_51F8BFA4E68EE2A110AFC534A139E525_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_51F8BFA4E68EE2A110AFC534A139E525" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_CDB44A8E42FF0F6344DAC534A13923F6" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_51F8BFA4E68EE2A110AFC534A139E525" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_FE9F45E8CFD63F077845C534A13A86E3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_51F8BFA4E68EE2A110AFC534A139E525" xlink:to="loc_us-gaap_ScenarioForecastMember_FE9F45E8CFD63F077845C534A13A86E3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanFundingStatusAxis" xlink:label="loc_us-gaap_RetirementPlanFundingStatusAxis_C7E8CDF9CAFB8B53366CC534A13A98E9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:to="loc_us-gaap_RetirementPlanFundingStatusAxis_C7E8CDF9CAFB8B53366CC534A13A98E9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanFundingStatusDomain" xlink:label="loc_us-gaap_RetirementPlanFundingStatusDomain_6ED55762D25415511861C534A13A47C0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanFundingStatusAxis_C7E8CDF9CAFB8B53366CC534A13A98E9" xlink:to="loc_us-gaap_RetirementPlanFundingStatusDomain_6ED55762D25415511861C534A13A47C0_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanFundingStatusDomain" xlink:label="loc_us-gaap_RetirementPlanFundingStatusDomain_6ED55762D25415511861C534A13A47C0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanFundingStatusAxis_C7E8CDF9CAFB8B53366CC534A13A98E9" xlink:to="loc_us-gaap_RetirementPlanFundingStatusDomain_6ED55762D25415511861C534A13A47C0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UnfundedPlanMember" xlink:label="loc_us-gaap_UnfundedPlanMember_B9A3C4E2D75CFEC9DB3BC534A13A2F9C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanFundingStatusDomain_6ED55762D25415511861C534A13A47C0" xlink:to="loc_us-gaap_UnfundedPlanMember_B9A3C4E2D75CFEC9DB3BC534A13A2F9C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanNameAxis" xlink:label="loc_us-gaap_RetirementPlanNameAxis_D2051E9E4E4D9E675968C534A13B2C82" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D9749052E6949F6C3894C534A136DF22" xlink:to="loc_us-gaap_RetirementPlanNameAxis_D2051E9E4E4D9E675968C534A13B2C82" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanNameDomain" xlink:label="loc_us-gaap_RetirementPlanNameDomain_91DC0B0DDCDA2BC752C7C534A13BD318_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanNameAxis_D2051E9E4E4D9E675968C534A13B2C82" xlink:to="loc_us-gaap_RetirementPlanNameDomain_91DC0B0DDCDA2BC752C7C534A13BD318_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanNameDomain" xlink:label="loc_us-gaap_RetirementPlanNameDomain_91DC0B0DDCDA2BC752C7C534A13BD318" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanNameAxis_D2051E9E4E4D9E675968C534A13B2C82" xlink:to="loc_us-gaap_RetirementPlanNameDomain_91DC0B0DDCDA2BC752C7C534A13BD318" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCompanyPuertoRicoHourlyPensionPlanMember" xlink:label="loc_hsy_HersheyCompanyPuertoRicoHourlyPensionPlanMember_93A42E36D7D0C5EB3713C534A13B909C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanNameDomain_91DC0B0DDCDA2BC752C7C534A13BD318" xlink:to="loc_hsy_HersheyCompanyPuertoRicoHourlyPensionPlanMember_93A42E36D7D0C5EB3713C534A13B909C" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans" xlink:label="loc_hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans_6E309245218CB7B11E7DC534A13C65FC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans_6E309245218CB7B11E7DC534A13C65FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation_4748E536573FD5C59942C534A13CFF35" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation_4748E536573FD5C59942C534A13CFF35" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear_965A44A13E79ADCE3923C534A13CDE85" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear_965A44A13E79ADCE3923C534A13CDE85" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1" xlink:label="loc_us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1_0AFD7C17335AB6D5DF95C534A13CE41C" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1_0AFD7C17335AB6D5DF95C534A13CE41C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanContributionsByEmployer" xlink:label="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_04F27AD7B0AF41FC8061C534A13C4DB2" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_04F27AD7B0AF41FC8061C534A13C4DB2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear" xlink:label="loc_hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear_CCBC8B473BC3095A4E18C534A13C39AA" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear_CCBC8B473BC3095A4E18C534A13C39AA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedContributionPlanCostRecognized" xlink:label="loc_us-gaap_DefinedContributionPlanCostRecognized_73B2157FBD371E38AA2FC534A13DC42E" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_44EDD6E013F2EDEAAB2EC534A13BD477" xlink:to="loc_us-gaap_DefinedContributionPlanCostRecognized_73B2157FBD371E38AA2FC534A13DC42E" 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/PensionAndOtherPostRetirementBenefitPlansScheduleOfAmountsExpectedToBeAmortizedFromAociIntoNetPeriodicBenefitDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_59C77220CDB562B295BCC534A10D9B32" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_49DAD347AFEDE1DC02A0C534A10B2A3A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_59C77220CDB562B295BCC534A10D9B32" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_49DAD347AFEDE1DC02A0C534A10B2A3A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_46FBA2C7BE31178FF16FC534A10CFC83" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_49DAD347AFEDE1DC02A0C534A10B2A3A" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_46FBA2C7BE31178FF16FC534A10CFC83" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_BE597B96A3893E4F9160C534A10C4F6E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_46FBA2C7BE31178FF16FC534A10CFC83" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_BE597B96A3893E4F9160C534A10C4F6E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_BE597B96A3893E4F9160C534A10C4F6E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_46FBA2C7BE31178FF16FC534A10CFC83" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_BE597B96A3893E4F9160C534A10C4F6E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_87AE0F52A71B79E86E6AC534A10C6250" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_BE597B96A3893E4F9160C534A10C4F6E" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_87AE0F52A71B79E86E6AC534A10C6250" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_0200AF978E315C95EB2DC534A10C853C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_BE597B96A3893E4F9160C534A10C4F6E" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_0200AF978E315C95EB2DC534A10C853C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedAmortizationOfGainLossNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfGainLossNextFiscalYear_8556DCA1AC0AFD36A1E0C534A10DAD92" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_59C77220CDB562B295BCC534A10D9B32" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfGainLossNextFiscalYear_8556DCA1AC0AFD36A1E0C534A10DAD92" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedAmortizationOfPriorServiceCostCreditNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfPriorServiceCostCreditNextFiscalYear_CB9B562B834643D0941EC534A10D016C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_59C77220CDB562B295BCC534A10D9B32" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfPriorServiceCostCreditNextFiscalYear_CB9B562B834643D0941EC534A10D016C" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_18C18F561C5E3AAFE555C534A11612D2" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_2F3AE8004256100F05ACC534A114CF17" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_18C18F561C5E3AAFE555C534A11612D2" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_2F3AE8004256100F05ACC534A114CF17" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_FD519724CD898A1BF909C534A115E5EB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_2F3AE8004256100F05ACC534A114CF17" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_FD519724CD898A1BF909C534A115E5EB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_695C552D871CDACC5F58C534A1152BC5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_FD519724CD898A1BF909C534A115E5EB" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_695C552D871CDACC5F58C534A1152BC5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_695C552D871CDACC5F58C534A1152BC5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_FD519724CD898A1BF909C534A115E5EB" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_695C552D871CDACC5F58C534A1152BC5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_D3861975DCA64B4387DBC534A1158F49" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_695C552D871CDACC5F58C534A1152BC5" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_D3861975DCA64B4387DBC534A1158F49" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_411D07979D9C9F2B2883C534A115C754" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_695C552D871CDACC5F58C534A1152BC5" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_411D07979D9C9F2B2883C534A115C754" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_18C18F561C5E3AAFE555C534A11612D2" xlink:to="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanServiceCost" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_07BE6D971A36945E9890C534A116F5FB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_07BE6D971A36945E9890C534A116F5FB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanInterestCost" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_659932BCD41A8CE92AD7C534A116078F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_659932BCD41A8CE92AD7C534A116078F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_9F906EFD72AD24B9787EC534A1161245" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_9F906EFD72AD24B9787EC534A1161245" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_05599BA4985CC6505F7CC534A11705D4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_05599BA4985CC6505F7CC534A11705D4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_2E30BE78DEF1548CBFEBC534A117862C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_2E30BE78DEF1548CBFEBC534A117862C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments_9556713EABA5F52F1F3DC534A1170500" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments_9556713EABA5F52F1F3DC534A1170500" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_BE1D397C29DF5BC574EEC534A117316B" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_BE1D397C29DF5BC574EEC534A117316B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_A7B5A64F464746438C68C534A117C7A8" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_6CB8297091C8AE4146E4C534A116CBF1" xlink:to="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_A7B5A64F464746438C68C534A117C7A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_F3BD3189DC48B71BD418C534A118BBD8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_18C18F561C5E3AAFE555C534A11612D2" xlink:to="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_F3BD3189DC48B71BD418C534A118BBD8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax_DA8E52B545C7EBB3AD95C534A1180DE4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_F3BD3189DC48B71BD418C534A118BBD8" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax_DA8E52B545C7EBB3AD95C534A1180DE4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax_7768380163B24A2B62F2C534A118333F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_F3BD3189DC48B71BD418C534A118BBD8" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax_7768380163B24A2B62F2C534A118333F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax_1DC27FA728121C52D267C534A1194C74" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_F3BD3189DC48B71BD418C534A118BBD8" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax_1DC27FA728121C52D267C534A1194C74" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax" xlink:label="loc_us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax_D234AD388F29B7D7D5CAC534A1198EB5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_18C18F561C5E3AAFE555C534A11612D2" xlink:to="loc_us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax_D234AD388F29B7D7D5CAC534A1198EB5" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_8F8B98E705E9397EE083DCBA07B7AABD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_8F8B98E705E9397EE083DCBA07B7AABD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_A6387D3A501E899EC1CEDCBA07B8E06E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_8F8B98E705E9397EE083DCBA07B7AABD" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_A6387D3A501E899EC1CEDCBA07B8E06E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_A922D6B04FC82C803DA6DCBA07B81EFC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_A6387D3A501E899EC1CEDCBA07B8E06E" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_A922D6B04FC82C803DA6DCBA07B81EFC_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_A922D6B04FC82C803DA6DCBA07B81EFC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_A6387D3A501E899EC1CEDCBA07B8E06E" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_A922D6B04FC82C803DA6DCBA07B81EFC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_8B9D92C785EFC198E39CDCBA07B873A9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_A922D6B04FC82C803DA6DCBA07B81EFC" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_8B9D92C785EFC198E39CDCBA07B873A9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_3679AE9ECB3003BBF43DDCBA07B99537" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_A922D6B04FC82C803DA6DCBA07B81EFC" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_3679AE9ECB3003BBF43DDCBA07B99537" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward" xlink:label="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:to="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanBenefitObligation_A527831554891648663ADCBA07BED87B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanBenefitObligation_A527831554891648663ADCBA07BED87B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanServiceCost" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_C50BC40E611C7CE72D42DCBA07BF8CAE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_C50BC40E611C7CE72D42DCBA07BF8CAE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanInterestCost" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_80CD284101A205A44AEBDCBA07BFEF38" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_80CD284101A205A44AEBDCBA07BFEF38" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAmendments" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAmendments_68FE473CB857B626E515DCBA07BFD121" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAmendments_68FE473CB857B626E515DCBA07BFD121" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanActuarialGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_D81CB4870D307241FDF9DCBA07BF3D5E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_D81CB4870D307241FDF9DCBA07BF3D5E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanCurtailments" xlink:label="loc_us-gaap_DefinedBenefitPlanCurtailments_AA25953000405FD9066DDCBA07BF5A13" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanCurtailments_AA25953000405FD9066DDCBA07BF5A13" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanSettlementsBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanSettlementsBenefitObligation_147CDC70829D7ACA186BDCBA07C0B066" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanSettlementsBenefitObligation_147CDC70829D7ACA186BDCBA07C0B066" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation_0521FCA29F9A3C47F2ABDCBA07C0D99D" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation_0521FCA29F9A3C47F2ABDCBA07C0D99D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid" xlink:label="loc_us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid_42EB71774D48D48E96F4DCBA07C015D0" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_B160600D7A58A634180DDCBA07BE0F7B" xlink:to="loc_us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid_42EB71774D48D48E96F4DCBA07C015D0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward" xlink:label="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:to="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanFairValueOfPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_AED648C817E881DFB359DCBA07C0B308" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:to="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_AED648C817E881DFB359DCBA07C0B308" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets_44059A65307FCF0DB8E4DCBA07C19EB1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:to="loc_us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets_44059A65307FCF0DB8E4DCBA07C19EB1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanContributionsByEmployer" xlink:label="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_94E76455E540EE0B9781DCBA07C1B41B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:to="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_94E76455E540EE0B9781DCBA07C1B41B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanSettlementsPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanSettlementsPlanAssets_594EAE64637EE7C6518DDCBA07C1CB52" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:to="loc_us-gaap_DefinedBenefitPlanSettlementsPlanAssets_594EAE64637EE7C6518DDCBA07C1CB52" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss_8461E5FC11AA03F6BCC1DCBA07C15F61" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss_8461E5FC11AA03F6BCC1DCBA07C15F61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid_60B076520AFA1F88D32FDCBA07C1BBAD" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_345101CCF6C0BC392930DCBA07C08209" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid_60B076520AFA1F88D32FDCBA07C1BBAD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanFundedStatusOfPlan" xlink:label="loc_us-gaap_DefinedBenefitPlanFundedStatusOfPlan_C767EFC4CB3F4BAB4209DCBA07C200F2" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:to="loc_us-gaap_DefinedBenefitPlanFundedStatusOfPlan_C767EFC4CB3F4BAB4209DCBA07C200F2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_047A3916FA1F727F75CCDCBA07C2A353" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_047A3916FA1F727F75CCDCBA07C2A353" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent" xlink:label="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_1C52D58CDE9BE297D4A4DCBA07C25BF9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_047A3916FA1F727F75CCDCBA07C2A353" xlink:to="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_1C52D58CDE9BE297D4A4DCBA07C25BF9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities" xlink:label="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities_FABFF0808EBB81ADCFCFDCBA07C2000A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_047A3916FA1F727F75CCDCBA07C2A353" xlink:to="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities_FABFF0808EBB81ADCFCFDCBA07C2000A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent" xlink:label="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent_7E26FFCD0203897B5C25DCBA07C3C4B3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_047A3916FA1F727F75CCDCBA07C2A353" xlink:to="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent_7E26FFCD0203897B5C25DCBA07C3C4B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet_16688906288F183CAB99DCBA07C38E9B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_047A3916FA1F727F75CCDCBA07C2A353" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet_16688906288F183CAB99DCBA07C38E9B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B290566479DBC86CDB5BDCBA07C3B314" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D012EAE75018DB7F64B3DCBA07B9CCFC" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B290566479DBC86CDB5BDCBA07C3B314" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax_B27868A15D2091F46FCBDCBA07C3969E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B290566479DBC86CDB5BDCBA07C3B314" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax_B27868A15D2091F46FCBDCBA07C3969E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax_D2F5914548E228C38747DCBA07C308E7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B290566479DBC86CDB5BDCBA07C3B314" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax_D2F5914548E228C38747DCBA07C308E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_3F43D674CC62047C564DDCBA07C4AF4D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B290566479DBC86CDB5BDCBA07C3B314" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_3F43D674CC62047C564DDCBA07C4AF4D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfEffectOfOnePercentChangeInAssumedHealthCareTrendRatesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_DEFA21ADBEA1335D11A1C534A0DA4808" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_DEFA21ADBEA1335D11A1C534A0DA4808" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_2F4D8B9513AD480BDA40C534A0DAC258" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_DEFA21ADBEA1335D11A1C534A0DA4808" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_2F4D8B9513AD480BDA40C534A0DAC258" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_E25AA178437F40B23C18C534A0DB43DA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_2F4D8B9513AD480BDA40C534A0DAC258" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_E25AA178437F40B23C18C534A0DB43DA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_E25AA178437F40B23C18C534A0DB43DA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_2F4D8B9513AD480BDA40C534A0DAC258" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_E25AA178437F40B23C18C534A0DB43DA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_2A05A5CC15C622CF92ADC534A0DB298D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_E25AA178437F40B23C18C534A0DB43DA" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_2A05A5CC15C622CF92ADC534A0DB298D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_FD64BAF79B2C9EA3C2F1C534A0DC7AB2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_E25AA178437F40B23C18C534A0DB43DA" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_FD64BAF79B2C9EA3C2F1C534A0DC7AB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths_0E60CAECA0E62F881D09C534A0DC85B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths_0E60CAECA0E62F881D09C534A0DC85B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo_00C6EB068484BB847B45C534A0DD5C22" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo_00C6EB068484BB847B45C534A0DD5C22" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree_BC7D3ECE3155F5E33709C534A0DDEFB5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree_BC7D3ECE3155F5E33709C534A0DDEFB5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour_BDE43278846C652614A8C534A0DD45BA" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour_BDE43278846C652614A8C534A0DD45BA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive_28B011275C686B8ADA17C534A0DD917C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive_28B011275C686B8ADA17C534A0DD917C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter_DA5FC7175C475EBF069BC534A0DDE572" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_81541CD0C58AAD8C4126C534A0DC3224" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter_DA5FC7175C475EBF069BC534A0DDE572" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8C4C9DF49EB6F892945CC534A0EAE543" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AA249FB46F322E4EF7FAC534A0E4C190" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8C4C9DF49EB6F892945CC534A0EAE543" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AA249FB46F322E4EF7FAC534A0E4C190" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_B2826312A7291DF0ABC3C534A0E55CBA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AA249FB46F322E4EF7FAC534A0E4C190" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_B2826312A7291DF0ABC3C534A0E55CBA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_9E14DBC8EF3ACEF4366BC534A0E59F06_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_B2826312A7291DF0ABC3C534A0E55CBA" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_9E14DBC8EF3ACEF4366BC534A0E59F06_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_9E14DBC8EF3ACEF4366BC534A0E59F06" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_B2826312A7291DF0ABC3C534A0E55CBA" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_9E14DBC8EF3ACEF4366BC534A0E59F06" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_4356A118E0C52EF1BBE7C534A0E58E99" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_9E14DBC8EF3ACEF4366BC534A0E59F06" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_4356A118E0C52EF1BBE7C534A0E58E99" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_751AEC2186047107DC46C534A0E67C2D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AA249FB46F322E4EF7FAC534A0E4C190" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_751AEC2186047107DC46C534A0E67C2D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_661B27806E8941987DAFC534A0E61407_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_751AEC2186047107DC46C534A0E67C2D" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_661B27806E8941987DAFC534A0E61407_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_661B27806E8941987DAFC534A0E61407" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_751AEC2186047107DC46C534A0E67C2D" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_661B27806E8941987DAFC534A0E61407" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_DC181BFA766617EC8B35C534A0E6B405" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_661B27806E8941987DAFC534A0E61407" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_DC181BFA766617EC8B35C534A0E6B405" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis" xlink:label="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_C45FC665282F9833535FC534A0E6F223" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AA249FB46F322E4EF7FAC534A0E4C190" xlink:to="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_C45FC665282F9833535FC534A0E6F223" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_C45FC665282F9833535FC534A0E6F223" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_C45FC665282F9833535FC534A0E6F223" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashAndCashEquivalentsMember" xlink:label="loc_us-gaap_CashAndCashEquivalentsMember_573589777A7C27E75381C534A0E7EF0F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_us-gaap_CashAndCashEquivalentsMember_573589777A7C27E75381C534A0E7EF0F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_GlobalAllCapMember" xlink:label="loc_hsy_GlobalAllCapMember_FF683D957BBF89375E4CC534A0E70E9B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_hsy_GlobalAllCapMember_FF683D957BBF89375E4CC534A0E70E9B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_USTreasuryAndGovernmentMember" xlink:label="loc_us-gaap_USTreasuryAndGovernmentMember_039252954D0C72E811FDC534A0E756DE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_us-gaap_USTreasuryAndGovernmentMember_039252954D0C72E811FDC534A0E756DE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CorporateBondSecuritiesMember" xlink:label="loc_us-gaap_CorporateBondSecuritiesMember_F782BDE64BF0224728F1C534A0E79027" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_us-gaap_CorporateBondSecuritiesMember_F782BDE64BF0224728F1C534A0E79027" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CollateralizedDebtObligationsMember" xlink:label="loc_us-gaap_CollateralizedDebtObligationsMember_C45286924A6B488450DBC534A0E81C1E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_us-gaap_CollateralizedDebtObligationsMember_C45286924A6B488450DBC534A0E81C1E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ForeignGovernmentDebtSecuritiesMember" xlink:label="loc_us-gaap_ForeignGovernmentDebtSecuritiesMember_80785E0D5A90B6AB88A8C534A0E82332" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_us-gaap_ForeignGovernmentDebtSecuritiesMember_80785E0D5A90B6AB88A8C534A0E82332" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DiversifiedcreditMember" xlink:label="loc_hsy_DiversifiedcreditMember_624BE30A751E3AD0F720C534A0E8CA32" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_hsy_DiversifiedcreditMember_624BE30A751E3AD0F720C534A0E8CA32" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_GlobaldiversifiedassetsMember" xlink:label="loc_hsy_GlobaldiversifiedassetsMember_70CF04736CEFF4DC5833C534A0E87682" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_hsy_GlobaldiversifiedassetsMember_70CF04736CEFF4DC5833C534A0E87682" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_GlobalrealestateinvestmenttrustsMember" xlink:label="loc_hsy_GlobalrealestateinvestmenttrustsMember_728920608547373B8CB2C534A0E9471E" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_hsy_GlobalrealestateinvestmenttrustsMember_728920608547373B8CB2C534A0E9471E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_GlobalinfrastructureMember" xlink:label="loc_hsy_GlobalinfrastructureMember_BD1AE5B20033E0D2D9A8C534A0E919DF" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_3D4E4BF43DA174988EC4C534A0E732E7" xlink:to="loc_hsy_GlobalinfrastructureMember_BD1AE5B20033E0D2D9A8C534A0E919DF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_57AA5A2A9381D87FD576C534A0E97DD5" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_AA249FB46F322E4EF7FAC534A0E4C190" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_57AA5A2A9381D87FD576C534A0E97DD5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_57AA5A2A9381D87FD576C534A0E97DD5" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_57AA5A2A9381D87FD576C534A0E97DD5" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel1Member" xlink:label="loc_us-gaap_FairValueInputsLevel1Member_136EC3CE662C910B2EBDC534A0E9DE4F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_136EC3CE662C910B2EBDC534A0E9DE4F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_1ED4B14D08C6C378BC74C534A0EA8780" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_1ED4B14D08C6C378BC74C534A0EA8780" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_4877B35C2C81548F7388C534A0EA9AA1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_2DAE4E978472A3535360C534A0E9E966" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_4877B35C2C81548F7388C534A0EA9AA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanFairValueOfPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_C614E561E45AC1E50E49C534A0EAB554" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8C4C9DF49EB6F892945CC534A0EAE543" xlink:to="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_C614E561E45AC1E50E49C534A0EAB554" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue" xlink:label="loc_hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue_EE5C59BAE7EF4B4EF5A8C534A0EA74F3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_8C4C9DF49EB6F892945CC534A0EAE543" xlink:to="loc_hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue_EE5C59BAE7EF4B4EF5A8C534A0EA74F3" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_63D988C543D0FDD3D4A4C534A0F36D98" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D83CD1E71F6CA4EDD262C534A0F00B4D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_63D988C543D0FDD3D4A4C534A0F36D98" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D83CD1E71F6CA4EDD262C534A0F00B4D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_92B88D4F1D323127533BC534A0F1A455" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D83CD1E71F6CA4EDD262C534A0F00B4D" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_92B88D4F1D323127533BC534A0F1A455" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_986F811A4569B7A4AEE6C534A0F1534D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_92B88D4F1D323127533BC534A0F1A455" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_986F811A4569B7A4AEE6C534A0F1534D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_986F811A4569B7A4AEE6C534A0F1534D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_92B88D4F1D323127533BC534A0F1A455" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_986F811A4569B7A4AEE6C534A0F1534D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DomesticPlanMember" xlink:label="loc_us-gaap_DomesticPlanMember_7E682ECCDC70DECCBE44C534A0F14684" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_986F811A4569B7A4AEE6C534A0F1534D" xlink:to="loc_us-gaap_DomesticPlanMember_7E682ECCDC70DECCBE44C534A0F14684" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis" xlink:label="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_A9D6C4A8549B290B531FC534A0F2A615" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D83CD1E71F6CA4EDD262C534A0F00B4D" xlink:to="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_A9D6C4A8549B290B531FC534A0F2A615" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_A9D6C4A8549B290B531FC534A0F2A615" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_A9D6C4A8549B290B531FC534A0F2A615" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CashAndCashEquivalentsMember" xlink:label="loc_us-gaap_CashAndCashEquivalentsMember_E12C91112391AA0A57A2C534A0F28951" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914" xlink:to="loc_us-gaap_CashAndCashEquivalentsMember_E12C91112391AA0A57A2C534A0F28951" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquitySecuritiesMember" xlink:label="loc_us-gaap_EquitySecuritiesMember_E91CDB42DEF5CFA6402DC534A0F29283" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914" xlink:to="loc_us-gaap_EquitySecuritiesMember_E91CDB42DEF5CFA6402DC534A0F29283" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtSecuritiesMember" xlink:label="loc_us-gaap_DebtSecuritiesMember_74CB088085917513AA2AC534A0F30C2C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914" xlink:to="loc_us-gaap_DebtSecuritiesMember_74CB088085917513AA2AC534A0F30C2C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherInvestmentsMember" xlink:label="loc_us-gaap_OtherInvestmentsMember_E33D0E58245DF6D8DBB1C534A0F3992A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_959C7EB59318EAED7572C534A0F23914" xlink:to="loc_us-gaap_OtherInvestmentsMember_E33D0E58245DF6D8DBB1C534A0F3992A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage_A8CE1F76F10B3656F05AC534A0F31087" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_63D988C543D0FDD3D4A4C534A0F36D98" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage_A8CE1F76F10B3656F05AC534A0F31087" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0EE34348C2A254D7261FC534A105FDB1" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_4C3765B750965DB285BBC534A104BD9C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0EE34348C2A254D7261FC534A105FDB1" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_4C3765B750965DB285BBC534A104BD9C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_2FB3637AF231D8944F25C534A1048B02" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_4C3765B750965DB285BBC534A104BD9C" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_2FB3637AF231D8944F25C534A1048B02" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_31A89CF340791FD76FC9C534A1050B21_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_2FB3637AF231D8944F25C534A1048B02" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_31A89CF340791FD76FC9C534A1050B21_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_31A89CF340791FD76FC9C534A1050B21" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_2FB3637AF231D8944F25C534A1048B02" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_31A89CF340791FD76FC9C534A1050B21" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_B0F95BC5C7C651487BA4C534A105678A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_31A89CF340791FD76FC9C534A1050B21" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_B0F95BC5C7C651487BA4C534A105678A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_A5804BC7F132B78F05F0C534A105F73D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_31A89CF340791FD76FC9C534A1050B21" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_A5804BC7F132B78F05F0C534A105F73D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_5FBEE6F2C1C7AC539C8FC534A1059F15" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0EE34348C2A254D7261FC534A105FDB1" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_5FBEE6F2C1C7AC539C8FC534A1059F15" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease_D5352548D5C4AEC8C2A3C534A106E3A2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_0EE34348C2A254D7261FC534A105FDB1" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease_D5352548D5C4AEC8C2A3C534A106E3A2" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_2781CEB7788068250D0CC534A1004F07" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_63B63573BD9644695DA0C534A0FEA101" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_2781CEB7788068250D0CC534A1004F07" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_63B63573BD9644695DA0C534A0FEA101" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_64551E2CAFF7CFCE887EC534A0FE3E36" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_63B63573BD9644695DA0C534A0FEA101" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_64551E2CAFF7CFCE887EC534A0FE3E36" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_2FB0DBF645CC822849F1C534A0FF2F8E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_64551E2CAFF7CFCE887EC534A0FE3E36" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_2FB0DBF645CC822849F1C534A0FF2F8E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_2FB0DBF645CC822849F1C534A0FF2F8E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_64551E2CAFF7CFCE887EC534A0FE3E36" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_2FB0DBF645CC822849F1C534A0FF2F8E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_B38A0E135284ACF1DABDC534A0FF8150" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_2FB0DBF645CC822849F1C534A0FF2F8E" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_B38A0E135284ACF1DABDC534A0FF8150" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_C9B2798B273DE3B6C622C534A0FF9C80" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_2FB0DBF645CC822849F1C534A0FF2F8E" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_C9B2798B273DE3B6C622C534A0FF9C80" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate_8881A8EEE26E841447AAC534A100C9E2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_2781CEB7788068250D0CC534A1004F07" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate_8881A8EEE26E841447AAC534A100C9E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets_1F6EB3584D3503E3EAFEC534A1003FAB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_2781CEB7788068250D0CC534A1004F07" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets_1F6EB3584D3503E3EAFEC534A1003FAB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease_47A67CA0F70ABB1BD464C534A100F96E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_2781CEB7788068250D0CC534A1004F07" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease_47A67CA0F70ABB1BD464C534A100F96E" 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/ScheduleIiValuationAndQualifyingAccountsScheduleIiValuationAndQualifyingAccounts" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureLineItems" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_50ED82D8D7619FA7E826DCEB40E32FEA" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureTable" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_693A10214CA7F65840F7DCEB40E2FF12" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_50ED82D8D7619FA7E826DCEB40E32FEA" xlink:to="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_693A10214CA7F65840F7DCEB40E2FF12" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesTypeAxis" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_9AB9080E59B7AD5D4A40DCEB40E22270" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_693A10214CA7F65840F7DCEB40E2FF12" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_9AB9080E59B7AD5D4A40DCEB40E22270" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_05632787FB8E2A06C7B9DCEB40E33A77_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_9AB9080E59B7AD5D4A40DCEB40E22270" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_05632787FB8E2A06C7B9DCEB40E33A77_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_05632787FB8E2A06C7B9DCEB40E33A77" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_9AB9080E59B7AD5D4A40DCEB40E22270" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_05632787FB8E2A06C7B9DCEB40E33A77" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ScheduleOfValuationAndQualifyingAccountsDisclosureTextBlock" xlink:label="loc_srt_ScheduleOfValuationAndQualifyingAccountsDisclosureTextBlock_C1003E18C453E0A7E8E1DCEB40E3CDAB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_50ED82D8D7619FA7E826DCEB40E32FEA" xlink:to="loc_srt_ScheduleOfValuationAndQualifyingAccountsDisclosureTextBlock_C1003E18C453E0A7E8E1DCEB40E3CDAB" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsScheduleIiValuationAndQualifyingAccountsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureLineItems" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_BC718B61A24C1469A0ADDCEB40D32506" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ValuationAndQualifyingAccountsDisclosureTable" xlink:label="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_28E881F0812EB4E79CC1DCEB40CC70D9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_BC718B61A24C1469A0ADDCEB40D32506" xlink:to="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_28E881F0812EB4E79CC1DCEB40CC70D9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesTypeAxis" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_37CE0EFD4C009C7CE6E1DCEB40D19D1A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureTable_28E881F0812EB4E79CC1DCEB40CC70D9" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_37CE0EFD4C009C7CE6E1DCEB40D19D1A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_37CE0EFD4C009C7CE6E1DCEB40D19D1A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_37CE0EFD4C009C7CE6E1DCEB40D19D1A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AllowanceForCreditLossMember" xlink:label="loc_us-gaap_AllowanceForCreditLossMember_F2BAEC593C021C885775DCEB40D2DB10" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D" xlink:to="loc_us-gaap_AllowanceForCreditLossMember_F2BAEC593C021C885775DCEB40D2DB10" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember" xlink:label="loc_us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember_5FCC7DB5703C9BB3696BDCEB40D25EB2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D" xlink:to="loc_us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember_5FCC7DB5703C9BB3696BDCEB40D25EB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InventoryValuationReserveMember" xlink:label="loc_us-gaap_InventoryValuationReserveMember_C75D48B3B210B248DDE3DCEB40D21B8A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_0B224C6275693A8A5357DCEB40D1CA1D" xlink:to="loc_us-gaap_InventoryValuationReserveMember_C75D48B3B210B248DDE3DCEB40D21B8A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesBalance" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesBalance_1DFE7F7E01C3323EF2AFDCEB40D36508" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_BC718B61A24C1469A0ADDCEB40D32506" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesBalance_1DFE7F7E01C3323EF2AFDCEB40D36508" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense_05AE4CD52478BBF67011DCEB40D388B1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_BC718B61A24C1469A0ADDCEB40D32506" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense_05AE4CD52478BBF67011DCEB40D388B1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts_B946EADB73CFC4828C3CDCEB40D3868B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_BC718B61A24C1469A0ADDCEB40D32506" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts_B946EADB73CFC4828C3CDCEB40D3868B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDeductions" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDeductions_8A435ACA85FAA7B551ABDCEB40D3B57F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ValuationAndQualifyingAccountsDisclosureLineItems_BC718B61A24C1469A0ADDCEB40D32506" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDeductions_8A435ACA85FAA7B551ABDCEB40D3B57F" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareBasicLineItems" xlink:label="loc_us-gaap_EarningsPerShareBasicLineItems_9056DDEF7306541ACA76C534A00F4014" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable" xlink:label="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_30809DF099DA4288F669C534A00DCDB7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_9056DDEF7306541ACA76C534A00F4014" xlink:to="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_30809DF099DA4288F669C534A00DCDB7" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_996A53E5472E09184C2CC534A00D955C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_30809DF099DA4288F669C534A00DCDB7" xlink:to="loc_us-gaap_StatementClassOfStockAxis_996A53E5472E09184C2CC534A00D955C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_25305FD16382F8A5F551C534A00E9229_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_996A53E5472E09184C2CC534A00D955C" xlink:to="loc_us-gaap_ClassOfStockDomain_25305FD16382F8A5F551C534A00E9229_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_25305FD16382F8A5F551C534A00E9229" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_996A53E5472E09184C2CC534A00D955C" xlink:to="loc_us-gaap_ClassOfStockDomain_25305FD16382F8A5F551C534A00E9229" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_AA6A679E03BF73281F84C534A00EADE1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_25305FD16382F8A5F551C534A00E9229" xlink:to="loc_hsy_HersheyCommonStockMember_AA6A679E03BF73281F84C534A00EADE1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_E4033750AEA33689D38DC534A00E7CF4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_25305FD16382F8A5F551C534A00E9229" xlink:to="loc_us-gaap_CommonClassBMember_E4033750AEA33689D38DC534A00E7CF4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_05F279DB887B913313E8C534A00E2F46" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_30809DF099DA4288F669C534A00DCDB7" xlink:to="loc_us-gaap_AwardTypeAxis_05F279DB887B913313E8C534A00E2F46" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_78914EF1B59EE4A143D2C534A00FF4FA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_05F279DB887B913313E8C534A00E2F46" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_78914EF1B59EE4A143D2C534A00FF4FA_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_78914EF1B59EE4A143D2C534A00FF4FA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_05F279DB887B913313E8C534A00E2F46" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_78914EF1B59EE4A143D2C534A00FF4FA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_5EA00330D19D22146841C534A00F66E4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_78914EF1B59EE4A143D2C534A00FF4FA" xlink:to="loc_us-gaap_EmployeeStockOptionMember_5EA00330D19D22146841C534A00F66E4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_BB9889AAD0DB0AB7778AC534A00F6843" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_78914EF1B59EE4A143D2C534A00FF4FA" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_BB9889AAD0DB0AB7778AC534A00F6843" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareBasicTwoClassMethodAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_9056DDEF7306541ACA76C534A00F4014" xlink:to="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Dividends" xlink:label="loc_us-gaap_Dividends_66201F3D793425AD1E71C534A0108C27" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:to="loc_us-gaap_Dividends_66201F3D793425AD1E71C534A0108C27" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_61DBF7E27788CBF6E2FDC534A010E81E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_61DBF7E27788CBF6E2FDC534A010E81E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_1965EE80E37B43C8C366C534A01067E9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_1965EE80E37B43C8C366C534A01067E9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingBasic" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_C85123DA70B7BC52A886C534A0105CEB" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_C85123DA70B7BC52A886C534A0105CEB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_69D5C847457B8C4B3456C534A01130F3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_9056F0D60B2274CDB8A2C534A00F8120" xlink:to="loc_us-gaap_EarningsPerShareBasic_69D5C847457B8C4B3456C534A01130F3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract" xlink:label="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_9056DDEF7306541ACA76C534A00F4014" xlink:to="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DistributedEarnings" xlink:label="loc_us-gaap_DistributedEarnings_DBF2C5548650142D0ED4C534A011A94E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_us-gaap_DistributedEarnings_DBF2C5548650142D0ED4C534A011A94E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_6D292EB94C8CA7B36553C534A0116916" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_6D292EB94C8CA7B36553C534A0116916" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_795C9BA3E8D0650EF27EC534A012B14E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_795C9BA3E8D0650EF27EC534A012B14E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock" xlink:label="loc_hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock_78B812578DBBDB367815C534A0124864" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock_78B812578DBBDB367815C534A0124864" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements" xlink:label="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_9620FDE59DFD7986D9E7C534A01235A7" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_9620FDE59DFD7986D9E7C534A01235A7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding" xlink:label="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_64F2EA165B28BBF938DDC534A0125C63" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_64F2EA165B28BBF938DDC534A0125C63" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_B250E9C4496AB641C969C534A0125A5E" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_7500E7D21DE1FAE09CE7C534A0117BD6" xlink:to="loc_us-gaap_EarningsPerShareDiluted_B250E9C4496AB641C969C534A0125A5E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_D78A8B797718C7B6D01BC534A06C648F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_707779BB43EAE314CCF4C534A069CC68" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_D78A8B797718C7B6D01BC534A06C648F" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_707779BB43EAE314CCF4C534A069CC68" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_13BBB3E7B763394AF052C534A06A4895" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_707779BB43EAE314CCF4C534A069CC68" xlink:to="loc_srt_ConsolidationItemsAxis_13BBB3E7B763394AF052C534A06A4895" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_3CAC8EBC38D5B3633EC3C534A06A729F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_13BBB3E7B763394AF052C534A06A4895" xlink:to="loc_srt_ConsolidationItemsDomain_3CAC8EBC38D5B3633EC3C534A06A729F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_3CAC8EBC38D5B3633EC3C534A06A729F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_13BBB3E7B763394AF052C534A06A4895" xlink:to="loc_srt_ConsolidationItemsDomain_3CAC8EBC38D5B3633EC3C534A06A729F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_C57058FFF73CB4CAE0C2C534A06A998D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_3CAC8EBC38D5B3633EC3C534A06A729F" xlink:to="loc_us-gaap_OperatingSegmentsMember_C57058FFF73CB4CAE0C2C534A06A998D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CorporateNonSegmentMember" xlink:label="loc_us-gaap_CorporateNonSegmentMember_594BA1FAAFFDE8E329F3C534A06AE70C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_3CAC8EBC38D5B3633EC3C534A06A729F" xlink:to="loc_us-gaap_CorporateNonSegmentMember_594BA1FAAFFDE8E329F3C534A06AE70C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_ABF21CF020D08EB777A6C534A06BA190" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_707779BB43EAE314CCF4C534A069CC68" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_ABF21CF020D08EB777A6C534A06BA190" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_ABF21CF020D08EB777A6C534A06BA190" xlink:to="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_ABF21CF020D08EB777A6C534A06BA190" xlink:to="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_6D1A7C5CD92E9B11CA96C534A06B6A24" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114" xlink:to="loc_hsy_NorthAmericaSegmentMember_6D1A7C5CD92E9B11CA96C534A06B6A24" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_EF407933D5C416DC7607C534A06B8F2C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114" xlink:to="loc_hsy_InternationalandOtherSegmentMember_EF407933D5C416DC7607C534A06B8F2C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CorporateMember" xlink:label="loc_us-gaap_CorporateMember_78A866B9C02B357CEB96C534A06B7A4F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_331A8D0E596A3146B6A2C534A06BA114" xlink:to="loc_us-gaap_CorporateMember_78A866B9C02B357CEB96C534A06B7A4F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DepreciationDepletionAndAmortization" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_4FE9FF75BDDA53CBA204C534A06CFECE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_D78A8B797718C7B6D01BC534A06C648F" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_4FE9FF75BDDA53CBA204C534A06CFECE" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_7453FA9BE83A2526720EC534A07DE997" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_7453FA9BE83A2526720EC534A07DE997" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_8FC92A0BA8DB9548711CC534A07D9743" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_7453FA9BE83A2526720EC534A07DE997" xlink:to="loc_srt_ConsolidationItemsAxis_8FC92A0BA8DB9548711CC534A07D9743" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_8FC92A0BA8DB9548711CC534A07D9743" xlink:to="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_8FC92A0BA8DB9548711CC534A07D9743" xlink:to="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_96B7A04AA1415E4A2D55C534A07E5F97" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F" xlink:to="loc_us-gaap_OperatingSegmentsMember_96B7A04AA1415E4A2D55C534A07E5F97" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CorporateNonSegmentMember" xlink:label="loc_us-gaap_CorporateNonSegmentMember_EC91EB77DD22EFB66473C534A07E39DA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F" xlink:to="loc_us-gaap_CorporateNonSegmentMember_EC91EB77DD22EFB66473C534A07E39DA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_B33A39AA71059493E811C534A07E18EF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_5E4BD2DD8EE4A4C59AE3C534A07E1D6F" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_B33A39AA71059493E811C534A07E18EF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_2B09B27918FB18732116C534A07FBF0D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_7453FA9BE83A2526720EC534A07DE997" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_2B09B27918FB18732116C534A07FBF0D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_2B09B27918FB18732116C534A07FBF0D" xlink:to="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_2B09B27918FB18732116C534A07FBF0D" xlink:to="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_87AB2522F26269DFA605C534A07FFFC2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_87AB2522F26269DFA605C534A07FFFC2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_2713A593B934C0D87C39C534A07FB2E3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61" xlink:to="loc_hsy_NorthAmericaSegmentMember_2713A593B934C0D87C39C534A07FB2E3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_1CF8F6B10244ECDF1EB1C534A07F1B63" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_97AF61B0EFB8345C376EC534A07F0E61" xlink:to="loc_hsy_InternationalandOtherSegmentMember_1CF8F6B10244ECDF1EB1C534A07F1B63" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_B1B41300BB30318901A2C534A0801338" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_Revenues_B1B41300BB30318901A2C534A0801338" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_C8A67B94899B9A7114CCC534A0807E9D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_OperatingIncomeLoss_C8A67B94899B9A7114CCC534A0807E9D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_2FBD167461BAE5434BBEC534A0804CFB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_2FBD167461BAE5434BBEC534A0804CFB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GoodwillAndIntangibleAssetImpairment" xlink:label="loc_us-gaap_GoodwillAndIntangibleAssetImpairment_1D0F857317DBADAC1E4AC534A0803679" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_GoodwillAndIntangibleAssetImpairment_1D0F857317DBADAC1E4AC534A0803679" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_66C3D1E5C7D4AE7FB7C6C534A081ACDF" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_RestructuringCharges_66C3D1E5C7D4AE7FB7C6C534A081ACDF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BusinessCombinationIntegrationRelatedCosts" xlink:label="loc_us-gaap_BusinessCombinationIntegrationRelatedCosts_6EEA87A9E5701AC2BA05C534A081BA60" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_BusinessCombinationIntegrationRelatedCosts_6EEA87A9E5701AC2BA05C534A081BA60" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GainLossOnDispositionOfIntangibleAssets" xlink:label="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_874A3F547A6B2F760568C534A08121E0" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_874A3F547A6B2F760568C534A08121E0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_A0C3AE11A83C201EFF0DC534A081A72F" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_A0C3AE11A83C201EFF0DC534A081A72F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_1FFB224DA67096A306F9C534A0819688" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_1FFB224DA67096A306F9C534A0819688" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_B86741D2D4C1680AA5F0C534A0812A9F" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_23948B69D95ACA7DE2C4C534A080752F" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_B86741D2D4C1680AA5F0C534A0812A9F" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleOfQuarterlyFinancialInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_8413FC0412CC5020A91AC5349F6A4C87" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_StatementTable_8413FC0412CC5020A91AC5349F6A4C87" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_2DBB3A0CE459BE64B481C5349F6B08FF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_8413FC0412CC5020A91AC5349F6A4C87" xlink:to="loc_us-gaap_StatementClassOfStockAxis_2DBB3A0CE459BE64B481C5349F6B08FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_FE4F681003EC21B25C2BC5349F6BE2DD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_2DBB3A0CE459BE64B481C5349F6B08FF" xlink:to="loc_us-gaap_ClassOfStockDomain_FE4F681003EC21B25C2BC5349F6BE2DD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_FE4F681003EC21B25C2BC5349F6BE2DD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_2DBB3A0CE459BE64B481C5349F6B08FF" xlink:to="loc_us-gaap_ClassOfStockDomain_FE4F681003EC21B25C2BC5349F6BE2DD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_EC6966C79DFAFE3D0986C5349F6BB8A7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_FE4F681003EC21B25C2BC5349F6BE2DD" xlink:to="loc_hsy_HersheyCommonStockMember_EC6966C79DFAFE3D0986C5349F6BB8A7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_83A6B923BF363CDFEFACC5349F6C0C33" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_FE4F681003EC21B25C2BC5349F6BE2DD" xlink:to="loc_us-gaap_CommonClassBMember_83A6B923BF363CDFEFACC5349F6C0C33" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_6144ED284FDD3F48D8F3C5349F6C145B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_8413FC0412CC5020A91AC5349F6A4C87" xlink:to="loc_srt_RangeAxis_6144ED284FDD3F48D8F3C5349F6C145B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_7E88FCD5863600D20C27C5349F6C5A84_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_6144ED284FDD3F48D8F3C5349F6C145B" xlink:to="loc_srt_RangeMember_7E88FCD5863600D20C27C5349F6C5A84_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_7E88FCD5863600D20C27C5349F6C5A84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_6144ED284FDD3F48D8F3C5349F6C145B" xlink:to="loc_srt_RangeMember_7E88FCD5863600D20C27C5349F6C5A84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_34B42F83C48435DD78D2C5349F6CDCEC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_7E88FCD5863600D20C27C5349F6C5A84" xlink:to="loc_srt_MaximumMember_34B42F83C48435DD78D2C5349F6CDCEC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_5BDEA7B182FAC21EA408C5349F6D0C63" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_7E88FCD5863600D20C27C5349F6C5A84" xlink:to="loc_srt_MinimumMember_5BDEA7B182FAC21EA408C5349F6D0C63" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_BD2C6AA82AA73031699CC5349F6D1CED" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_Revenues_BD2C6AA82AA73031699CC5349F6D1CED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GrossProfit" xlink:label="loc_us-gaap_GrossProfit_BF42196BD1A6FF835C75C5349F6D944C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_GrossProfit_BF42196BD1A6FF835C75C5349F6D944C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_11835607E503955360A8C5349F70CC5D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_NetIncomeLoss_11835607E503955360A8C5349F70CC5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_FEAA47741D1F42D3A63EC5349F70B306" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_EarningsPerShareBasic_FEAA47741D1F42D3A63EC5349F70B306" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_9CFE661A06ABBE23F1B7C5349F70FE35" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_EarningsPerShareDiluted_9CFE661A06ABBE23F1B7C5349F70FE35" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_1BA6ED8C352C73BAC1CDC5349F71F1B2" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_1BA6ED8C352C73BAC1CDC5349F71F1B2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_4A42CD0F1DF5DC38AA8DC5349F71848D" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_5C5C2D4488E1B7198BE8C5349F6D4B48" xlink:to="loc_us-gaap_SharePrice_4A42CD0F1DF5DC38AA8DC5349F71848D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleOfSegmentInformationByGeographyDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems" xlink:label="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_2FBDD6272B5DFF561C73C534A065522D" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable" xlink:label="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_AC202B77D0DEA996D454C534A064DCD7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_2FBDD6272B5DFF561C73C534A065522D" xlink:to="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_AC202B77D0DEA996D454C534A064DCD7" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_StatementGeographicalAxis" xlink:label="loc_srt_StatementGeographicalAxis_27766BA1D5A95CB2B470C534A064A348" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_AC202B77D0DEA996D454C534A064DCD7" xlink:to="loc_srt_StatementGeographicalAxis_27766BA1D5A95CB2B470C534A064A348" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_SegmentGeographicalDomain" xlink:label="loc_srt_SegmentGeographicalDomain_F551591C410B0952804CC534A06453EF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_StatementGeographicalAxis_27766BA1D5A95CB2B470C534A064A348" xlink:to="loc_srt_SegmentGeographicalDomain_F551591C410B0952804CC534A06453EF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_SegmentGeographicalDomain" xlink:label="loc_srt_SegmentGeographicalDomain_F551591C410B0952804CC534A06453EF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_StatementGeographicalAxis_27766BA1D5A95CB2B470C534A064A348" xlink:to="loc_srt_SegmentGeographicalDomain_F551591C410B0952804CC534A06453EF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.sec.gov/country/2017/country-2017-01-31.xsd#country_US" xlink:label="loc_country_US_3D057EA01C32720C1B16C534A064DBE3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SegmentGeographicalDomain_F551591C410B0952804CC534A06453EF" xlink:to="loc_country_US_3D057EA01C32720C1B16C534A064DBE3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NonUsMember" xlink:label="loc_us-gaap_NonUsMember_3FD91A0F94872D05D719C534A065FD70" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_SegmentGeographicalDomain_F551591C410B0952804CC534A06453EF" xlink:to="loc_us-gaap_NonUsMember_3FD91A0F94872D05D719C534A065FD70" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_658E17649A6DD504FC69C534A065E599" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_2FBDD6272B5DFF561C73C534A065522D" xlink:to="loc_us-gaap_Revenues_658E17649A6DD504FC69C534A065E599" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_177D4BE193333718F333C534A0658BA7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_2FBDD6272B5DFF561C73C534A065522D" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_177D4BE193333718F333C534A0658BA7" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleOfSupplementalBalanceSheetInformationDetails" xlink:type="extended" />
  <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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EntityWideRevenueMajorCustomerLineItems" xlink:label="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_E000CCA49803B0F5465AC534A08E6E87" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable" xlink:label="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_E000CCA49803B0F5465AC534A08E6E87" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_09DA189611EF73B6535DC534A089E774" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_09DA189611EF73B6535DC534A089E774" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_B06C563972B52280113AC534A089D000_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_09DA189611EF73B6535DC534A089E774" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_B06C563972B52280113AC534A089D000_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_B06C563972B52280113AC534A089D000" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_09DA189611EF73B6535DC534A089E774" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_B06C563972B52280113AC534A089D000" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CostOfSalesMember" xlink:label="loc_us-gaap_CostOfSalesMember_1C5A416072C28763F3FCC534A08AF768" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_B06C563972B52280113AC534A089D000" xlink:to="loc_us-gaap_CostOfSalesMember_1C5A416072C28763F3FCC534A08AF768" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_38CDB3A339CDDF501669C534A08A1ADA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_us-gaap_StatementScenarioAxis_38CDB3A339CDDF501669C534A08A1ADA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_EB99BD3B85A7CF362F1AC534A08AD1F7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_38CDB3A339CDDF501669C534A08A1ADA" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_EB99BD3B85A7CF362F1AC534A08AD1F7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_EB99BD3B85A7CF362F1AC534A08AD1F7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_38CDB3A339CDDF501669C534A08A1ADA" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_EB99BD3B85A7CF362F1AC534A08AD1F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_ADBF3D5F1BF3403DACA1C534A08A4148" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_EB99BD3B85A7CF362F1AC534A08AD1F7" xlink:to="loc_us-gaap_ScenarioForecastMember_ADBF3D5F1BF3403DACA1C534A08A4148" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_1701FF496DBC03E309A6C534A08B2039" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_srt_ConsolidationItemsAxis_1701FF496DBC03E309A6C534A08B2039" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_E5E638BFE0103AFFDDB1C534A08BEA8D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_1701FF496DBC03E309A6C534A08B2039" xlink:to="loc_srt_ConsolidationItemsDomain_E5E638BFE0103AFFDDB1C534A08BEA8D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_E5E638BFE0103AFFDDB1C534A08BEA8D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_1701FF496DBC03E309A6C534A08B2039" xlink:to="loc_srt_ConsolidationItemsDomain_E5E638BFE0103AFFDDB1C534A08BEA8D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_B7658FCE8A5238BEF054C534A08B0F16" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_E5E638BFE0103AFFDDB1C534A08BEA8D" xlink:to="loc_us-gaap_OperatingSegmentsMember_B7658FCE8A5238BEF054C534A08B0F16" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_2B80C70597535E6D4C15C534A08C1219" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_2B80C70597535E6D4C15C534A08C1219" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_FC187801436133400F19C534A08C2922_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_2B80C70597535E6D4C15C534A08C1219" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_FC187801436133400F19C534A08C2922_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_FC187801436133400F19C534A08C2922" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_2B80C70597535E6D4C15C534A08C1219" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_FC187801436133400F19C534A08C2922" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_253B4764C75C6B3AA149C534A08CDF39" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_FC187801436133400F19C534A08C2922" xlink:to="loc_us-gaap_CommodityContractMember_253B4764C75C6B3AA149C534A08CDF39" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_8E03ACF862A07013C69AC534A08C105E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_8E03ACF862A07013C69AC534A08C105E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_FB05AD34E425A51FBB12C534A08C27F5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_8E03ACF862A07013C69AC534A08C105E" xlink:to="loc_us-gaap_SegmentDomain_FB05AD34E425A51FBB12C534A08C27F5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_FB05AD34E425A51FBB12C534A08C27F5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_8E03ACF862A07013C69AC534A08C105E" xlink:to="loc_us-gaap_SegmentDomain_FB05AD34E425A51FBB12C534A08C27F5" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_A85405ABA6C8908902A4C534A08D4CB8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_FB05AD34E425A51FBB12C534A08C27F5" xlink:to="loc_hsy_NorthAmericaSegmentMember_A85405ABA6C8908902A4C534A08D4CB8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_3FC4859B49CD00A0758CC534A08D6E7F" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_3FC4859B49CD00A0758CC534A08D6E7F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_8EE637475DB6F55697DCC534A08D5D1B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_3FC4859B49CD00A0758CC534A08D6E7F" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_8EE637475DB6F55697DCC534A08D5D1B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_8EE637475DB6F55697DCC534A08D5D1B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_3FC4859B49CD00A0758CC534A08D6E7F" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_8EE637475DB6F55697DCC534A08D5D1B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_GeographicConcentrationRiskMember" xlink:label="loc_us-gaap_GeographicConcentrationRiskMember_63EE8B834103BB47BF83C534A08D9D84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_8EE637475DB6F55697DCC534A08D5D1B" xlink:to="loc_us-gaap_GeographicConcentrationRiskMember_63EE8B834103BB47BF83C534A08D9D84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_897500EAA3E67C31B937C534A08E39B8" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_0654735513DD40815DF5C534A089E2A2" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_897500EAA3E67C31B937C534A08E39B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_445D2D183E52BA03E3BBC534A08E85EF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_897500EAA3E67C31B937C534A08E39B8" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_445D2D183E52BA03E3BBC534A08E85EF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_445D2D183E52BA03E3BBC534A08E85EF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_897500EAA3E67C31B937C534A08E39B8" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_445D2D183E52BA03E3BBC534A08E85EF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SalesRevenueGoodsNetMember" xlink:label="loc_us-gaap_SalesRevenueGoodsNetMember_272068689D6E1F783546C534A08E3C9E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_445D2D183E52BA03E3BBC534A08E85EF" xlink:to="loc_us-gaap_SalesRevenueGoodsNetMember_272068689D6E1F783546C534A08E3C9E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_DDEB2E78E02A5A8B330AC534A08E0FC4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_E000CCA49803B0F5465AC534A08E6E87" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_DDEB2E78E02A5A8B330AC534A08E0FC4" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_CumulativeAmountofMarktoMarketLossesonCommodityDerivatives" xlink:label="loc_hsy_CumulativeAmountofMarktoMarketLossesonCommodityDerivatives_60CF7E7A522EC4E7ECB0C534A08FE7E9" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_E000CCA49803B0F5465AC534A08E6E87" xlink:to="loc_hsy_CumulativeAmountofMarktoMarketLossesonCommodityDerivatives_60CF7E7A522EC4E7ECB0C534A08FE7E9" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome" xlink:label="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_A1FA718A4844BF3765C9C534A08FF2DC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_E000CCA49803B0F5465AC534A08E6E87" xlink:to="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_A1FA718A4844BF3765C9C534A08FF2DC" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_F152C07A8D31972F5398C534A0604DE5" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D95FF2CE5C8F731C154FC534A05E9433" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_F152C07A8D31972F5398C534A0604DE5" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D95FF2CE5C8F731C154FC534A05E9433" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ProductOrServiceAxis" xlink:label="loc_srt_ProductOrServiceAxis_BEE1135B2CAA7D8ABF21C534A05E4686" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D95FF2CE5C8F731C154FC534A05E9433" xlink:to="loc_srt_ProductOrServiceAxis_BEE1135B2CAA7D8ABF21C534A05E4686" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ProductsAndServicesDomain" xlink:label="loc_srt_ProductsAndServicesDomain_3F7E8A91A54A35F6D61BC534A05FDF96_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ProductOrServiceAxis_BEE1135B2CAA7D8ABF21C534A05E4686" xlink:to="loc_srt_ProductsAndServicesDomain_3F7E8A91A54A35F6D61BC534A05FDF96_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ProductsAndServicesDomain" xlink:label="loc_srt_ProductsAndServicesDomain_3F7E8A91A54A35F6D61BC534A05FDF96" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ProductOrServiceAxis_BEE1135B2CAA7D8ABF21C534A05E4686" xlink:to="loc_srt_ProductsAndServicesDomain_3F7E8A91A54A35F6D61BC534A05FDF96" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ConfectioneryandConfectionerybasedPortfolioMember" xlink:label="loc_hsy_ConfectioneryandConfectionerybasedPortfolioMember_B8F04596F6DAE3AE0161C534A05FE35D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ProductsAndServicesDomain_3F7E8A91A54A35F6D61BC534A05FDF96" xlink:to="loc_hsy_ConfectioneryandConfectionerybasedPortfolioMember_B8F04596F6DAE3AE0161C534A05FE35D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_SnacksPortfolioMember" xlink:label="loc_hsy_SnacksPortfolioMember_B85785360B64A157ACB2C534A05FBDDF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ProductsAndServicesDomain_3F7E8A91A54A35F6D61BC534A05FDF96" xlink:to="loc_hsy_SnacksPortfolioMember_B85785360B64A157ACB2C534A05FBDDF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_B40E67268521F69E771EC534A0608D88" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_F152C07A8D31972F5398C534A0604DE5" xlink:to="loc_us-gaap_Revenues_B40E67268521F69E771EC534A0608D88" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_4DFF11FF5C9387C887C9C534A0760540" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_4DFF11FF5C9387C887C9C534A0760540" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_A0351B078978C819DC65C534A0729FD6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:to="loc_us-gaap_HedgingDesignationAxis_A0351B078978C819DC65C534A0729FD6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_8D73DD3D0B8C666C77BBC534A07280A2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_A0351B078978C819DC65C534A0729FD6" xlink:to="loc_us-gaap_HedgingDesignationDomain_8D73DD3D0B8C666C77BBC534A07280A2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_8D73DD3D0B8C666C77BBC534A07280A2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_A0351B078978C819DC65C534A0729FD6" xlink:to="loc_us-gaap_HedgingDesignationDomain_8D73DD3D0B8C666C77BBC534A07280A2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_B73C813A7F2ED502DE5FC534A072211C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_8D73DD3D0B8C666C77BBC534A07280A2" xlink:to="loc_us-gaap_NondesignatedMember_B73C813A7F2ED502DE5FC534A072211C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_8A4F5CAD3B4CD261F357C534A0737164" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_8A4F5CAD3B4CD261F357C534A0737164" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_33657234FD1A926A7B2EC534A073EFB7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_8A4F5CAD3B4CD261F357C534A0737164" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_33657234FD1A926A7B2EC534A073EFB7_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_33657234FD1A926A7B2EC534A073EFB7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_8A4F5CAD3B4CD261F357C534A0737164" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_33657234FD1A926A7B2EC534A073EFB7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_0EF5AC6E8497296238E3C534A0733ED3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_33657234FD1A926A7B2EC534A073EFB7" xlink:to="loc_us-gaap_CommodityContractMember_0EF5AC6E8497296238E3C534A0733ED3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsAxis" xlink:label="loc_srt_ConsolidationItemsAxis_8E87AEAA430F0A96C0CCC534A0734A61" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:to="loc_srt_ConsolidationItemsAxis_8E87AEAA430F0A96C0CCC534A0734A61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_080103946ED9DFC3ACF1C534A0738930_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_ConsolidationItemsAxis_8E87AEAA430F0A96C0CCC534A0734A61" xlink:to="loc_srt_ConsolidationItemsDomain_080103946ED9DFC3ACF1C534A0738930_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_ConsolidationItemsDomain" xlink:label="loc_srt_ConsolidationItemsDomain_080103946ED9DFC3ACF1C534A0738930" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_ConsolidationItemsAxis_8E87AEAA430F0A96C0CCC534A0734A61" xlink:to="loc_srt_ConsolidationItemsDomain_080103946ED9DFC3ACF1C534A0738930" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_F782AA49997A9B307DECC534A074EEEC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_ConsolidationItemsDomain_080103946ED9DFC3ACF1C534A0738930" xlink:to="loc_us-gaap_OperatingSegmentsMember_F782AA49997A9B307DECC534A074EEEC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_AABACCED73965CEC0601C534A074B7EB" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_AABACCED73965CEC0601C534A074B7EB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_52C84281672623C2EF03C534A074F013_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_AABACCED73965CEC0601C534A074B7EB" xlink:to="loc_us-gaap_SegmentDomain_52C84281672623C2EF03C534A074F013_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_52C84281672623C2EF03C534A074F013" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_AABACCED73965CEC0601C534A074B7EB" xlink:to="loc_us-gaap_SegmentDomain_52C84281672623C2EF03C534A074F013" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_E8E3BBD01329E819D893C534A0750BB2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_52C84281672623C2EF03C534A074F013" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_E8E3BBD01329E819D893C534A0750BB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SubsegmentsAxis" xlink:label="loc_us-gaap_SubsegmentsAxis_5C5CC54DD5B4DBD1AE11C534A07567E2" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:to="loc_us-gaap_SubsegmentsAxis_5C5CC54DD5B4DBD1AE11C534A07567E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SubsegmentsDomain" xlink:label="loc_us-gaap_SubsegmentsDomain_5D515BF46EBECAE11719C534A0753D83_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsegmentsAxis_5C5CC54DD5B4DBD1AE11C534A07567E2" xlink:to="loc_us-gaap_SubsegmentsDomain_5D515BF46EBECAE11719C534A0753D83_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SubsegmentsDomain" xlink:label="loc_us-gaap_SubsegmentsDomain_5D515BF46EBECAE11719C534A0753D83" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsegmentsAxis_5C5CC54DD5B4DBD1AE11C534A07567E2" xlink:to="loc_us-gaap_SubsegmentsDomain_5D515BF46EBECAE11719C534A0753D83" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsAxis" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsAxis_7B18BEA78613DC088F4EC534A0759794" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_A3EA5B32A325A03865D6C534A0712DAA" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsAxis_7B18BEA78613DC088F4EC534A0759794" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsDomain" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsDomain_45ECB005FD9D359A5B2AC534A076B22A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsegmentsConsolidationItemsAxis_7B18BEA78613DC088F4EC534A0759794" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsDomain_45ECB005FD9D359A5B2AC534A076B22A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsDomain" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsDomain_45ECB005FD9D359A5B2AC534A076B22A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsegmentsConsolidationItemsAxis_7B18BEA78613DC088F4EC534A0759794" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsDomain_45ECB005FD9D359A5B2AC534A076B22A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_D14587E14A3361476B46C534A07694D0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_4DFF11FF5C9387C887C9C534A0760540" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_D14587E14A3361476B46C534A07694D0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome" xlink:label="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_E4A4411D08A82F4A2D4BC534A076743F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_4DFF11FF5C9387C887C9C534A0760540" xlink:to="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_E4A4411D08A82F4A2D4BC534A076743F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses" xlink:label="loc_hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses_4A09F95C2D7D59951674C534A076BE7F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_4DFF11FF5C9387C887C9C534A0760540" xlink:to="loc_hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses_4A09F95C2D7D59951674C534A076BE7F" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_AADBBAB11C798577E0D6C534A22D6DFF" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_A7E89ED3E566165E73EAC534A22AD486" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_AADBBAB11C798577E0D6C534A22D6DFF" xlink:to="loc_us-gaap_DebtInstrumentTable_A7E89ED3E566165E73EAC534A22AD486" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_B4EEE4B37415D04EC9B9C534A22A6887" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_A7E89ED3E566165E73EAC534A22AD486" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_B4EEE4B37415D04EC9B9C534A22A6887" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_45DFEEC650AE877D499BC534A22A4D03_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_B4EEE4B37415D04EC9B9C534A22A6887" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_45DFEEC650AE877D499BC534A22A4D03_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_45DFEEC650AE877D499BC534A22A4D03" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_B4EEE4B37415D04EC9B9C534A22A6887" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_45DFEEC650AE877D499BC534A22A4D03" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_1C91D23ECD5BF414680DC534A22BF10D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_45DFEEC650AE877D499BC534A22A4D03" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_1C91D23ECD5BF414680DC534A22BF10D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_1799CC5CB3139A3A5E01C534A22B7C6E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_A7E89ED3E566165E73EAC534A22AD486" xlink:to="loc_us-gaap_DebtInstrumentAxis_1799CC5CB3139A3A5E01C534A22B7C6E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_1799CC5CB3139A3A5E01C534A22B7C6E" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_1799CC5CB3139A3A5E01C534A22B7C6E" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes1.60Due2018Member" xlink:label="loc_hsy_Notes1.60Due2018Member_D8A8D9A425279FE1281CC534A22B406B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes1.60Due2018Member_D8A8D9A425279FE1281CC534A22B406B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes2.90Due2020Domain" xlink:label="loc_hsy_Notes2.90Due2020Domain_85B1F290C68B07480764C534A22CAF81" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes2.90Due2020Domain_85B1F290C68B07480764C534A22CAF81" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes4.125Due2020Member" xlink:label="loc_hsy_Notes4.125Due2020Member_41FE35EEA03E0458814BC534A22CFE9A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes4.125Due2020Member_41FE35EEA03E0458814BC534A22CFE9A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.10Due2021Domain" xlink:label="loc_hsy_Notes3.10Due2021Domain_B51953BDA856790E13EFC534A22CBB81" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes3.10Due2021Domain_B51953BDA856790E13EFC534A22CBB81" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_A965ED95F6354FA48F0BC534A22CFF3A" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Debentures8.8Due2021Member_A965ED95F6354FA48F0BC534A22CFF3A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.375Due2023Domain" xlink:label="loc_hsy_Notes3.375Due2023Domain_FDE1CAB92B143959136BC534A22C7224" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes3.375Due2023Domain_FDE1CAB92B143959136BC534A22C7224" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes2.625Due2023Member" xlink:label="loc_hsy_Notes2.625Due2023Member_0351C66D019383F5A21AC534A22CE34C" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes2.625Due2023Member_0351C66D019383F5A21AC534A22CE34C" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.20Due2025Member" xlink:label="loc_hsy_Notes3.20Due2025Member_9E0E7AA4499BA30D48BEC534A22CA1F6" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes3.20Due2025Member_9E0E7AA4499BA30D48BEC534A22CA1F6" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_F621915677A4884A7ECCC534A22DE18B" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes2.30Due2026Member_F621915677A4884A7ECCC534A22DE18B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_9A4EB0C5B7840F17773BC534A22D24F2" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Debentures7.2Due2027Member_9A4EB0C5B7840F17773BC534A22D24F2" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_134DA5D2E7AEC1A0D065C534A22DCC95" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_474ADB687994E3436327C534A22B8508" xlink:to="loc_hsy_Notes3.375Due2046Member_134DA5D2E7AEC1A0D065C534A22DCC95" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_79DC41A90F8B80FE778DC534A22D92A2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_AADBBAB11C798577E0D6C534A22D6DFF" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_79DC41A90F8B80FE778DC534A22D92A2" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_EF6A8A293F3919F2460AE8C560728865" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_DE0E7FAC98E3470BCBA2E8C5606FDD32" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_EF6A8A293F3919F2460AE8C560728865" xlink:to="loc_us-gaap_DebtInstrumentTable_DE0E7FAC98E3470BCBA2E8C5606FDD32" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_55EB22239CB13A4408E4E8C5607007E7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_DE0E7FAC98E3470BCBA2E8C5606FDD32" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_55EB22239CB13A4408E4E8C5607007E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_6FD267E3B524604D4F79E8C56070B3FE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_55EB22239CB13A4408E4E8C5607007E7" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_6FD267E3B524604D4F79E8C56070B3FE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_6FD267E3B524604D4F79E8C56070B3FE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_55EB22239CB13A4408E4E8C5607007E7" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_6FD267E3B524604D4F79E8C56070B3FE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_2A8A9512300E1DEA76FDE8C560702FB2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_6FD267E3B524604D4F79E8C56070B3FE" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_2A8A9512300E1DEA76FDE8C560702FB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_F2ABB3B03D11E227C853E8C56071AEE1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_DE0E7FAC98E3470BCBA2E8C5606FDD32" xlink:to="loc_us-gaap_DebtInstrumentAxis_F2ABB3B03D11E227C853E8C56071AEE1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_39B660EDACB3CCC5DCB2E8C56071F328_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_F2ABB3B03D11E227C853E8C56071AEE1" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_39B660EDACB3CCC5DCB2E8C56071F328_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_39B660EDACB3CCC5DCB2E8C56071F328" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_F2ABB3B03D11E227C853E8C56071AEE1" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_39B660EDACB3CCC5DCB2E8C56071F328" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes5.45Due2016Member" xlink:label="loc_hsy_Notes5.45Due2016Member_12D00CE9F8A155CF1BE3E8C560718BA0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_39B660EDACB3CCC5DCB2E8C56071F328" xlink:to="loc_hsy_Notes5.45Due2016Member_12D00CE9F8A155CF1BE3E8C560718BA0" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes1.50Due2016Member" xlink:label="loc_hsy_Notes1.50Due2016Member_17197CB222457975E340E8C56072F1D5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_39B660EDACB3CCC5DCB2E8C56071F328" xlink:to="loc_hsy_Notes1.50Due2016Member_17197CB222457975E340E8C56072F1D5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ExtinguishmentOfDebtAxis" xlink:label="loc_us-gaap_ExtinguishmentOfDebtAxis_D2803AF078073733516EE8C560720DEA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_DE0E7FAC98E3470BCBA2E8C5606FDD32" xlink:to="loc_us-gaap_ExtinguishmentOfDebtAxis_D2803AF078073733516EE8C560720DEA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ExtinguishmentOfDebtTypeDomain" xlink:label="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_184E68F8E5800A26FE56E8C560723C90_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ExtinguishmentOfDebtAxis_D2803AF078073733516EE8C560720DEA" xlink:to="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_184E68F8E5800A26FE56E8C560723C90_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ExtinguishmentOfDebtTypeDomain" xlink:label="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_184E68F8E5800A26FE56E8C560723C90" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ExtinguishmentOfDebtAxis_D2803AF078073733516EE8C560720DEA" xlink:to="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_184E68F8E5800A26FE56E8C560723C90" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_DD2D84047ED2B33AE0F7E8C56072D29E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_184E68F8E5800A26FE56E8C560723C90" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_DD2D84047ED2B33AE0F7E8C56072D29E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RepaymentsOfDebt" xlink:label="loc_us-gaap_RepaymentsOfDebt_D22992471FBBEDD44D72E8C56073768E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_EF6A8A293F3919F2460AE8C560728865" xlink:to="loc_us-gaap_RepaymentsOfDebt_D22992471FBBEDD44D72E8C56073768E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_0D06DAC8E2B4915C0EDEE8C56073D76B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_EF6A8A293F3919F2460AE8C560728865" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_0D06DAC8E2B4915C0EDEE8C56073D76B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_1A97BF8C5B22B371DD45E8C5648A2746" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_EF6A8A293F3919F2460AE8C560728865" xlink:to="loc_us-gaap_LongTermDebt_1A97BF8C5B22B371DD45E8C5648A2746" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_35C3D7B54039728C9600E9BBE22DB9B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_DebtInstrumentTable_35C3D7B54039728C9600E9BBE22DB9B3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_CF9267F1368D979A96B1E9BBE22DE661" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_35C3D7B54039728C9600E9BBE22DB9B3" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_CF9267F1368D979A96B1E9BBE22DE661" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_AEC5D853FD14E9B36191E9BBE22D214F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_CF9267F1368D979A96B1E9BBE22DE661" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_AEC5D853FD14E9B36191E9BBE22D214F_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_AEC5D853FD14E9B36191E9BBE22D214F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_CF9267F1368D979A96B1E9BBE22DE661" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_AEC5D853FD14E9B36191E9BBE22D214F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_2391FCB465BBB96AEE6AE9BBE22E33A1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_AEC5D853FD14E9B36191E9BBE22D214F" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_2391FCB465BBB96AEE6AE9BBE22E33A1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CapitalLeaseObligationsMember" xlink:label="loc_us-gaap_CapitalLeaseObligationsMember_C917E58AC5E10B8391ABE9BBE22E9FA1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_AEC5D853FD14E9B36191E9BBE22D214F" xlink:to="loc_us-gaap_CapitalLeaseObligationsMember_C917E58AC5E10B8391ABE9BBE22E9FA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_2772A13758F078383D78E9BBE22E15F8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_35C3D7B54039728C9600E9BBE22DB9B3" xlink:to="loc_us-gaap_DebtInstrumentAxis_2772A13758F078383D78E9BBE22E15F8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_2772A13758F078383D78E9BBE22E15F8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_2772A13758F078383D78E9BBE22E15F8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes1.60Due2018Member" xlink:label="loc_hsy_Notes1.60Due2018Member_4BCB9CCC4C4725CB83D8E9BBE22F30D8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes1.60Due2018Member_4BCB9CCC4C4725CB83D8E9BBE22F30D8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes2.90Due2020Domain" xlink:label="loc_hsy_Notes2.90Due2020Domain_43115B18E47C34335899E9BBE22F5673" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes2.90Due2020Domain_43115B18E47C34335899E9BBE22F5673" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes4.125Due2020Member" xlink:label="loc_hsy_Notes4.125Due2020Member_B05BDD1114E1129947B4E9BBE22FEC66" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes4.125Due2020Member_B05BDD1114E1129947B4E9BBE22FEC66" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.10Due2021Domain" xlink:label="loc_hsy_Notes3.10Due2021Domain_E5305343F607FECE1BFEE9BBE22F163E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes3.10Due2021Domain_E5305343F607FECE1BFEE9BBE22F163E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_15F079C52F3B9D2078E6E9BBE230B34D" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Debentures8.8Due2021Member_15F079C52F3B9D2078E6E9BBE230B34D" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.375Due2023Domain" xlink:label="loc_hsy_Notes3.375Due2023Domain_2AF5FA54A0401443764FE9BBE2307986" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes3.375Due2023Domain_2AF5FA54A0401443764FE9BBE2307986" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes2.625Due2023Member" xlink:label="loc_hsy_Notes2.625Due2023Member_0DB2B13777E6280117D0E9BBE2302C3B" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes2.625Due2023Member_0DB2B13777E6280117D0E9BBE2302C3B" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.20Due2025Member" xlink:label="loc_hsy_Notes3.20Due2025Member_ADC26D656000226FB12FE9BBE23097F7" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes3.20Due2025Member_ADC26D656000226FB12FE9BBE23097F7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_6B6A5868973F30C10D9EE9BBE230FA12" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes2.30Due2026Member_6B6A5868973F30C10D9EE9BBE230FA12" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_2F6965B419B899B9B2CFE9BBE2307E40" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Debentures7.2Due2027Member_2F6965B419B899B9B2CFE9BBE2307E40" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_E399205B5169C968D737E9BBE23016D9" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CB57439011A7576D8273E9BBE22EA64D" xlink:to="loc_hsy_Notes3.375Due2046Member_E399205B5169C968D737E9BBE23016D9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_D89FC133E50579D23B75E9BBE231B049" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_LongTermDebt_D89FC133E50579D23B75E9BBE231B049" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet" xlink:label="loc_hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet_F19F17350E175F34D70EE9BBE2319DFD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet_F19F17350E175F34D70EE9BBE2319DFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_EAE0B680678058076B70E9BBE231480D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_LongTermDebtCurrent_EAE0B680678058076B70E9BBE231480D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongTermDebtNoncurrent" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_102029D1C3121796B6D4E9BBE232064E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_102029D1C3121796B6D4E9BBE232064E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RepaymentsOfDebt" xlink:label="loc_us-gaap_RepaymentsOfDebt_78B6F103E6C55651A8D7E9BBE232A0D0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_RepaymentsOfDebt_78B6F103E6C55651A8D7E9BBE232A0D0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_A944A522B7679748B3BCE9BBE232A5E5" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_A944A522B7679748B3BCE9BBE232A5E5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_632616D49D43EAB6ACBAE9BBE2321DFE" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_1A9C5A8020AB4274B6D3E9BBE231155B" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_632616D49D43EAB6ACBAE9BBE2321DFE" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LineOfCreditFacilityLineItems" xlink:label="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LineOfCreditFacilityTable" xlink:label="loc_us-gaap_LineOfCreditFacilityTable_DCC1529F2B4E779EFB39C534A243281D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_us-gaap_LineOfCreditFacilityTable_DCC1529F2B4E779EFB39C534A243281D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_538FB401E17BBA4D20A9C534A243A04F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_DCC1529F2B4E779EFB39C534A243281D" xlink:to="loc_us-gaap_DebtInstrumentAxis_538FB401E17BBA4D20A9C534A243A04F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_E6021F5AA0F894597BDEC534A243FDDD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_538FB401E17BBA4D20A9C534A243A04F" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_E6021F5AA0F894597BDEC534A243FDDD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_E6021F5AA0F894597BDEC534A243FDDD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_538FB401E17BBA4D20A9C534A243A04F" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_E6021F5AA0F894597BDEC534A243FDDD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_452FBB6AD5C2ACF2C8BBC534A244F035" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_E6021F5AA0F894597BDEC534A243FDDD" xlink:to="loc_us-gaap_LineOfCreditMember_452FBB6AD5C2ACF2C8BBC534A244F035" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CreditFacilityAxis" xlink:label="loc_us-gaap_CreditFacilityAxis_4F8C468C87C155FD6531C534A244FE1D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_DCC1529F2B4E779EFB39C534A243281D" xlink:to="loc_us-gaap_CreditFacilityAxis_4F8C468C87C155FD6531C534A244FE1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_705716267FEFA4592AD6C534A24427B2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_4F8C468C87C155FD6531C534A244FE1D" xlink:to="loc_us-gaap_CreditFacilityDomain_705716267FEFA4592AD6C534A24427B2_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_705716267FEFA4592AD6C534A24427B2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_4F8C468C87C155FD6531C534A244FE1D" xlink:to="loc_us-gaap_CreditFacilityDomain_705716267FEFA4592AD6C534A24427B2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RevolvingCreditFacilityMember" xlink:label="loc_us-gaap_RevolvingCreditFacilityMember_271D7B56C93D1C1223F6C534A2449477" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_705716267FEFA4592AD6C534A24427B2" xlink:to="loc_us-gaap_RevolvingCreditFacilityMember_271D7B56C93D1C1223F6C534A2449477" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_40FC1B2D318C655D7EE9C534A2452324" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_DCC1529F2B4E779EFB39C534A243281D" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_40FC1B2D318C655D7EE9C534A2452324" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_2D957AA35FA1B37B9206C534A245F491_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_40FC1B2D318C655D7EE9C534A2452324" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_2D957AA35FA1B37B9206C534A245F491_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_2D957AA35FA1B37B9206C534A245F491" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_40FC1B2D318C655D7EE9C534A2452324" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_2D957AA35FA1B37B9206C534A245F491" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_EFBD4B26619EAF45C384C534A2457250" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_2D957AA35FA1B37B9206C534A245F491" xlink:to="loc_us-gaap_LineOfCreditMember_EFBD4B26619EAF45C384C534A2457250" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ForeignLineOfCreditMember" xlink:label="loc_us-gaap_ForeignLineOfCreditMember_F026900FBB5B6ED3A8D4C534A246B81D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_2D957AA35FA1B37B9206C534A245F491" xlink:to="loc_us-gaap_ForeignLineOfCreditMember_F026900FBB5B6ED3A8D4C534A246B81D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShortTermDebtTypeAxis" xlink:label="loc_us-gaap_ShortTermDebtTypeAxis_EA6FBD9059DE664E9B94C534A2466472" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_DCC1529F2B4E779EFB39C534A243281D" xlink:to="loc_us-gaap_ShortTermDebtTypeAxis_EA6FBD9059DE664E9B94C534A2466472" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShortTermDebtTypeDomain" xlink:label="loc_us-gaap_ShortTermDebtTypeDomain_C795BBF492E44C782BE1C534A24603C3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ShortTermDebtTypeAxis_EA6FBD9059DE664E9B94C534A2466472" xlink:to="loc_us-gaap_ShortTermDebtTypeDomain_C795BBF492E44C782BE1C534A24603C3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShortTermDebtTypeDomain" xlink:label="loc_us-gaap_ShortTermDebtTypeDomain_C795BBF492E44C782BE1C534A24603C3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ShortTermDebtTypeAxis_EA6FBD9059DE664E9B94C534A2466472" xlink:to="loc_us-gaap_ShortTermDebtTypeDomain_C795BBF492E44C782BE1C534A24603C3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CommercialPaperMember" xlink:label="loc_us-gaap_CommercialPaperMember_83EA3BBA0AF8DC8213BBC534A24754C2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShortTermDebtTypeDomain_C795BBF492E44C782BE1C534A24603C3" xlink:to="loc_us-gaap_CommercialPaperMember_83EA3BBA0AF8DC8213BBC534A24754C2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_25BD7FDC60BA5166CE3FC534A2470B8A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_25BD7FDC60BA5166CE3FC534A2470B8A" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum" xlink:label="loc_hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum_856A53D301FA4F37A4E8C534A247E5A1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum_856A53D301FA4F37A4E8C534A247E5A1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LinesOfCreditCurrent" xlink:label="loc_us-gaap_LinesOfCreditCurrent_D9C8748BDA34F86ED095C534A2474670" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_us-gaap_LinesOfCreditCurrent_D9C8748BDA34F86ED095C534A2474670" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShortTermBorrowings" xlink:label="loc_us-gaap_ShortTermBorrowings_DA079728CDA85E8FB55EC534A2487369" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_us-gaap_ShortTermBorrowings_DA079728CDA85E8FB55EC534A2487369" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShortTermDebtWeightedAverageInterestRate" xlink:label="loc_us-gaap_ShortTermDebtWeightedAverageInterestRate_1170A1BC5DC363A73EB6C534A248A5EB" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_us-gaap_ShortTermDebtWeightedAverageInterestRate_1170A1BC5DC363A73EB6C534A248A5EB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod_76EB3A89AF13C4BFE316C534A24843A4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_D90CFB8D527D2AF5942FC534A2478AF4" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod_76EB3A89AF13C4BFE316C534A24843A4" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CAA3D57159BC3E0C819CC534A0A35A0B" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C8C14DD40392C622DC8DC534A0A20470" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CAA3D57159BC3E0C819CC534A0A35A0B" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C8C14DD40392C622DC8DC534A0A20470" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_8EC315E2A4664817160DC534A0A2B6A4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C8C14DD40392C622DC8DC534A0A20470" xlink:to="loc_us-gaap_AwardTypeAxis_8EC315E2A4664817160DC534A0A2B6A4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_67EF77435796A9DAC975C534A0A3EC48_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_8EC315E2A4664817160DC534A0A2B6A4" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_67EF77435796A9DAC975C534A0A3EC48_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_67EF77435796A9DAC975C534A0A3EC48" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_8EC315E2A4664817160DC534A0A2B6A4" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_67EF77435796A9DAC975C534A0A3EC48" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_3877F31792ADBB7D9575C534A0A3FC44" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_67EF77435796A9DAC975C534A0A3EC48" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_3877F31792ADBB7D9575C534A0A3FC44" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CAA3D57159BC3E0C819CC534A0A35A0B" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_5874B8D886EBA7709C92C534A0A42323" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_5874B8D886EBA7709C92C534A0A42323" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_55D3D7A5DD07774D2D95C534A0A49872" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_55D3D7A5DD07774D2D95C534A0A49872" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange_47AC378BACEDE3F082D1C534A0A41B63" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange_47AC378BACEDE3F082D1C534A0A41B63" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_32EBC1691AFF5C5E2F49C534A0A4C8CE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_32EBC1691AFF5C5E2F49C534A0A4C8CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_8C2DD890F6561DD0379DC534A0A488E7" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_13A2F170FBBB391860C5C534A0A30C20" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_8C2DD890F6561DD0379DC534A0A488E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CAA3D57159BC3E0C819CC534A0A35A0B" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_4C244F4F062BF816678BC534A0A52FB8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_4C244F4F062BF816678BC534A0A52FB8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_2005A03A9A7AA4B74EBCC534A0A576E7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_2005A03A9A7AA4B74EBCC534A0A576E7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue_ED7F93852B34C7B797DEC534A0A5C246" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue_ED7F93852B34C7B797DEC534A0A5C246" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_4D07444FC086E4BB6BEEC534A0A63830" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_4D07444FC086E4BB6BEEC534A0A63830" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_610D5B35CC09310E8B13C534A0A6573A" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_CB345C41D128340D9CFCC534A0A59BD1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_610D5B35CC09310E8B13C534A0A6573A" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8B3C51DCE7697BE62265C534A09B9853" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8B3C51DCE7697BE62265C534A09B9853" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_5FEBCDDE69350189639BC534A09B3F07" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8B3C51DCE7697BE62265C534A09B9853" xlink:to="loc_us-gaap_AwardTypeAxis_5FEBCDDE69350189639BC534A09B3F07" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_0C689833DF1800CBC64EC534A09BF44E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_5FEBCDDE69350189639BC534A09B3F07" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_0C689833DF1800CBC64EC534A09BF44E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_0C689833DF1800CBC64EC534A09BF44E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_5FEBCDDE69350189639BC534A09B3F07" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_0C689833DF1800CBC64EC534A09BF44E" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_CF6349C2E28F1ECEC7ACC534A09BC266" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_0C689833DF1800CBC64EC534A09BF44E" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_CF6349C2E28F1ECEC7ACC534A09BC266" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_129C078BDF2177CE68CCC534A09CBCA7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_129C078BDF2177CE68CCC534A09CBCA7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_0985DAC12BDCAC785806C534A09CB0CC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_0985DAC12BDCAC785806C534A09CB0CC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_E892422491E8AE3F01C3C534A09C794B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:to="loc_us-gaap_SharePrice_E892422491E8AE3F01C3C534A09C794B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_CCFC26FA71096728777DC534A09C1DDB" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_CCFC26FA71096728777DC534A09C1DDB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_A4ACAF0135B5ABA2ED68C534A09D9A0C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_4C22C6319CB9C3F962E4C534A09C9BF6" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_A4ACAF0135B5ABA2ED68C534A09D9A0C" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_966CD319FFA16EB21C18C534A0ACC1A0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_966CD319FFA16EB21C18C534A0ACC1A0" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_B69A4E503C33510B9FA3C534A0ACCD65" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_966CD319FFA16EB21C18C534A0ACC1A0" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_B69A4E503C33510B9FA3C534A0ACCD65" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_B69A4E503C33510B9FA3C534A0ACCD65" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_B69A4E503C33510B9FA3C534A0ACCD65" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ExercisePriceRangeOneMember" xlink:label="loc_hsy_ExercisePriceRangeOneMember_916569855FFC7CF95314C534A0AD75C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC" xlink:to="loc_hsy_ExercisePriceRangeOneMember_916569855FFC7CF95314C534A0AD75C7" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ExercisePriceRangeTwoMember" xlink:label="loc_hsy_ExercisePriceRangeTwoMember_7867ABFB3D628C353134C534A0AD44D8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC" xlink:to="loc_hsy_ExercisePriceRangeTwoMember_7867ABFB3D628C353134C534A0AD44D8" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ExercisePriceRangeThreeMember" xlink:label="loc_hsy_ExercisePriceRangeThreeMember_F831C8EF1795EFB7D832C534A0ADA025" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC" xlink:to="loc_hsy_ExercisePriceRangeThreeMember_F831C8EF1795EFB7D832C534A0ADA025" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ExercisePriceRangeFourMember" xlink:label="loc_hsy_ExercisePriceRangeFourMember_024366E75964ADD8F1D9C534A0AD98C6" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_EF50456DF2DDE58C0BF5C534A0AC36BC" xlink:to="loc_hsy_ExercisePriceRangeFourMember_024366E75964ADD8F1D9C534A0AD98C6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit_D967A14D4480D5DBCE5AC534A0AEA21B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit_D967A14D4480D5DBCE5AC534A0AEA21B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit_8A76C758443E8874B351C534A0AEDDB7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit_8A76C758443E8874B351C534A0AEDDB7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions_A6AB43166C437D1C0DAFC534A0AEB935" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions_A6AB43166C437D1C0DAFC534A0AEB935" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2_09A6D616C22DEEB82CD4C534A0AE3A90" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2_09A6D616C22DEEB82CD4C534A0AE3A90" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1_79166E281A9B21472D96C534A0AEFC91" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1_79166E281A9B21472D96C534A0AEFC91" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions_28E0FC08DBE1A627EB32C534A0AF2F22" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions_28E0FC08DBE1A627EB32C534A0AF2F22" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1_2BFE8357F45060121CF0C534A0AF733F" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_FD62CBF80C23BFFC50DBC534A0AD29C5" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1_2BFE8357F45060121CF0C534A0AF733F" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C9BD112B935F629E7E02C534A0C664AF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C9BD112B935F629E7E02C534A0C664AF" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_DB94BDD11C4653B96384C534A0C6C407" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C9BD112B935F629E7E02C534A0C664AF" xlink:to="loc_us-gaap_AwardTypeAxis_DB94BDD11C4653B96384C534A0C6C407" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_DB94BDD11C4653B96384C534A0C6C407" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_DB94BDD11C4653B96384C534A0C6C407" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_D5B10C767FFF6B0C4A4DC534A0C62974" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1" xlink:to="loc_us-gaap_EmployeeStockOptionMember_D5B10C767FFF6B0C4A4DC534A0C62974" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PerformanceSharesMember" xlink:label="loc_us-gaap_PerformanceSharesMember_65CB3628D2BA4DE8F6A5C534A0C7EC4C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1" xlink:to="loc_us-gaap_PerformanceSharesMember_65CB3628D2BA4DE8F6A5C534A0C7EC4C" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PerformanceStockUnitsandRestrictedStockUnitsMember" xlink:label="loc_hsy_PerformanceStockUnitsandRestrictedStockUnitsMember_3381EDD7E0C3E94811E4C534A0C79C05" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C9420FCFF5A4220E922FC534A0C658C1" xlink:to="loc_hsy_PerformanceStockUnitsandRestrictedStockUnitsMember_3381EDD7E0C3E94811E4C534A0C79C05" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_5F7A00E92F393A1BF1F9C534A0C7CD87" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_C9BD112B935F629E7E02C534A0C664AF" xlink:to="loc_srt_RangeAxis_5F7A00E92F393A1BF1F9C534A0C7CD87" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_3F4E9C61FE1D3B09EC1EC534A0C7A0A4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_5F7A00E92F393A1BF1F9C534A0C7CD87" xlink:to="loc_srt_RangeMember_3F4E9C61FE1D3B09EC1EC534A0C7A0A4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_3F4E9C61FE1D3B09EC1EC534A0C7A0A4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_5F7A00E92F393A1BF1F9C534A0C7CD87" xlink:to="loc_srt_RangeMember_3F4E9C61FE1D3B09EC1EC534A0C7A0A4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_6E6B71CC6273425E2643C534A0C8480A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_3F4E9C61FE1D3B09EC1EC534A0C7A0A4" xlink:to="loc_srt_MinimumMember_6E6B71CC6273425E2643C534A0C8480A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_DD9781080A151F93DE09C534A0C8639B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_3F4E9C61FE1D3B09EC1EC534A0C7A0A4" xlink:to="loc_srt_MaximumMember_DD9781080A151F93DE09C534A0C8639B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized_F4A1A2E2EC90BEBB22B2C534A0C8C5D2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized_F4A1A2E2EC90BEBB22B2C534A0C8C5D2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_8948A4C36806F1205D0DC534A0C945A4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_8948A4C36806F1205D0DC534A0C945A4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_B6C017067EF8A934558BC534A0C9CF98" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_B6C017067EF8A934558BC534A0C9CF98" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod" xlink:label="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_B5AE1F55A5FFE59A741FC534A0C96F36" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_B5AE1F55A5FFE59A741FC534A0C96F36" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_8E0FA7145ED951CAD347C534A0C988F4" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_8E0FA7145ED951CAD347C534A0C988F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_1E035B991F24C177496FC534A0C9E22F" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_1E035B991F24C177496FC534A0C9E22F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_39A684F05E2C02BC0D6FC534A0C9AC67" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_39A684F05E2C02BC0D6FC534A0C9AC67" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions_749B96571B1C37C46C57C534A0C97567" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions_749B96571B1C37C46C57C534A0C97567" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage_79F977238701FBF81242C534A0CAA842" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage_79F977238701FBF81242C534A0CAA842" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested_37A09795CFE590400CBDC534A0CAF038" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested_37A09795CFE590400CBDC534A0CAF038" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued" xlink:label="loc_us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued_B7009D5AD9AA044BD7A7C534A0CAC774" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued_B7009D5AD9AA044BD7A7C534A0CAC774" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_DeferredCompensationArrangementwithIndividualConversionBasis" xlink:label="loc_hsy_DeferredCompensationArrangementwithIndividualConversionBasis_668812A360B272D96A87C534A0CA0A7C" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_F533A6F2E671D1252BF5C534A0C8C67A" xlink:to="loc_hsy_DeferredCompensationArrangementwithIndividualConversionBasis_668812A360B272D96A87C534A0CA0A7C" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EntityWideRevenueMajorCustomerLineItems" xlink:label="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_9F80C8B8CC7DDAD7E630C532DA435D17" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable" xlink:label="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_A26E0B02CEA46A40023BC532DA409BB4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_9F80C8B8CC7DDAD7E630C532DA435D17" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_A26E0B02CEA46A40023BC532DA409BB4" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MajorCustomersAxis" xlink:label="loc_srt_MajorCustomersAxis_110DB79B6A72513BA9A2C532DA40A862" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_A26E0B02CEA46A40023BC532DA409BB4" xlink:to="loc_srt_MajorCustomersAxis_110DB79B6A72513BA9A2C532DA40A862" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_BB1BBD4F540FEAC6F0D9C532DA41EFFD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_MajorCustomersAxis_110DB79B6A72513BA9A2C532DA40A862" xlink:to="loc_srt_NameOfMajorCustomerDomain_BB1BBD4F540FEAC6F0D9C532DA41EFFD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_BB1BBD4F540FEAC6F0D9C532DA41EFFD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_MajorCustomersAxis_110DB79B6A72513BA9A2C532DA40A862" xlink:to="loc_srt_NameOfMajorCustomerDomain_BB1BBD4F540FEAC6F0D9C532DA41EFFD" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_McLaneCompanyInc.Member" xlink:label="loc_hsy_McLaneCompanyInc.Member_CC0D92C5FE40DB8C3696C532DA417041" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_NameOfMajorCustomerDomain_BB1BBD4F540FEAC6F0D9C532DA41EFFD" xlink:to="loc_hsy_McLaneCompanyInc.Member_CC0D92C5FE40DB8C3696C532DA417041" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_0D699DEC1A58C999C996C532DA41C795" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_A26E0B02CEA46A40023BC532DA409BB4" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_0D699DEC1A58C999C996C532DA41C795" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_DEAC9614BFEC34D41F21C532DA42E14C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_0D699DEC1A58C999C996C532DA41C795" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_DEAC9614BFEC34D41F21C532DA42E14C_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_DEAC9614BFEC34D41F21C532DA42E14C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_0D699DEC1A58C999C996C532DA41C795" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_DEAC9614BFEC34D41F21C532DA42E14C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CustomerConcentrationRiskMember" xlink:label="loc_us-gaap_CustomerConcentrationRiskMember_9E99F3107BB09F3F3D9DC532DA42D991" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_DEAC9614BFEC34D41F21C532DA42E14C" xlink:to="loc_us-gaap_CustomerConcentrationRiskMember_9E99F3107BB09F3F3D9DC532DA42D991" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_09A55533759FBFBC7C4EC532DA423128" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_A26E0B02CEA46A40023BC532DA409BB4" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_09A55533759FBFBC7C4EC532DA423128" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_4223F6C74E9CE29E89B9C532DA4209DD_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_09A55533759FBFBC7C4EC532DA423128" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_4223F6C74E9CE29E89B9C532DA4209DD_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_4223F6C74E9CE29E89B9C532DA4209DD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_09A55533759FBFBC7C4EC532DA423128" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_4223F6C74E9CE29E89B9C532DA4209DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccountsReceivableMember" xlink:label="loc_us-gaap_AccountsReceivableMember_0B48182E7FF0BF71989FC532DA43D203" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_4223F6C74E9CE29E89B9C532DA4209DD" xlink:to="loc_us-gaap_AccountsReceivableMember_0B48182E7FF0BF71989FC532DA43D203" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_549D60F2C093E8E37DFEC532DA438BC7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_9F80C8B8CC7DDAD7E630C532DA435D17" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_549D60F2C093E8E37DFEC532DA438BC7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent" xlink:label="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_D204B4BF78C912282544C532DA486210" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_9F80C8B8CC7DDAD7E630C532DA435D17" xlink:to="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_D204B4BF78C912282544C532DA486210" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_C73812FB0FFA64680F16C532D4CF884D" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_F0C1C55C506DD28EF555C532D4CD3147" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_C73812FB0FFA64680F16C532D4CF884D" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_F0C1C55C506DD28EF555C532D4CD3147" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_01FFC165E374FE706DC9C532D4CDD18C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_F0C1C55C506DD28EF555C532D4CD3147" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_01FFC165E374FE706DC9C532D4CDD18C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_48388DCA36AF978BF007C532D4CDE18E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_01FFC165E374FE706DC9C532D4CDD18C" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_48388DCA36AF978BF007C532D4CDE18E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_48388DCA36AF978BF007C532D4CDE18E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_01FFC165E374FE706DC9C532D4CDD18C" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_48388DCA36AF978BF007C532D4CDE18E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SoftwareAndSoftwareDevelopmentCostsMember" xlink:label="loc_us-gaap_SoftwareAndSoftwareDevelopmentCostsMember_892507C42CA1AF00ED0DC532D4CE53E9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_48388DCA36AF978BF007C532D4CDE18E" xlink:to="loc_us-gaap_SoftwareAndSoftwareDevelopmentCostsMember_892507C42CA1AF00ED0DC532D4CE53E9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_9C3596754AA7AC08DD6EC532D4CE60CD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_F0C1C55C506DD28EF555C532D4CD3147" xlink:to="loc_srt_RangeAxis_9C3596754AA7AC08DD6EC532D4CE60CD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_AD54C4474EFDF04DD91CC532D4CEBD8A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_9C3596754AA7AC08DD6EC532D4CE60CD" xlink:to="loc_srt_RangeMember_AD54C4474EFDF04DD91CC532D4CEBD8A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_AD54C4474EFDF04DD91CC532D4CEBD8A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_9C3596754AA7AC08DD6EC532D4CE60CD" xlink:to="loc_srt_RangeMember_AD54C4474EFDF04DD91CC532D4CEBD8A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_BEA78C17C3657CC157F3C532D4CF2B45" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_AD54C4474EFDF04DD91CC532D4CEBD8A" xlink:to="loc_srt_MinimumMember_BEA78C17C3657CC157F3C532D4CF2B45" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_6215DD93D4FAB42E076FC532D4CF91D8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_AD54C4474EFDF04DD91CC532D4CEBD8A" xlink:to="loc_srt_MaximumMember_6215DD93D4FAB42E076FC532D4CF91D8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CapitalizedComputerSoftwareNet" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareNet_A446883FC6BEBBB447BDC532D4CF5901" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_C73812FB0FFA64680F16C532D4CF884D" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareNet_A446883FC6BEBBB447BDC532D4CF5901" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_C1CA9D9B1C9A3F63AC58C532D4CF4535" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_C73812FB0FFA64680F16C532D4CF884D" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_C1CA9D9B1C9A3F63AC58C532D4CF4535" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization_972B52BEBFE16B73BBEFC532D4D05298" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_C73812FB0FFA64680F16C532D4CF884D" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization_972B52BEBFE16B73BBEFC532D4D05298" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_24B44E46B4480338CA8CC532D6DBAAA5" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5C27633AD287035B014BC532D6D8134B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_24B44E46B4480338CA8CC532D6DBAAA5" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5C27633AD287035B014BC532D6D8134B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_77EE233AF71EA3B60715C532D6D8B732" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5C27633AD287035B014BC532D6D8134B" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_77EE233AF71EA3B60715C532D6D8B732" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_080D2D25FD73110E6E7CC532D6D965BC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_77EE233AF71EA3B60715C532D6D8B732" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_080D2D25FD73110E6E7CC532D6D965BC_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_080D2D25FD73110E6E7CC532D6D965BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_77EE233AF71EA3B60715C532D6D8B732" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_080D2D25FD73110E6E7CC532D6D965BC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_MachineryAndEquipmentMember" xlink:label="loc_us-gaap_MachineryAndEquipmentMember_BC396B035B0022DBA75FC532D6D9DB75" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_080D2D25FD73110E6E7CC532D6D965BC" xlink:to="loc_us-gaap_MachineryAndEquipmentMember_BC396B035B0022DBA75FC532D6D9DB75" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_BuildingAndBuildingImprovementsMember" xlink:label="loc_us-gaap_BuildingAndBuildingImprovementsMember_B6464DD343BB08F1913FC532D6D9647C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_080D2D25FD73110E6E7CC532D6D965BC" xlink:to="loc_us-gaap_BuildingAndBuildingImprovementsMember_B6464DD343BB08F1913FC532D6D9647C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeAxis" xlink:label="loc_srt_RangeAxis_C5C3ED8DBB30A7CF7B59C532D6DAA031" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_5C27633AD287035B014BC532D6D8134B" xlink:to="loc_srt_RangeAxis_C5C3ED8DBB30A7CF7B59C532D6DAA031" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_CFB79C10AE3E044AF568C532D6DA7DB4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_RangeAxis_C5C3ED8DBB30A7CF7B59C532D6DAA031" xlink:to="loc_srt_RangeMember_CFB79C10AE3E044AF568C532D6DA7DB4_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_RangeMember" xlink:label="loc_srt_RangeMember_CFB79C10AE3E044AF568C532D6DA7DB4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_RangeAxis_C5C3ED8DBB30A7CF7B59C532D6DAA031" xlink:to="loc_srt_RangeMember_CFB79C10AE3E044AF568C532D6DA7DB4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MinimumMember" xlink:label="loc_srt_MinimumMember_42FDE41A95F4B1B1D54BC532D6DA88D8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_CFB79C10AE3E044AF568C532D6DA7DB4" xlink:to="loc_srt_MinimumMember_42FDE41A95F4B1B1D54BC532D6DA88D8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MaximumMember" xlink:label="loc_srt_MaximumMember_C791951040A4838E2E04C532D6DAA0E2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_RangeMember_CFB79C10AE3E044AF568C532D6DA7DB4" xlink:to="loc_srt_MaximumMember_C791951040A4838E2E04C532D6DAA0E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_E9AFDEF7F7599F7F1970C532D6E0FF53" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_24B44E46B4480338CA8CC532D6DBAAA5" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_E9AFDEF7F7599F7F1970C532D6E0FF53" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_CapitalLeasedAssetsNet" xlink:label="loc_hsy_CapitalLeasedAssetsNet_D2FCAA2FD4DEE08E39F7C532D6E052E8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_24B44E46B4480338CA8CC532D6DBAAA5" xlink:to="loc_hsy_CapitalLeasedAssetsNet_D2FCAA2FD4DEE08E39F7C532D6E052E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_Depreciation" xlink:label="loc_us-gaap_Depreciation_5A4E0207BB9283E24902C532D6E1876C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_24B44E46B4480338CA8CC532D6DBAAA5" xlink:to="loc_us-gaap_Depreciation_5A4E0207BB9283E24902C532D6E1876C" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems" xlink:label="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable" xlink:label="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_3C6F5A9CC978C7811BCBC532D2E5059B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_3C6F5A9CC978C7811BCBC532D2E5059B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AdjustmentsForNewAccountingPronouncementsAxis" xlink:label="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5A759303FD70004C3AD1C532D2E6A14C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_3C6F5A9CC978C7811BCBC532D2E5059B" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5A759303FD70004C3AD1C532D2E6A14C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5A759303FD70004C3AD1C532D2E6A14C" xlink:to="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5A759303FD70004C3AD1C532D2E6A14C" xlink:to="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccountingStandardsUpdate201707Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201707Member_EF88073561BADC0D63DEC532D2E680D3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A" xlink:to="loc_us-gaap_AccountingStandardsUpdate201707Member_EF88073561BADC0D63DEC532D2E680D3" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_AccountingStandardsUpdate201609ExcessTaxBenefitComponentMember" xlink:label="loc_hsy_AccountingStandardsUpdate201609ExcessTaxBenefitComponentMember_5A7DD6ADDA55BB552CE0C532D2E70ED6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A" xlink:to="loc_hsy_AccountingStandardsUpdate201609ExcessTaxBenefitComponentMember_5A7DD6ADDA55BB552CE0C532D2E70ED6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_AccountingStandardsUpdate201602Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201602Member_25845AE09131AB5E7854C532D2E74A94" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_27E64B132910D697DDD6C532D2E6C70A" xlink:to="loc_us-gaap_AccountingStandardsUpdate201602Member_25845AE09131AB5E7854C532D2E74A94" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_DE28BBBCA7E8CE5D28CEC532D2E75AFA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_3C6F5A9CC978C7811BCBC532D2E5059B" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_DE28BBBCA7E8CE5D28CEC532D2E75AFA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_30D7B0422A6C36ED10A8C532D2E873BF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_DE28BBBCA7E8CE5D28CEC532D2E75AFA" xlink:to="loc_us-gaap_EquityComponentDomain_30D7B0422A6C36ED10A8C532D2E873BF_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_30D7B0422A6C36ED10A8C532D2E873BF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_DE28BBBCA7E8CE5D28CEC532D2E75AFA" xlink:to="loc_us-gaap_EquityComponentDomain_30D7B0422A6C36ED10A8C532D2E873BF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_E60591BBD7A3CE14227AC532D2E8A9AE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_30D7B0422A6C36ED10A8C532D2E873BF" xlink:to="loc_us-gaap_RetainedEarningsMember_E60591BBD7A3CE14227AC532D2E8A9AE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CostOfGoodsAndServicesSold" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_D71E0D404879BFC09EEFC532D2E96C5F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_D71E0D404879BFC09EEFC532D2E96C5F" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_TaxCutsandJobsActof2017ReclassificationfromAOCItoRetainedEarnings" xlink:label="loc_hsy_TaxCutsandJobsActof2017ReclassificationfromAOCItoRetainedEarnings_6486AC2FA60CF5DACDDFC532D2E99B76" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_hsy_TaxCutsandJobsActof2017ReclassificationfromAOCItoRetainedEarnings_6486AC2FA60CF5DACDDFC532D2E99B76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpense" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_1DFA0FE54FFFDC720E26C532D2E93879" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_1DFA0FE54FFFDC720E26C532D2E93879" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_RestructuringChargesBusinessRealignment" xlink:label="loc_hsy_RestructuringChargesBusinessRealignment_F25E119E899079DE703FC532D2E96A94" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_hsy_RestructuringChargesBusinessRealignment_F25E119E899079DE703FC532D2E96A94" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_0F7367F6EF574935DE85C532D2E9D520" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_0F7367F6EF574935DE85C532D2E9D520" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_15DEE71C7C4275CABF3FC532D2E9B5BE" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_15DEE71C7C4275CABF3FC532D2E9B5BE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_D0E3BDD81A409A3AF735C532D2EA3F0C" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_D0E3BDD81A409A3AF735C532D2EA3F0C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingLeaseRightOfUseAsset" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_A37AEFE388FA1C1CE2ECC532D2EAFFD5" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_A37AEFE388FA1C1CE2ECC532D2EAFFD5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_OperatingLeaseLiability" xlink:label="loc_us-gaap_OperatingLeaseLiability_CE205EB5E25857EDAEBDC532D2EA8F73" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_OperatingLeaseLiability_CE205EB5E25857EDAEBDC532D2EA8F73" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_E93A717426E964BFD082C532D2EA0E56" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E3A400C958B17D08E8B7C532D2E883D2" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_E93A717426E964BFD082C532D2EA0E56" 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/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_32C6E07B611E5FA01A54C532DDC15F0F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_4A67F67F76D630DA1473C532DDBEDBB3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_32C6E07B611E5FA01A54C532DDC15F0F" xlink:to="loc_us-gaap_StatementTable_4A67F67F76D630DA1473C532DDBEDBB3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_73523678FB5C2B6429E8C532DDBE39CE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_4A67F67F76D630DA1473C532DDBEDBB3" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_73523678FB5C2B6429E8C532DDBE39CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D0979C26092F550343BC532DDBEFD3A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_73523678FB5C2B6429E8C532DDBE39CE" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D0979C26092F550343BC532DDBEFD3A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D0979C26092F550343BC532DDBEFD3A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_73523678FB5C2B6429E8C532DDBE39CE" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D0979C26092F550343BC532DDBEFD3A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_SalesRevenueGoodsNetMember" xlink:label="loc_us-gaap_SalesRevenueGoodsNetMember_BF986901549E8E8931F6C532DDBFA48B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_5D0979C26092F550343BC532DDBEFD3A" xlink:to="loc_us-gaap_SalesRevenueGoodsNetMember_BF986901549E8E8931F6C532DDBFA48B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_2CC7BF7F1B5449AB0405C532DDBFED76" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_4A67F67F76D630DA1473C532DDBEDBB3" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_2CC7BF7F1B5449AB0405C532DDBFED76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_9F45232D4741A54B9F5BC532DDBF4713_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_2CC7BF7F1B5449AB0405C532DDBFED76" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_9F45232D4741A54B9F5BC532DDBF4713_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_9F45232D4741A54B9F5BC532DDBF4713" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_2CC7BF7F1B5449AB0405C532DDBFED76" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_9F45232D4741A54B9F5BC532DDBF4713" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_CustomerConcentrationRiskMember" xlink:label="loc_us-gaap_CustomerConcentrationRiskMember_3B4E0D6EDE7F10D14E78C532DDC0BDB2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_9F45232D4741A54B9F5BC532DDBF4713" xlink:to="loc_us-gaap_CustomerConcentrationRiskMember_3B4E0D6EDE7F10D14E78C532DDC0BDB2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_MajorCustomersAxis" xlink:label="loc_srt_MajorCustomersAxis_424C4C5D4F2B1D7D2480C532DDC05BD1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_4A67F67F76D630DA1473C532DDBEDBB3" xlink:to="loc_srt_MajorCustomersAxis_424C4C5D4F2B1D7D2480C532DDC05BD1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_7CBA62418753A933A874C532DDC09BE5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_srt_MajorCustomersAxis_424C4C5D4F2B1D7D2480C532DDC05BD1" xlink:to="loc_srt_NameOfMajorCustomerDomain_7CBA62418753A933A874C532DDC09BE5_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/srt/2018/elts/srt-2018-01-31.xsd#srt_NameOfMajorCustomerDomain" xlink:label="loc_srt_NameOfMajorCustomerDomain_7CBA62418753A933A874C532DDC09BE5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_srt_MajorCustomersAxis_424C4C5D4F2B1D7D2480C532DDC05BD1" xlink:to="loc_srt_NameOfMajorCustomerDomain_7CBA62418753A933A874C532DDC09BE5" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_McLaneCompanyInc.Member" xlink:label="loc_hsy_McLaneCompanyInc.Member_77D249305664A316489DC532DDC0B049" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_srt_NameOfMajorCustomerDomain_7CBA62418753A933A874C532DDC09BE5" xlink:to="loc_hsy_McLaneCompanyInc.Member_77D249305664A316489DC532DDC0B049" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_PromotionalCostsEstimateDeviationPercentage" xlink:label="loc_hsy_PromotionalCostsEstimateDeviationPercentage_D38B48EEE15134FFA6E5C53434E8D348" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_32C6E07B611E5FA01A54C532DDC15F0F" xlink:to="loc_hsy_PromotionalCostsEstimateDeviationPercentage_D38B48EEE15134FFA6E5C53434E8D348" xlink:type="arc" />
    <link:loc xlink:href="hsy-20181231.xsd#hsy_UnsettledAccruedLiabilities" xlink:label="loc_hsy_UnsettledAccruedLiabilities_18B6878F867F208636EBC5381B10EF7A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_32C6E07B611E5FA01A54C532DDC15F0F" xlink:to="loc_hsy_UnsettledAccruedLiabilities_18B6878F867F208636EBC5381B10EF7A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2018/elts/us-gaap-2018-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_247FD8A11C637C45CFF9C532DDC1FED3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_32C6E07B611E5FA01A54C532DDC15F0F" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_247FD8A11C637C45CFF9C532DDC1FED3" 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/SummaryOfSignificantAccountingPoliciesTables" 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/SupplementalBalanceSheetInformationTables" xlink:type="extended" />
</link:linkbase>




