SEC Info  
    Home      Search      My Interests      Help      Sign In      Please Sign In

Hershey Co – ‘8-K’ for 5/25/18 – ‘EX-101.DEF’

On:  Friday, 5/25/18, at 4:24pm ET   ·   For:  5/25/18   ·   Accession #:  47111-18-29   ·   File #:  1-00183

Previous ‘8-K’:  ‘8-K’ on / for 5/10/18   ·   Next:  ‘8-K’ on / for 7/26/18   ·   Latest:  ‘8-K’ on 2/8/24 for 2/2/24

Find Words in Filings emoji
 
  in    Show  and   Hints

  As Of               Filer                 Filing    For·On·As Docs:Size

 5/25/18  Hershey Co                        8-K:8,9     5/25/18  136:17M

Current Report   —   Form 8-K   —   Sect. 13 / 15(d) – SEA’34
Filing Table of Contents

Document/Exhibit                   Description                      Pages   Size 

 1: 8-K         Form 8-K Dated May 25, 2018                         HTML     75K 
 2: EX-23.1     Exhibit 23.1 - Consent of Ernst & Young LLP         HTML     43K 
 3: EX-23.2     Exhibit 23.2 - Consent of Kpmg LLP                  HTML     43K 
 4: EX-99.1     Exhibit 99.1 - Part Ii, Item 6 of the Hershey       HTML     85K 
                Company's 2017 Form 10-K                                         
 5: EX-99.2     Exhibit 99.2 - Part Ii, Item 7 of the Hershey       HTML    326K 
                Company's 2017 Form 10-K                                         
 6: EX-99.3     Exhibit 99.3 - Part Ii, Item 8 of the Hershey       HTML    849K 
                Company's 2017 Form 10-K                                         
13: R1          Document and Entity Information                     HTML     72K 
14: R2          Consolidated Statements of Income                   HTML    108K 
15: R3          Consolidated Statements of Comprehensive Income     HTML    115K 
16: R4          Consolidated Balance Sheets                         HTML    134K 
17: R5          Consolidated Balance Sheets (Parenthetical)         HTML     49K 
18: R6          Consolidated Statements of Cash Flows               HTML    145K 
19: R7          Consolidated Statements of Stockholders' Equity     HTML     97K 
20: R8          Consolidated Statements of Stockholders' Equity     HTML     47K 
                (Parenthetical)                                                  
21: R9          Summary of Significant Accounting Policies          HTML    105K 
22: R10         Business Acquisitions and Divestitures              HTML     64K 
23: R11         Goodwill and Intangible Assets                      HTML    112K 
24: R12         Short and Long-Term Debt                            HTML     97K 
25: R13         Derivative Instruments                              HTML    134K 
26: R14         Fair Value Measurements Fair Value Measurements     HTML    120K 
27: R15         Business Realignment Activities                     HTML    110K 
28: R16         Income Taxes                                        HTML    180K 
29: R17         Pension and Other Post-Retirement Benefit Plans     HTML    382K 
30: R18         Stock Compensation Plans                            HTML    139K 
31: R19         Segment Information                                 HTML    135K 
32: R20         Equity and Noncontrolling Interest                  HTML     78K 
33: R21         Commitments and Contingencies                       HTML     71K 
34: R22         Earnings Per Share                                  HTML    154K 
35: R23         Other (Income) Expense, Net Other (Income)          HTML     59K 
                Expense, Net                                                     
36: R24         Supplemental Balance Sheet Information              HTML    107K 
37: R25         Quarterly Data (Unaudited)                          HTML    124K 
38: R26         Subsequent Events Subsequent Events                 HTML     48K 
39: R27         Schedule Ii - Valuation and Qualifying Accounts     HTML    127K 
40: R28         Summary of Significant Accounting Policies          HTML    159K 
                (Policies)                                                       
41: R29         Summary of Significant Accounting Policies          HTML     58K 
                (Tables)                                                         
42: R30         Business Acquisitions and Divestitures (Tables)     HTML     57K 
43: R31         Goodwill and Intangible Assets (Tables)             HTML    107K 
44: R32         Short and Long-Term Debt (Tables)                   HTML     94K 
45: R33         Derivative Instruments (Tables)                     HTML    124K 
46: R34         Fair Value Measurements Fair Value Measurements     HTML    118K 
                (Tables)                                                         
47: R35         Business Realignment Activities (Tables)            HTML    101K 
48: R36         Income Taxes (Tables)                               HTML    176K 
49: R37         Pension and Other Post-Retirement Benefit Plans     HTML    384K 
                (Tables)                                                         
50: R38         Stock Compensation Plans (Tables)                   HTML    138K 
51: R39         Segment Information (Tables)                        HTML    138K 
52: R40         Equity and Noncontrolling Interest (Tables)         HTML     73K 
53: R41         Commitments and Contingencies (Tables)              HTML     84K 
54: R42         Earnings Per Share (Tables)                         HTML    153K 
55: R43         Other (Income) Expense, Net Other (Income)          HTML     59K 
                Expense, Net (Tables)                                            
56: R44         Supplemental Balance Sheet Information (Tables)     HTML    107K 
57: R45         Quarterly Data (Tables)                             HTML    124K 
58: R46         Summary of Significant Accounting Policies -        HTML     45K 
                Description of Business and Basis of Presentation                
                (Details)                                                        
59: R47         Summary of Significant Accounting Policies -        HTML     45K 
                Revenue Recognition (Details)                                    
60: R48         Summary of Significant Accounting Policies -        HTML     50K 
                Selling, Marketing and Administrative Expense                    
                (Details)                                                        
61: R49         Summary of Significant Accounting Policies -        HTML     52K 
                Accounts Receivable - Trade (Details)                            
62: R50         Summary of Significant Accounting Policies -        HTML     44K 
                Inventories (Details)                                            
63: R51         Summary of Significant Accounting Policies -        HTML     56K 
                Property, Plant and Equipment (Details)                          
64: R52         Summary of Significant Accounting Policies -        HTML     53K 
                Computer Software (Details)                                      
65: R53         Summary of Significant Accounting Policies -        HTML     47K 
                Goodwill and Other Intangible Assets (Details)                   
66: R54         Summary of Significant Accounting Policies -        HTML     65K 
                Recent Accounting Pronouncements (Details)                       
67: R55         Business Acquisitions and Divestitures - Ripple     HTML     64K 
                Brand Collective, Llc Assets Acquired and                        
                Liabilities Assumed Allocation (Details)                         
68: R56         Business Acquisitions and Divestitures - Ripple     HTML     49K 
                Brand Collective, Llc Narrative (Details)                        
69: R57         Business Acquisitions and Divestitures - Shanghai   HTML     54K 
                Golden Monkey Narrative (Details)                                
70: R58         Business Acquisitions and Divestitures - Krave      HTML     55K 
                Pure Foods Narrative (Details)                                   
71: R59         Business Acquisitions and Divestitures - Krave      HTML     66K 
                Pure Foods Assets Acquired and Liabilities Assumed               
                Allocation (Details)                                             
72: R60         Business Acquisitions and Divestitures - Mauna Loa  HTML     51K 
                Narrative (Details)                                              
73: R61         Goodwill and Intangible Assets - Schedule of        HTML     65K 
                Changes in Carrying Value of Goodwill by                         
                Reportable Segment (Details)                                     
74: R62         Goodwill and Intangible Assets - Goodwill and       HTML     74K 
                Intangible Assets Narrative (Details)                            
75: R63         Goodwill and Intangible Assets - Schedule of Gross  HTML     59K 
                Carrying Amount and Accumulated Amortization for                 
                Each Major Class of Intangible Asset (Details)                   
76: R64         Goodwill and Intangible Assets - Schedule of        HTML     52K 
                Amortization Expense, for the Next Five Years                    
                (Details)                                                        
77: R65         Short and Long-Term Debt - Short-Term Debt          HTML     66K 
                Narrative (Details)                                              
78: R66         Short and Long-Term Debt - Schedule of Long-Term    HTML     70K 
                Debt Instruments (Details)                                       
79: R67         Short and Long-Term Debt - Long Term Debt Interest  HTML     69K 
                Rates (Details)                                                  
80: R68         Short and Long-Term Debt - Long Term Debt           HTML     83K 
                Narrative (Details)                                              
81: R69         Short and Long-Term Debt - Schedule of Maturities   HTML     56K 
                of Long-Term Debt (Details)                                      
82: R70         Short and Long-Term Debt - Schedule of Net          HTML     54K 
                Interest Expense (Details)                                       
83: R71         Derivative Instruments - Derivative Instruments     HTML     80K 
                Narrative (Details)                                              
84: R72         Derivative Instruments - Schedule of the            HTML     70K 
                Classification of Derivative Assets and                          
                Liabilities Within the Consolidated Balance Sheets               
                (Details)                                                        
85: R73         Derivative Instruments - Schedule of the Effect of  HTML     66K 
                Derivative Instruments on the Consolidated                       
                Statements of Income (Details)                                   
86: R74         Fair Value Measurements - Schedule of Assets and    HTML     81K 
                Liabilities Measured at Fair Value (Details)                     
87: R75         Fair Value Measurements - Schedule of Fair Values   HTML     57K 
                and Carrying Values of Long-Term Debt (Details)                  
88: R76         Fair Value Measurements - Fair Value Measurements   HTML     52K 
                Narrative (Details)                                              
89: R77         Business Realignment Activities - Schedule of       HTML     79K 
                Business Realignment Activity (Details)                          
90: R78         Business Realignment Activities - Business          HTML    127K 
                Realignment Activities Narrative (Details)                       
91: R79         Business Realignment Activities - Schedule of       HTML     50K 
                Liability Activity for Costs Qualifying as Exit                  
                and Disposal Costs (Details)                                     
92: R80         Income Taxes - Schedule of Income (Loss) Before     HTML     48K 
                Taxes (Details)                                                  
93: R81         Income Taxes - Schedule of Components of Income     HTML     68K 
                Tax Expense (Benefit) (Details)                                  
94: R82         Income Taxes - Income Taxes Narrative (Details)     HTML     65K 
95: R83         Income Taxes - Schedule of Deferred Tax Asset and   HTML    104K 
                Liabilities (Details)                                            
96: R84         Income Taxes - Schedule of Effective Income Tax     HTML     68K 
                Rate Reconciliation (Details)                                    
97: R85         Income Taxes - Schedule of Unrecognized Tax         HTML     54K 
                Benefits Roll Forward (Details)                                  
98: R86         Pension and Other Post-Retirement Benefit Plans -   HTML     76K 
                Pension and Other Post-Retirement Benefit Plans                  
                Narrative (Details)                                              
99: R87         Pension and Other Post-Retirement Benefit Plans -   HTML    124K 
                Schedule of Defined Benefit Obligations, Plan                    
                Assets and Funded Status (Details)                               
100: R88         Pension and Other Post-Retirement Benefit Plans -   HTML     47K  
                Schedule of Accumulated Benefit Obligations in                   
                Excess of Plan Assets (Details)                                  
101: R89         Pension and Other Post-Retirement Benefit Plans -   HTML     82K  
                Schedule of Components of Net Periodic Benefit                   
                Cost (Details)                                                   
102: R90         Pension and Other Post-Retirement Benefit Plans -   HTML     49K  
                Schedule of Amounts Expected to Be Amortized From                
                Aoci Into Net Periodic Benefit (Details)                         
103: R91         Pension and Other Post-Retirement Benefit Plans -   HTML     49K  
                Schedule of Weighted Average Assumptions Used in                 
                Computing Benefit Obligations (Details)                          
104: R92         Pension and Other Post-Retirement Benefit Plans -   HTML     52K  
                Schedule of Weighted Average Assumptions Used in                 
                Computing Net Periodic Benefit Cost (Details)                    
105: R93         Pension and Other Post-Retirement Benefit Plans -   HTML     49K  
                Schedule of Effect of One Percent Change in                      
                Assumed Health Care Trend Rates (Details)                        
106: R94         Pension and Other Post-Retirement Benefit Plans -   HTML     51K  
                Schedule of Plan Assets Across Asset Classes                     
                (Details)                                                        
107: R95         Pension and Other Post-Retirement Benefit Plans -   HTML    116K  
                Schedule of Pension Plan Assets Within the Fair                  
                Value Hierarchy (Details)                                        
108: R96         Pension and Other Post-Retirement Benefit Plans -   HTML     58K  
                Schedule of Expected Benefit Payments to Be Paid                 
                (Details)                                                        
109: R97         Stock Compensation Plans - Stock Compensation       HTML     82K  
                Plans Narrative (Details)                                        
110: R98         Stock Compensation Plans - Schedule of              HTML     46K  
                Compensation Expense and Income Tax Benefits for                 
                Stock-Based Compensation Programs (Details)                      
111: R99         Stock Compensation Plans - Schedule of Stock        HTML     78K  
                Option Activity (Details)                                        
112: R100        Stock Compensation Plans - Schedule of Fair Value   HTML     50K  
                Weighted-Average Assumptions (Details)                           
113: R101        Stock Compensation Plans - Schedule of Stock        HTML     75K  
                Option Information by Exercise Price Range                       
                (Details)                                                        
114: R102        STOCK COMPENSATION PLANS - SCHEDULE OF PSUs AND     HTML     71K  
                RSUs ACTIVITY (Details)                                          
115: R103        STOCK COMPENSATION PLANS - SCHEDULE OF PSUs AND     HTML     55K  
                RSUS FAIR VALUE WEIGHTED-AVERAGE ASSUMPTIONS                     
                (Details)                                                        
116: R104        Segment Information Narrative (Details)             HTML     59K  
117: R105        Schedule of Net Sales and Earnings by Segment       HTML     86K  
                (Details)                                                        
118: R106        Segment Information - Schedule of Unallocated       HTML     53K  
                Mark-To-Market (Gains) Losses on Commodity                       
                Derivatives (Details)                                            
119: R107        Schedule of Depreciation and Amortization Expense   HTML     52K  
                Included Within Segment Income (Details)                         
120: R108        Schedule of Segment Information by Geography        HTML     56K  
                (Details)                                                        
121: R109        Equity and Noncontrolling Interest - Equity and     HTML     97K  
                Noncontrolling Interest Narrative (Details)                      
122: R110        Equity and Noncontrolling Interest - Schedule of    HTML     64K  
                the Changes in the Outstanding Shares of Commmon                 
                Stock (Details)                                                  
123: R111        Equity and Noncontrolling Interest - Schedule of    HTML     53K  
                Activity Relating to the Noncontrolling Interest                 
                (Details)                                                        
124: R112        Commitments and Contingencies - Schedule of         HTML     53K  
                Purchase Obligations Covered by Putchase                         
                Agreements With Various Suppliers Future Maturty                 
                Schedule (Details)                                               
125: R113        Commitments and Contingencies - Schedule of         HTML     74K  
                Operating and Capital Lease Obligations (Details)                
126: R114        Commitments and Contingencies - Commitments and     HTML     51K  
                Contingencies Narrative (Details)                                
127: R115        Schedule of Basic and Diluted Earnings Per Share    HTML    105K  
                (Details)                                                        
128: R116        Earnings Per Share - Earnings Per Share Narrative   HTML     45K  
                (Details)                                                        
129: R117        Other (Income) Expense, Net - Schedule of Other     HTML     61K  
                (Income) and Expense, Net (Details)                              
130: R118        Schedule of Supplemental Balance Sheet Information  HTML    129K  
                (Details)                                                        
131: R119        Schedule of Quarterly Financial Information         HTML     72K  
                (Details)                                                        
132: R120        Subsequent Events Subsequent Events (Details)       HTML     93K  
133: R121        Schedule Ii - Valuation and Qualifying Accounts     HTML     62K  
                (Details)                                                        
135: XML         IDEA XML File -- Filing Summary                      XML    262K  
134: EXCEL       IDEA Workbook of Financial Reports                  XLSX    173K  
 7: EX-101.INS  XBRL Instance -- hsy-20180525                        XML   5.93M 
 9: EX-101.CAL  XBRL Calculations -- hsy-20180525_cal                XML    399K 
10: EX-101.DEF  XBRL Definitions -- hsy-20180525_def                 XML   1.61M 
11: EX-101.LAB  XBRL Labels -- hsy-20180525_lab                      XML   2.77M 
12: EX-101.PRE  XBRL Presentations -- hsy-20180525_pre               XML   2.07M 
 8: EX-101.SCH  XBRL Schema -- hsy-20180525                          XSD    263K 
136: ZIP         XBRL Zipped Folder -- 0000047111-18-000029-xbrl      Zip    475K  


‘EX-101.DEF’   —   XBRL Definitions — hsy-20180525_def


This Exhibit is an XBRL XML File.


                                                                                                                                                                                
<?xml version="1.0" encoding="windows-1252"?>
<!-- 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/BusinessAcquisitionsAndDivestitures" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestitures" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresKravePureFoodsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresKravePureFoodsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresKravePureFoodsNarrativeDetails" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresKravePureFoodsNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresMaunaLoaNarrativeDetails" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresMaunaLoaNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresRippleBrandCollectiveLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresRippleBrandCollectiveLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresRippleBrandCollectiveLlcNarrativeDetails" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresRippleBrandCollectiveLlcNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresShanghaiGoldenMonkeyNarrativeDetails" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresShanghaiGoldenMonkeyNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresTables" xlink:href="hsy-20180525.xsd#BusinessAcquisitionsAndDivestituresTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivities" xlink:href="hsy-20180525.xsd#BusinessRealignmentActivities" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:href="hsy-20180525.xsd#BusinessRealignmentActivitiesBusinessRealignmentActivitiesNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:href="hsy-20180525.xsd#BusinessRealignmentActivitiesScheduleOfBusinessRealignmentActivityDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:href="hsy-20180525.xsd#BusinessRealignmentActivitiesScheduleOfLiabilityActivityForCostsQualifyingAsExitAndDisposalCostsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/BusinessRealignmentActivitiesTables" xlink:href="hsy-20180525.xsd#BusinessRealignmentActivitiesTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingencies" xlink:href="hsy-20180525.xsd#CommitmentsAndContingencies" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:href="hsy-20180525.xsd#CommitmentsAndContingenciesCommitmentsAndContingenciesNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:href="hsy-20180525.xsd#CommitmentsAndContingenciesScheduleOfOperatingAndCapitalLeaseObligationsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:href="hsy-20180525.xsd#CommitmentsAndContingenciesScheduleOfPurchaseObligationsCoveredByPutchaseAgreementsWithVariousSuppliersFutureMaturtyScheduleDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/CommitmentsAndContingenciesTables" xlink:href="hsy-20180525.xsd#CommitmentsAndContingenciesTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedBalanceSheets" xlink:href="hsy-20180525.xsd#ConsolidatedBalanceSheets" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedBalanceSheetsParenthetical" xlink:href="hsy-20180525.xsd#ConsolidatedBalanceSheetsParenthetical" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfCashFlows" xlink:href="hsy-20180525.xsd#ConsolidatedStatementsOfCashFlows" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfComprehensiveIncome" xlink:href="hsy-20180525.xsd#ConsolidatedStatementsOfComprehensiveIncome" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfIncome" xlink:href="hsy-20180525.xsd#ConsolidatedStatementsOfIncome" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquity" xlink:href="hsy-20180525.xsd#ConsolidatedStatementsOfStockholdersEquity" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:href="hsy-20180525.xsd#ConsolidatedStatementsOfStockholdersEquityParenthetical" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstruments" xlink:href="hsy-20180525.xsd#DerivativeInstruments" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsDerivativeInstrumentsNarrativeDetails" xlink:href="hsy-20180525.xsd#DerivativeInstrumentsDerivativeInstrumentsNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:href="hsy-20180525.xsd#DerivativeInstrumentsScheduleOfClassificationOfDerivativeAssetsAndLiabilitiesWithinConsolidatedBalanceSheetsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:href="hsy-20180525.xsd#DerivativeInstrumentsScheduleOfEffectOfDerivativeInstrumentsOnConsolidatedStatementsOfIncomeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/DerivativeInstrumentsTables" xlink:href="hsy-20180525.xsd#DerivativeInstrumentsTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/DocumentAndEntityInformation" xlink:href="hsy-20180525.xsd#DocumentAndEntityInformation" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShare" xlink:href="hsy-20180525.xsd#EarningsPerShare" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareEarningsPerShareNarrativeDetails" xlink:href="hsy-20180525.xsd#EarningsPerShareEarningsPerShareNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EarningsPerShareTables" xlink:href="hsy-20180525.xsd#EarningsPerShareTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterest" xlink:href="hsy-20180525.xsd#EquityAndNoncontrollingInterest" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:href="hsy-20180525.xsd#EquityAndNoncontrollingInterestEquityAndNoncontrollingInterestNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:href="hsy-20180525.xsd#EquityAndNoncontrollingInterestScheduleOfActivityRelatingToNoncontrollingInterestDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:href="hsy-20180525.xsd#EquityAndNoncontrollingInterestScheduleOfChangesInOutstandingSharesOfCommmonStockDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/EquityAndNoncontrollingInterestTables" xlink:href="hsy-20180525.xsd#EquityAndNoncontrollingInterestTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurements" xlink:href="hsy-20180525.xsd#FairValueMeasurementsFairValueMeasurements" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:href="hsy-20180525.xsd#FairValueMeasurementsFairValueMeasurementsNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsFairValueMeasurementsTables" xlink:href="hsy-20180525.xsd#FairValueMeasurementsFairValueMeasurementsTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:href="hsy-20180525.xsd#FairValueMeasurementsScheduleOfAssetsAndLiabilitiesMeasuredAtFairValueDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:href="hsy-20180525.xsd#FairValueMeasurementsScheduleOfFairValuesAndCarryingValuesOfLongTermDebtDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssets" xlink:href="hsy-20180525.xsd#GoodwillAndIntangibleAssets" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:href="hsy-20180525.xsd#GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:href="hsy-20180525.xsd#GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:href="hsy-20180525.xsd#GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:href="hsy-20180525.xsd#GoodwillAndIntangibleAssetsScheduleOfGrossCarryingAmountAndAccumulatedAmortizationForEachMajorClassOfIntangibleAssetDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsTables" xlink:href="hsy-20180525.xsd#GoodwillAndIntangibleAssetsTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxes" xlink:href="hsy-20180525.xsd#IncomeTaxes" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesIncomeTaxesNarrativeDetails" xlink:href="hsy-20180525.xsd#IncomeTaxesIncomeTaxesNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:href="hsy-20180525.xsd#IncomeTaxesScheduleOfComponentsOfIncomeTaxExpenseBenefitDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:href="hsy-20180525.xsd#IncomeTaxesScheduleOfDeferredTaxAssetAndLiabilitiesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:href="hsy-20180525.xsd#IncomeTaxesScheduleOfEffectiveIncomeTaxRateReconciliationDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:href="hsy-20180525.xsd#IncomeTaxesScheduleOfIncomeLossBeforeTaxesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:href="hsy-20180525.xsd#IncomeTaxesScheduleOfUnrecognizedTaxBenefitsRollForwardDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/IncomeTaxesTables" xlink:href="hsy-20180525.xsd#IncomeTaxesTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:href="hsy-20180525.xsd#OtherIncomeExpenseNetOtherIncomeExpenseNet" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:href="hsy-20180525.xsd#OtherIncomeExpenseNetOtherIncomeExpenseNetTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:href="hsy-20180525.xsd#OtherIncomeExpenseNetScheduleOfOtherIncomeAndExpenseNetDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlans" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlans" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansPensionAndOtherPostRetirementBenefitPlansNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfAccumulatedBenefitObligationsInExcessOfPlanAssetsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfAmountsExpectedToBeAmortizedFromAociIntoNetPeriodicBenefitDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfAmountsExpectedToBeAmortizedFromAociIntoNetPeriodicBenefitDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfComponentsOfNetPeriodicBenefitCostDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfDefinedBenefitObligationsPlanAssetsAndFundedStatusDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfEffectOfOnePercentChangeInAssumedHealthCareTrendRatesDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfEffectOfOnePercentChangeInAssumedHealthCareTrendRatesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfExpectedBenefitPaymentsToBePaidDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfPensionPlanAssetsWithinFairValueHierarchyDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfPlanAssetsAcrossAssetClassesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingBenefitObligationsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansScheduleOfWeightedAverageAssumptionsUsedInComputingNetPeriodicBenefitCostDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/PensionAndOtherPostRetirementBenefitPlansTables" xlink:href="hsy-20180525.xsd#PensionAndOtherPostRetirementBenefitPlansTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataTables" xlink:href="hsy-20180525.xsd#QuarterlyDataTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/QuarterlyDataUnaudited" xlink:href="hsy-20180525.xsd#QuarterlyDataUnaudited" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccounts" xlink:href="hsy-20180525.xsd#ScheduleIiValuationAndQualifyingAccounts" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsDetails" xlink:href="hsy-20180525.xsd#ScheduleIiValuationAndQualifyingAccountsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:href="hsy-20180525.xsd#ScheduleOfBasicAndDilutedEarningsPerShareDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:href="hsy-20180525.xsd#ScheduleOfDepreciationAndAmortizationExpenseIncludedWithinSegmentIncomeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:href="hsy-20180525.xsd#ScheduleOfNetSalesAndEarningsBySegmentDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfQuarterlyFinancialInformationDetails" xlink:href="hsy-20180525.xsd#ScheduleOfQuarterlyFinancialInformationDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfSegmentInformationByGeographyDetails" xlink:href="hsy-20180525.xsd#ScheduleOfSegmentInformationByGeographyDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ScheduleOfSupplementalBalanceSheetInformationDetails" xlink:href="hsy-20180525.xsd#ScheduleOfSupplementalBalanceSheetInformationDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformation" xlink:href="hsy-20180525.xsd#SegmentInformation" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationNarrativeDetails" xlink:href="hsy-20180525.xsd#SegmentInformationNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:href="hsy-20180525.xsd#SegmentInformationScheduleOfUnallocatedMarkToMarketGainsLossesOnCommodityDerivativesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SegmentInformationTables" xlink:href="hsy-20180525.xsd#SegmentInformationTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebt" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebt" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtLongTermDebtInterestRatesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtLongTermDebtNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtScheduleOfLongTermDebtInstrumentsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtScheduleOfMaturitiesOfLongTermDebtDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtScheduleOfNetInterestExpenseDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtShortTermDebtNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/ShortAndLongTermDebtTables" xlink:href="hsy-20180525.xsd#ShortAndLongTermDebtTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlans" xlink:href="hsy-20180525.xsd#StockCompensationPlans" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansScheduleOfCompensationExpenseAndIncomeTaxBenefitsForStockBasedCompensationProgramsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansScheduleOfFairValueWeightedAverageAssumptionsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansScheduleOfPsusAndRsusActivityDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansScheduleOfPsusAndRsusFairValueWeightedAverageAssumptionsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansScheduleOfStockOptionActivityDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansScheduleOfStockOptionInformationByExercisePriceRangeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:href="hsy-20180525.xsd#StockCompensationPlansStockCompensationPlansNarrativeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/StockCompensationPlansTables" xlink:href="hsy-20180525.xsd#StockCompensationPlansTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SubsequentEventsSubsequentEvents" xlink:href="hsy-20180525.xsd#SubsequentEventsSubsequentEvents" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SubsequentEventsSubsequentEventsDetails" xlink:href="hsy-20180525.xsd#SubsequentEventsSubsequentEventsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SubsequentEventsSubsequentEventsTables" xlink:href="hsy-20180525.xsd#SubsequentEventsSubsequentEventsTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPolicies" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPolicies" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesAccountsReceivableTradeDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesComputerSoftwareDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesDescriptionOfBusinessAndBasisOfPresentationDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesGoodwillAndOtherIntangibleAssetsDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesGoodwillAndOtherIntangibleAssetsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesInventoriesDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesPropertyPlantAndEquipmentDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesRecentAccountingPronouncementsDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesRevenueRecognitionDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesSellingMarketingAndAdministrativeExpenseDetails" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SummaryOfSignificantAccountingPoliciesTables" xlink:href="hsy-20180525.xsd#SummaryOfSignificantAccountingPoliciesTables" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformation" xlink:href="hsy-20180525.xsd#SupplementalBalanceSheetInformation" xlink:type="simple"/>
<link:roleRef roleURI="http://www.hersheys.com/role/SupplementalBalanceSheetInformationTables" xlink:href="hsy-20180525.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/BusinessAcquisitionsAndDivestitures" xlink:type="extended"/>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresKravePureFoodsAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_C20896AB12E72C6AB26E08C41B8CFBAB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_C20896AB12E72C6AB26E08C41B8CFBAB" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_C56C6DE552BDCD0B533008C41B8C64CA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_C20896AB12E72C6AB26E08C41B8CFBAB" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_C56C6DE552BDCD0B533008C41B8C64CA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F4B61172819FDFBEA1EF08C41B8CA038_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_C56C6DE552BDCD0B533008C41B8C64CA" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F4B61172819FDFBEA1EF08C41B8CA038_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F4B61172819FDFBEA1EF08C41B8CA038" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_C56C6DE552BDCD0B533008C41B8C64CA" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F4B61172819FDFBEA1EF08C41B8CA038" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_KRAVEPureFoodsInc.Member" xlink:label="loc_hsy_KRAVEPureFoodsInc.Member_59132ED6CAC61B9764CA08C41B8CE54D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_F4B61172819FDFBEA1EF08C41B8CA038" xlink:to="loc_hsy_KRAVEPureFoodsInc.Member_59132ED6CAC61B9764CA08C41B8CE54D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C376B1D78D2666252FFE08C41B8C7364" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_C20896AB12E72C6AB26E08C41B8CFBAB" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C376B1D78D2666252FFE08C41B8C7364" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1833CF263DA37E3429B208C41B8C6EBC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C376B1D78D2666252FFE08C41B8C7364" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1833CF263DA37E3429B208C41B8C6EBC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1833CF263DA37E3429B208C41B8C6EBC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_C376B1D78D2666252FFE08C41B8C7364" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1833CF263DA37E3429B208C41B8C6EBC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_1E95ACF1E760A24B3DE808C41B8C73F5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1833CF263DA37E3429B208C41B8C6EBC" xlink:to="loc_us-gaap_TrademarksMember_1E95ACF1E760A24B3DE808C41B8C73F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherIntangibleAssetsMember" xlink:label="loc_us-gaap_OtherIntangibleAssetsMember_0E3F5B3AEF2621D5170008C41B8CDBC6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1833CF263DA37E3429B208C41B8C6EBC" xlink:to="loc_us-gaap_OtherIntangibleAssetsMember_0E3F5B3AEF2621D5170008C41B8CDBC6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_677E09C0A8574118DCB208C41B8CB2BC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_Goodwill_677E09C0A8574118DCB208C41B8CB2BC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_BF9190569F637A05940808C41B8CBD48" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_BF9190569F637A05940808C41B8CBD48" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_8A3E1BADA73D27DC0A2F08C41B8C1068" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_8A3E1BADA73D27DC0A2F08C41B8C1068" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_F23C7F199002DF54DE6808C41B8C76DB" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_F23C7F199002DF54DE6808C41B8C76DB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities_77A88789BCF97128FCCD08C41B8C2EDB" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities_77A88789BCF97128FCCD08C41B8C2EDB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilitiesNoncurrent" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilitiesNoncurrent_AB184F0152D3ED74E74908C41B8C7A96" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedDeferredTaxLiabilitiesNoncurrent_AB184F0152D3ED74E74908C41B8C7A96" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_CEEBC34357371776148D08C41B8C8C95" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_279858DC96611D25219B08C41B8CE1A5" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_CEEBC34357371776148D08C41B8C8C95" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresKravePureFoodsNarrativeDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_B7F5672FBD251424951108C41809ADA6" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7120782CEBA968D4B19208C4180949AD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_B7F5672FBD251424951108C41809ADA6" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7120782CEBA968D4B19208C4180949AD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_4A792E87FEDCF7A329F608C41809109B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7120782CEBA968D4B19208C4180949AD" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_4A792E87FEDCF7A329F608C41809109B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1AC1445402240B8083A408C41809E142_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_4A792E87FEDCF7A329F608C41809109B" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1AC1445402240B8083A408C41809E142_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1AC1445402240B8083A408C41809E142" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_4A792E87FEDCF7A329F608C41809109B" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1AC1445402240B8083A408C41809E142" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_KRAVEPureFoodsInc.Member" xlink:label="loc_hsy_KRAVEPureFoodsInc.Member_F760D44A906E5F6B43FD08C4180930B8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_1AC1445402240B8083A408C41809E142" xlink:to="loc_hsy_KRAVEPureFoodsInc.Member_F760D44A906E5F6B43FD08C4180930B8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_0347B9EBC9CFAA8D5ADE08C41809AAD5" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_7120782CEBA968D4B19208C4180949AD" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_0347B9EBC9CFAA8D5ADE08C41809AAD5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_94315F201514CE6BC56008C41809284C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_0347B9EBC9CFAA8D5ADE08C41809AAD5" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_94315F201514CE6BC56008C41809284C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_94315F201514CE6BC56008C41809284C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_0347B9EBC9CFAA8D5ADE08C41809AAD5" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_94315F201514CE6BC56008C41809284C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_CFAD548AF26E3D913C5208C418095CCD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_94315F201514CE6BC56008C41809284C" xlink:to="loc_us-gaap_TrademarksMember_CFAD548AF26E3D913C5208C418095CCD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherIntangibleAssetsMember" xlink:label="loc_us-gaap_OtherIntangibleAssetsMember_2F0BE1305CBE816B65E808C41809DC65" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_94315F201514CE6BC56008C41809284C" xlink:to="loc_us-gaap_OtherIntangibleAssetsMember_2F0BE1305CBE816B65E808C41809DC65" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsToAcquireBusinessesGross" xlink:label="loc_us-gaap_PaymentsToAcquireBusinessesGross_0ACA4F74B8A90DC5556508C41809FC45" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_B7F5672FBD251424951108C41809ADA6" xlink:to="loc_us-gaap_PaymentsToAcquireBusinessesGross_0ACA4F74B8A90DC5556508C41809FC45" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationContingentConsiderationArrangementsRangeOfOutcomesValueHigh" xlink:label="loc_us-gaap_BusinessCombinationContingentConsiderationArrangementsRangeOfOutcomesValueHigh_01097AADE96AAE51B8F008C4180966D6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_B7F5672FBD251424951108C41809ADA6" xlink:to="loc_us-gaap_BusinessCombinationContingentConsiderationArrangementsRangeOfOutcomesValueHigh_01097AADE96AAE51B8F008C4180966D6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationContingentConsiderationLiability" xlink:label="loc_us-gaap_BusinessCombinationContingentConsiderationLiability_1DD092BF1807D89ADFB908C418094722" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_B7F5672FBD251424951108C41809ADA6" xlink:to="loc_us-gaap_BusinessCombinationContingentConsiderationLiability_1DD092BF1807D89ADFB908C418094722" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsForPreviousAcquisition" xlink:label="loc_us-gaap_PaymentsForPreviousAcquisition_BDF4A97512F1FDC409C708C41809C149" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_B7F5672FBD251424951108C41809ADA6" xlink:to="loc_us-gaap_PaymentsForPreviousAcquisition_BDF4A97512F1FDC409C708C41809C149" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresMaunaLoaNarrativeDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_17CE1FF7656F5A426CDC08C417CDDC29" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_21BEAC4D017ED6F3728A08C417CDA2A9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_17CE1FF7656F5A426CDC08C417CDDC29" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_21BEAC4D017ED6F3728A08C417CDA2A9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupClassificationAxis" xlink:label="loc_us-gaap_DisposalGroupClassificationAxis_9D2BE97E3480860E5ED608C417CD70A8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_21BEAC4D017ED6F3728A08C417CDA2A9" xlink:to="loc_us-gaap_DisposalGroupClassificationAxis_9D2BE97E3480860E5ED608C417CD70A8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_95329B7CB59CF6EE8C6308C417CDC9A1_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_9D2BE97E3480860E5ED608C417CD70A8" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_95329B7CB59CF6EE8C6308C417CDC9A1_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_95329B7CB59CF6EE8C6308C417CDC9A1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_9D2BE97E3480860E5ED608C417CD70A8" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_95329B7CB59CF6EE8C6308C417CDC9A1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupHeldForSaleOrDisposedOfBySaleNotDiscontinuedOperationsMember" xlink:label="loc_us-gaap_DisposalGroupHeldForSaleOrDisposedOfBySaleNotDiscontinuedOperationsMember_BA1B5A9F76FB4DB0FB8808C417CDC0A5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DisposalGroupClassificationDomain_95329B7CB59CF6EE8C6308C417CDC9A1" xlink:to="loc_us-gaap_DisposalGroupHeldForSaleOrDisposedOfBySaleNotDiscontinuedOperationsMember_BA1B5A9F76FB4DB0FB8808C417CDC0A5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_72CAE6FB05F5E6978B9508C417CD1300" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsTable_21BEAC4D017ED6F3728A08C417CDA2A9" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_72CAE6FB05F5E6978B9508C417CD1300" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1440EAA5D65286A2606808C417CDE7EC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_72CAE6FB05F5E6978B9508C417CD1300" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1440EAA5D65286A2606808C417CDE7EC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1440EAA5D65286A2606808C417CDE7EC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_72CAE6FB05F5E6978B9508C417CD1300" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1440EAA5D65286A2606808C417CDE7EC" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MaunaLoaMacadamiaNutCorporationMember" xlink:label="loc_hsy_MaunaLoaMacadamiaNutCorporationMember_6728094086D79D7A205708C417CD8F2C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_1440EAA5D65286A2606808C417CDE7EC" xlink:to="loc_hsy_MaunaLoaMacadamiaNutCorporationMember_6728094086D79D7A205708C417CD8F2C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProceedsFromDivestitureOfBusinesses" xlink:label="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_2F83DECA2C1D4A49842F08C417CDCAC8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_17CE1FF7656F5A426CDC08C417CDDC29" xlink:to="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_2F83DECA2C1D4A49842F08C417CDCAC8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupNotDiscontinuedOperationGainLossOnDisposal" xlink:label="loc_us-gaap_DisposalGroupNotDiscontinuedOperationGainLossOnDisposal_65702BF7E20AAF1AB88508C417CD8852" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsLineItems_17CE1FF7656F5A426CDC08C417CDDC29" xlink:to="loc_us-gaap_DisposalGroupNotDiscontinuedOperationGainLossOnDisposal_65702BF7E20AAF1AB88508C417CD8852" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresRippleBrandCollectiveLlcAssetsAcquiredAndLiabilitiesAssumedAllocationDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9CC12830B36829B6A9EC08C41966BB9E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9CC12830B36829B6A9EC08C41966BB9E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_D492137F17D46074D11508C419665E2D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9CC12830B36829B6A9EC08C41966BB9E" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_D492137F17D46074D11508C419665E2D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_D492137F17D46074D11508C419665E2D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_9CC12830B36829B6A9EC08C41966BB9E" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_D492137F17D46074D11508C419665E2D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_07327BB5CC4F4411884508C419660946" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_D492137F17D46074D11508C419665E2D" xlink:to="loc_us-gaap_TrademarksMember_07327BB5CC4F4411884508C419660946" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherIntangibleAssetsMember" xlink:label="loc_us-gaap_OtherIntangibleAssetsMember_779E891043B7CF91F52108C419661514" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_D492137F17D46074D11508C419665E2D" xlink:to="loc_us-gaap_OtherIntangibleAssetsMember_779E891043B7CF91F52108C419661514" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_4368E16F0BF4E8565C5208C41966B094" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:to="loc_us-gaap_RangeAxis_4368E16F0BF4E8565C5208C41966B094" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_F81AA283E58ED5AE45C508C419663E4B_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_4368E16F0BF4E8565C5208C41966B094" xlink:to="loc_us-gaap_RangeMember_F81AA283E58ED5AE45C508C419663E4B_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_F81AA283E58ED5AE45C508C419663E4B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_4368E16F0BF4E8565C5208C41966B094" xlink:to="loc_us-gaap_RangeMember_F81AA283E58ED5AE45C508C419663E4B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_9B183793AE20D707FA9008C41966359C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:to="loc_us-gaap_StatementScenarioAxis_9B183793AE20D707FA9008C41966359C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_AEA626BD5DF4951C2F9908C419664D91_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_9B183793AE20D707FA9008C41966359C" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_AEA626BD5DF4951C2F9908C419664D91_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_AEA626BD5DF4951C2F9908C419664D91" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_9B183793AE20D707FA9008C41966359C" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_AEA626BD5DF4951C2F9908C419664D91" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_029AC403FCDD2446E0DF08C41966CE39" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_029AC403FCDD2446E0DF08C41966CE39" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_44D606B80056338AD5A108C41966BCDB_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_029AC403FCDD2446E0DF08C41966CE39" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_44D606B80056338AD5A108C41966BCDB_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_44D606B80056338AD5A108C41966BCDB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_029AC403FCDD2446E0DF08C41966CE39" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_44D606B80056338AD5A108C41966BCDB" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RippleBrandCollectiveLLCMember" xlink:label="loc_hsy_RippleBrandCollectiveLLCMember_ED5071088EDA069C757508C419660606" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_44D606B80056338AD5A108C41966BCDB" xlink:to="loc_hsy_RippleBrandCollectiveLLCMember_ED5071088EDA069C757508C419660606" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_39FF3296F9A7955F702008C419663DCE" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B44C8BC6D9BF32BABB2E08C41966C6AC" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_39FF3296F9A7955F702008C419663DCE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_36E984490AFF75E269C808C419665174_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_39FF3296F9A7955F702008C419663DCE" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_36E984490AFF75E269C808C419665174_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_36E984490AFF75E269C808C419665174" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_39FF3296F9A7955F702008C419663DCE" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_36E984490AFF75E269C808C419665174" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_3C527A235544EB249D9608C419667705" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_Goodwill_3C527A235544EB249D9608C419667705" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_D0AB45CB8A56A5BBD31008C41966F404" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedIntangibles_D0AB45CB8A56A5BBD31008C41966F404" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_E677F7AF17E51A42FE4E08C41966BA61" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentAssetsOther_E677F7AF17E51A42FE4E08C41966BA61" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_FACEDB0C36F1BCCDCE4208C419703D61" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCashAndEquivalents_FACEDB0C36F1BCCDCE4208C419703D61" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities_E5458DF28F3EB6E3E05608C419705342" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedCurrentLiabilities_E5458DF28F3EB6E3E05608C419705342" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_67762FF0C701A92233AC08C41970455A" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_7821B2CDC2DF7721DE6108C419661069" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNet_67762FF0C701A92233AC08C41970455A" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresRippleBrandCollectiveLlcNarrativeDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_0B1E8F9ED61CDD9FDE3208C41948303D" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_63D6F20A2C5E789567A308C419486418" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_0B1E8F9ED61CDD9FDE3208C41948303D" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_63D6F20A2C5E789567A308C419486418" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_AE93E1A01CD50E358BB608C419481928" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_63D6F20A2C5E789567A308C419486418" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_AE93E1A01CD50E358BB608C419481928" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_7FC5A20437944E113BD108C41948398C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_AE93E1A01CD50E358BB608C419481928" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_7FC5A20437944E113BD108C41948398C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_7FC5A20437944E113BD108C41948398C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_AE93E1A01CD50E358BB608C419481928" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_7FC5A20437944E113BD108C41948398C" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RippleBrandCollectiveLLCMember" xlink:label="loc_hsy_RippleBrandCollectiveLLCMember_802146366D647F03F33508C419481EC6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_7FC5A20437944E113BD108C41948398C" xlink:to="loc_hsy_RippleBrandCollectiveLLCMember_802146366D647F03F33508C419481EC6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22A67126D4FD691670EF08C41948C35A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_63D6F20A2C5E789567A308C419486418" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22A67126D4FD691670EF08C41948C35A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_61E074E4D9B3127230E108C4194882D6_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22A67126D4FD691670EF08C41948C35A" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_61E074E4D9B3127230E108C4194882D6_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_61E074E4D9B3127230E108C4194882D6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_22A67126D4FD691670EF08C41948C35A" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_61E074E4D9B3127230E108C4194882D6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_606FFDC3D3723A6C404408C41948EA9C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_61E074E4D9B3127230E108C4194882D6" xlink:to="loc_us-gaap_TrademarksMember_606FFDC3D3723A6C404408C41948EA9C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherIntangibleAssetsMember" xlink:label="loc_us-gaap_OtherIntangibleAssetsMember_786C2D7BAE3B26EBF01E08C41948810A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_61E074E4D9B3127230E108C4194882D6" xlink:to="loc_us-gaap_OtherIntangibleAssetsMember_786C2D7BAE3B26EBF01E08C41948810A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_02CCC820C6B289C7B23008C41948D51B" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_63D6F20A2C5E789567A308C419486418" xlink:to="loc_us-gaap_RangeAxis_02CCC820C6B289C7B23008C41948D51B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_1A2C1FF17ADDDC74C32B08C419481A3B_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_02CCC820C6B289C7B23008C41948D51B" xlink:to="loc_us-gaap_RangeMember_1A2C1FF17ADDDC74C32B08C419481A3B_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_1A2C1FF17ADDDC74C32B08C419481A3B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_02CCC820C6B289C7B23008C41948D51B" xlink:to="loc_us-gaap_RangeMember_1A2C1FF17ADDDC74C32B08C419481A3B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_8A73E99D786BEF4E3EE308C419480E0C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_1A2C1FF17ADDDC74C32B08C419481A3B" xlink:to="loc_us-gaap_MinimumMember_8A73E99D786BEF4E3EE308C419480E0C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_7B1E396C4C088C8407AF08C41948F2A3" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_1A2C1FF17ADDDC74C32B08C419481A3B" xlink:to="loc_us-gaap_MaximumMember_7B1E396C4C088C8407AF08C41948F2A3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_3EEDEC6967600F8AA15008C41948D267" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_0B1E8F9ED61CDD9FDE3208C41948303D" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_3EEDEC6967600F8AA15008C41948D267" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresShanghaiGoldenMonkeyNarrativeDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_BD9498C9CC08E811A7CC08C41A106E7B" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B2796D8CF557B956C2F508C41A10B0F6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BD9498C9CC08E811A7CC08C41A106E7B" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B2796D8CF557B956C2F508C41A10B0F6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_4929A42CF9FBBE21277B08C41A1040DF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B2796D8CF557B956C2F508C41A10B0F6" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_4929A42CF9FBBE21277B08C41A1040DF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_34E65DD7976082C5C4B908C41A10B96D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_4929A42CF9FBBE21277B08C41A1040DF" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_34E65DD7976082C5C4B908C41A10B96D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_34E65DD7976082C5C4B908C41A10B96D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_4929A42CF9FBBE21277B08C41A1040DF" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_34E65DD7976082C5C4B908C41A10B96D" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member" xlink:label="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_3AF940C5062C658D7F5408C41A103358" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_34E65DD7976082C5C4B908C41A10B96D" xlink:to="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_3AF940C5062C658D7F5408C41A103358" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_E2FCB27B32C7420D878208C41A1018AF" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B2796D8CF557B956C2F508C41A10B0F6" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_E2FCB27B32C7420D878208C41A1018AF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_504D61F8A9035CD2F68808C41A10971C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_E2FCB27B32C7420D878208C41A1018AF" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_504D61F8A9035CD2F68808C41A10971C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_504D61F8A9035CD2F68808C41A10971C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_E2FCB27B32C7420D878208C41A1018AF" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_504D61F8A9035CD2F68808C41A10971C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OwnershipAxis" xlink:label="loc_us-gaap_OwnershipAxis_30C71B4FE30A816578FF08C41A102C45" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B2796D8CF557B956C2F508C41A10B0F6" xlink:to="loc_us-gaap_OwnershipAxis_30C71B4FE30A816578FF08C41A102C45" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OwnershipDomain" xlink:label="loc_us-gaap_OwnershipDomain_6CC148144751DBB7B6BA08C41A10DC4B_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_OwnershipAxis_30C71B4FE30A816578FF08C41A102C45" xlink:to="loc_us-gaap_OwnershipDomain_6CC148144751DBB7B6BA08C41A10DC4B_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OwnershipDomain" xlink:label="loc_us-gaap_OwnershipDomain_6CC148144751DBB7B6BA08C41A10DC4B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_OwnershipAxis_30C71B4FE30A816578FF08C41A102C45" xlink:to="loc_us-gaap_OwnershipDomain_6CC148144751DBB7B6BA08C41A10DC4B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_2B11C7416A0DEF6762AB08C41A103333" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_B2796D8CF557B956C2F508C41A10B0F6" xlink:to="loc_us-gaap_StatementClassOfStockAxis_2B11C7416A0DEF6762AB08C41A103333" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_8852527493C745BE423A08C41A1048DC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_2B11C7416A0DEF6762AB08C41A103333" xlink:to="loc_us-gaap_ClassOfStockDomain_8852527493C745BE423A08C41A1048DC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_8852527493C745BE423A08C41A1048DC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_2B11C7416A0DEF6762AB08C41A103333" xlink:to="loc_us-gaap_ClassOfStockDomain_8852527493C745BE423A08C41A1048DC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionPercentageOfVotingInterestsAcquired" xlink:label="loc_us-gaap_BusinessAcquisitionPercentageOfVotingInterestsAcquired_0561E33F07065CE2501308C41A1A7EF2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BD9498C9CC08E811A7CC08C41A106E7B" xlink:to="loc_us-gaap_BusinessAcquisitionPercentageOfVotingInterestsAcquired_0561E33F07065CE2501308C41A1A7EF2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsToAcquireBusinessesGross" xlink:label="loc_us-gaap_PaymentsToAcquireBusinessesGross_3F4A1EA67B8BC5E0B72D08C41A1A1038" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BD9498C9CC08E811A7CC08C41A106E7B" xlink:to="loc_us-gaap_PaymentsToAcquireBusinessesGross_3F4A1EA67B8BC5E0B72D08C41A1A1038" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount" xlink:label="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_86E9644F7E898F6CC8D108C41A1A0E7D" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_BD9498C9CC08E811A7CC08C41A106E7B" xlink:to="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_86E9644F7E898F6CC8D108C41A1A0E7D" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/BusinessAcquisitionsAndDivestituresTables" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_A69B3CEDD8D1B68884A308C418EF805F" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_BABEF7F02AAEB57D4D4F08C418E52196" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_A69B3CEDD8D1B68884A308C418EF805F" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_BABEF7F02AAEB57D4D4F08C418E52196" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_FA688B74F674AC95801108C418EFBD58" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_BABEF7F02AAEB57D4D4F08C418E52196" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_FA688B74F674AC95801108C418EFBD58" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_FA688B74F674AC95801108C418EFBD58" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_FA688B74F674AC95801108C418EFBD58" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RippleBrandCollectiveLLCMember" xlink:label="loc_hsy_RippleBrandCollectiveLLCMember_29E83732F0C59AC9114508C418EF2D6E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F" xlink:to="loc_hsy_RippleBrandCollectiveLLCMember_29E83732F0C59AC9114508C418EF2D6E" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member" xlink:label="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_D9CED0F84BE24DE712AA08C418EF602A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F" xlink:to="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_D9CED0F84BE24DE712AA08C418EF602A" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_KRAVEPureFoodsInc.Member" xlink:label="loc_hsy_KRAVEPureFoodsInc.Member_14A4A488370427B89FED08C418EF07E2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_483816B02C98940DE51508C418EFAD2F" xlink:to="loc_hsy_KRAVEPureFoodsInc.Member_14A4A488370427B89FED08C418EF07E2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_8AFD20D564E1436C984D08C418EF7134" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_BABEF7F02AAEB57D4D4F08C418E52196" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_8AFD20D564E1436C984D08C418EF7134" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_C90B94302B44793C721A08C418EF1946_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_8AFD20D564E1436C984D08C418EF7134" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_C90B94302B44793C721A08C418EF1946_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_C90B94302B44793C721A08C418EF1946" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_8AFD20D564E1436C984D08C418EF7134" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_C90B94302B44793C721A08C418EF1946" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupClassificationAxis" xlink:label="loc_us-gaap_DisposalGroupClassificationAxis_140D042F0133520B9A8C08C418EF9FD6" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_BABEF7F02AAEB57D4D4F08C418E52196" xlink:to="loc_us-gaap_DisposalGroupClassificationAxis_140D042F0133520B9A8C08C418EF9FD6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_3AA18535B039897245DB08C418EFB939_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_140D042F0133520B9A8C08C418EF9FD6" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_3AA18535B039897245DB08C418EFB939_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupClassificationDomain" xlink:label="loc_us-gaap_DisposalGroupClassificationDomain_3AA18535B039897245DB08C418EFB939" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DisposalGroupClassificationAxis_140D042F0133520B9A8C08C418EF9FD6" xlink:to="loc_us-gaap_DisposalGroupClassificationDomain_3AA18535B039897245DB08C418EFB939" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock" xlink:label="loc_us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock_637CA5C5BBB7FE11127308C418EF90E7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_A69B3CEDD8D1B68884A308C418EF805F" xlink:to="loc_us-gaap_ScheduleOfRecognizedIdentifiedAssetsAcquiredAndLiabilitiesAssumedTableTextBlock_637CA5C5BBB7FE11127308C418EF90E7" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_AC302B95363CD678B01008C41B283D79" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:to="loc_us-gaap_RangeAxis_AC302B95363CD678B01008C41B283D79" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_098AD36953066A3CD65508C41B2826C7_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_AC302B95363CD678B01008C41B283D79" xlink:to="loc_us-gaap_RangeMember_098AD36953066A3CD65508C41B2826C7_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_098AD36953066A3CD65508C41B2826C7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_AC302B95363CD678B01008C41B283D79" xlink:to="loc_us-gaap_RangeMember_098AD36953066A3CD65508C41B2826C7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_F748C2AF5AC66150B1CF08C41B287F4B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_098AD36953066A3CD65508C41B2826C7" xlink:to="loc_us-gaap_MinimumMember_F748C2AF5AC66150B1CF08C41B287F4B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_13A2FD3D576B1024856308C41B28E3E4" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_098AD36953066A3CD65508C41B2826C7" xlink:to="loc_us-gaap_MaximumMember_13A2FD3D576B1024856308C41B28E3E4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_F844D6546C8F3ABEACF808C41B288B7F" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_F844D6546C8F3ABEACF808C41B288B7F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_D9C8F082862FEBFF0DEA08C41B287FEC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_F844D6546C8F3ABEACF808C41B288B7F" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_D9C8F082862FEBFF0DEA08C41B287FEC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_D9C8F082862FEBFF0DEA08C41B287FEC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_F844D6546C8F3ABEACF808C41B288B7F" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_D9C8F082862FEBFF0DEA08C41B287FEC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringChargesMember" xlink:label="loc_us-gaap_RestructuringChargesMember_FB3208436BF2671AD42A08C41B28122C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_D9C8F082862FEBFF0DEA08C41B287FEC" xlink:to="loc_us-gaap_RestructuringChargesMember_FB3208436BF2671AD42A08C41B28122C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_D436D88E7103811BEADB08C41B287F5E" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_D436D88E7103811BEADB08C41B287F5E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_A306770E34F3FA7CAE8508C41B286A27_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_D436D88E7103811BEADB08C41B287F5E" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_A306770E34F3FA7CAE8508C41B286A27_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_A306770E34F3FA7CAE8508C41B286A27" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_D436D88E7103811BEADB08C41B287F5E" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_A306770E34F3FA7CAE8508C41B286A27" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GeographicConcentrationRiskMember" xlink:label="loc_us-gaap_GeographicConcentrationRiskMember_43AB43D0128CDEE5E22308C41B2856EF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_A306770E34F3FA7CAE8508C41B286A27" xlink:to="loc_us-gaap_GeographicConcentrationRiskMember_43AB43D0128CDEE5E22308C41B2856EF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_638DF6CC878D6580F93D08C41B28098A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_638DF6CC878D6580F93D08C41B28098A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_18D132FE4F7710CE2C5508C41B288917_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_638DF6CC878D6580F93D08C41B28098A" xlink:to="loc_us-gaap_SegmentDomain_18D132FE4F7710CE2C5508C41B288917_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_18D132FE4F7710CE2C5508C41B288917" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_638DF6CC878D6580F93D08C41B28098A" xlink:to="loc_us-gaap_SegmentDomain_18D132FE4F7710CE2C5508C41B288917" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NorthAmericaMember" xlink:label="loc_us-gaap_NorthAmericaMember_15F85631FFD8DDFC925C08C41B2898D2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_18D132FE4F7710CE2C5508C41B288917" xlink:to="loc_us-gaap_NorthAmericaMember_15F85631FFD8DDFC925C08C41B2898D2" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_24E63DB62C4764727D1F08C41B28816A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_18D132FE4F7710CE2C5508C41B288917" xlink:to="loc_hsy_InternationalandOtherSegmentMember_24E63DB62C4764727D1F08C41B28816A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_3DEC25E238353520E8AC08C41B2821CF" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:to="loc_us-gaap_RestructuringPlanAxis_3DEC25E238353520E8AC08C41B2821CF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_3DEC25E238353520E8AC08C41B2821CF" xlink:to="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_3DEC25E238353520E8AC08C41B2821CF" xlink:to="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NorthAmericaMember" xlink:label="loc_us-gaap_NorthAmericaMember_8CD6FBD171051CED8EF108C41B286655" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2" xlink:to="loc_us-gaap_NorthAmericaMember_8CD6FBD171051CED8EF108C41B286655" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_1C39C22F48A57F1E2AEE08C41B283A5B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2" xlink:to="loc_hsy_MarginforGrowthProgramMember_1C39C22F48A57F1E2AEE08C41B283A5B" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ChinaStructureOptimizationMember" xlink:label="loc_hsy_ChinaStructureOptimizationMember_D30079C9FAD5812C4D2008C41B286EC2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2" xlink:to="loc_hsy_ChinaStructureOptimizationMember_D30079C9FAD5812C4D2008C41B286EC2" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ProductivityInitiative2015Member" xlink:label="loc_hsy_ProductivityInitiative2015Member_0BCD6F7FBAA87F41EA1008C41B28627C" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_5E8928FDEB468BF5B14F08C41B2832D2" xlink:to="loc_hsy_ProductivityInitiative2015Member_0BCD6F7FBAA87F41EA1008C41B28627C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_053BF4DB866F0AF7921208C41B2892FA" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_2796752913EFD765634208C41B28B159" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_053BF4DB866F0AF7921208C41B2892FA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_053BF4DB866F0AF7921208C41B2892FA" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_053BF4DB866F0AF7921208C41B2892FA" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FacilityClosingMember" xlink:label="loc_us-gaap_FacilityClosingMember_FC602F5FC89219EDF69008C41B28C703" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:to="loc_us-gaap_FacilityClosingMember_FC602F5FC89219EDF69008C41B28C703" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeSeveranceMember" xlink:label="loc_us-gaap_EmployeeSeveranceMember_B263943A3CB5F305133708C41B28B160" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:to="loc_us-gaap_EmployeeSeveranceMember_B263943A3CB5F305133708C41B28B160" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_AcceleratedDepreciationandAmortizationMember" xlink:label="loc_hsy_AcceleratedDepreciationandAmortizationMember_BFD14CE2AAD09A486A1708C41B2897D3" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:to="loc_hsy_AcceleratedDepreciationandAmortizationMember_BFD14CE2AAD09A486A1708C41B2897D3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractTerminationMember" xlink:label="loc_us-gaap_ContractTerminationMember_C886D1019661A8E6A21508C41B284A7E" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:to="loc_us-gaap_ContractTerminationMember_C886D1019661A8E6A21508C41B284A7E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherRestructuringMember" xlink:label="loc_us-gaap_OtherRestructuringMember_2FC32531D5F9E516D12308C41B325FFE" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:to="loc_us-gaap_OtherRestructuringMember_2FC32531D5F9E516D12308C41B325FFE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OneTimeTerminationBenefitsMember" xlink:label="loc_us-gaap_OneTimeTerminationBenefitsMember_A3B4F6C83364167E2B9908C41B32A1DE" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_5EF8E529105346C9364E08C41B28A6A9" xlink:to="loc_us-gaap_OneTimeTerminationBenefitsMember_A3B4F6C83364167E2B9908C41B32A1DE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_CBCD88253D450FBF82B108C41B32F5E9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_CBCD88253D450FBF82B108C41B32F5E9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringAndRelatedCostExpectedCost1" xlink:label="loc_us-gaap_RestructuringAndRelatedCostExpectedCost1_7BC79FB43F45A00D245108C41B32895A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_RestructuringAndRelatedCostExpectedCost1_7BC79FB43F45A00D245108C41B32895A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_E8E7448618D4492C53AE08C41B328E02" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_E8E7448618D4492C53AE08C41B328E02" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EffectOnFutureCashFlowsAmount" xlink:label="loc_us-gaap_EffectOnFutureCashFlowsAmount_CE3CF07BBB713C9A3BFC08C41B3299C4" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_EffectOnFutureCashFlowsAmount_CE3CF07BBB713C9A3BFC08C41B3299C4" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent" xlink:label="loc_hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent_4318A9902013C0F9122E08C41B3211AA" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_hsy_RestructuringandRelatedCostExpectedNumberofPositionsEliminatedPercent_4318A9902013C0F9122E08C41B3211AA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_E3F0B08139F36B630D7B08C41B324A41" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_AssetImpairmentCharges_E3F0B08139F36B630D7B08C41B324A41" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsHeldForUse" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_BA5CADBDA365152C58C708C41B32BDAE" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_BA5CADBDA365152C58C708C41B32BDAE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_6A3C42E31152367182D008C41B329804" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_RestructuringCharges_6A3C42E31152367182D008C41B329804" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RestructuringandRelatedCostPeriodofIncurredRestructuringCosts" xlink:label="loc_hsy_RestructuringandRelatedCostPeriodofIncurredRestructuringCosts_64E7480AC0608FF0233508C41B32963D" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_hsy_RestructuringandRelatedCostPeriodofIncurredRestructuringCosts_64E7480AC0608FF0233508C41B32963D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringAndRelatedCostExpectedNumberOfPositionsEliminated" xlink:label="loc_us-gaap_RestructuringAndRelatedCostExpectedNumberOfPositionsEliminated_E25EDB6158EE4AFAA55708C41B32AF1F" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_RestructuringAndRelatedCostExpectedNumberOfPositionsEliminated_E25EDB6158EE4AFAA55708C41B32AF1F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringAndRelatedCostCostIncurredToDate1" xlink:label="loc_us-gaap_RestructuringAndRelatedCostCostIncurredToDate1_1135562362DFE54729A608C41B325970" xlink:type="locator"/>
<link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_ECD5253A4B461F44ECB508C41B32254B" xlink:to="loc_us-gaap_RestructuringAndRelatedCostCostIncurredToDate1_1135562362DFE54729A608C41B325970" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_33A648E2DB5C5052179C83150424628D" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_8E155848C85A4108BF8A831504247CDE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_33A648E2DB5C5052179C83150424628D" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_8E155848C85A4108BF8A831504247CDE" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_B276BFF5BCEE090028AF8315042437C0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_8E155848C85A4108BF8A831504247CDE" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_B276BFF5BCEE090028AF8315042437C0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_B276BFF5BCEE090028AF8315042437C0" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_B276BFF5BCEE090028AF8315042437C0" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeSeveranceMember" xlink:label="loc_us-gaap_EmployeeSeveranceMember_27B81692A7043506D8D883150424D861" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1" xlink:to="loc_us-gaap_EmployeeSeveranceMember_27B81692A7043506D8D883150424D861" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_AcceleratedDepreciationandAmortizationMember" xlink:label="loc_hsy_AcceleratedDepreciationandAmortizationMember_D119FD40676BEE8F55BB8315042406A1" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1" xlink:to="loc_hsy_AcceleratedDepreciationandAmortizationMember_D119FD40676BEE8F55BB8315042406A1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherRestructuringMember" xlink:label="loc_us-gaap_OtherRestructuringMember_6778FB084D0ADCF9B26C83150424DF7C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1" xlink:to="loc_us-gaap_OtherRestructuringMember_6778FB084D0ADCF9B26C83150424DF7C" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PensionSettlementChargeMember" xlink:label="loc_hsy_PensionSettlementChargeMember_6BE147995A54C7295D7B83150424262D" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfRestructuringDomain_32DFEF4740649D016F3D831504240EE1" xlink:to="loc_hsy_PensionSettlementChargeMember_6BE147995A54C7295D7B83150424262D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis" xlink:label="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_B7E9219FD5A3E19A1599831504242C62" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_8E155848C85A4108BF8A831504247CDE" xlink:to="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_B7E9219FD5A3E19A1599831504242C62" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_64668F94FBDBF03CF4D5831504243145_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_B7E9219FD5A3E19A1599831504242C62" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_64668F94FBDBF03CF4D5831504243145_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain" xlink:label="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_64668F94FBDBF03CF4D5831504243145" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementBalanceSheetAndAdditionalDisclosuresByDisposalGroupsIncludingDiscontinuedOperationsAxis_B7E9219FD5A3E19A1599831504242C62" xlink:to="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_64668F94FBDBF03CF4D5831504243145" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MaunaLoaMacadamiaNutCorporationMember" xlink:label="loc_hsy_MaunaLoaMacadamiaNutCorporationMember_021ED6788E617DC49351831504246575" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DisposalGroupsIncludingDiscontinuedOperationsNameDomain_64668F94FBDBF03CF4D5831504243145" xlink:to="loc_hsy_MaunaLoaMacadamiaNutCorporationMember_021ED6788E617DC49351831504246575" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_4FBA319F73C0F19C78A783150424F996" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_8E155848C85A4108BF8A831504247CDE" xlink:to="loc_us-gaap_RestructuringPlanAxis_4FBA319F73C0F19C78A783150424F996" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_4FBA319F73C0F19C78A783150424F996" xlink:to="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_4FBA319F73C0F19C78A783150424F996" xlink:to="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_151BE05A833C2C3FDFB683150424C5F8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79" xlink:to="loc_hsy_MarginforGrowthProgramMember_151BE05A833C2C3FDFB683150424C5F8" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ChinaStructureOptimizationMember" xlink:label="loc_hsy_ChinaStructureOptimizationMember_0F12D755F7051D0E3D25831504247174" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79" xlink:to="loc_hsy_ChinaStructureOptimizationMember_0F12D755F7051D0E3D25831504247174" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ProductivityInitiative2015Member" xlink:label="loc_hsy_ProductivityInitiative2015Member_B9AC5EB679AFBD33FEC6831504241F06" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79" xlink:to="loc_hsy_ProductivityInitiative2015Member_B9AC5EB679AFBD33FEC6831504241F06" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_OtherInternationalRestructuringProgramsMember" xlink:label="loc_hsy_OtherInternationalRestructuringProgramsMember_CF1141BF0534353B0D99831504245227" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_F848207F463546249A5C83150424FC79" xlink:to="loc_hsy_OtherInternationalRestructuringProgramsMember_CF1141BF0534353B0D99831504245227" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_570C4CBC7417B4E7AEB2831504247B00" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_8E155848C85A4108BF8A831504247CDE" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_570C4CBC7417B4E7AEB2831504247B00" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_570C4CBC7417B4E7AEB2831504247B00" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_570C4CBC7417B4E7AEB2831504247B00" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostOfSalesMember" xlink:label="loc_us-gaap_CostOfSalesMember_5944C3475A8B681117D0831504244F87" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052" xlink:to="loc_us-gaap_CostOfSalesMember_5944C3475A8B681117D0831504244F87" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_6C5288DB702ED6D3EB1783150424621F" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_6C5288DB702ED6D3EB1783150424621F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringChargesMember" xlink:label="loc_us-gaap_RestructuringChargesMember_AADDDBBA22CB88D3B72483150424F1A4" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052" xlink:to="loc_us-gaap_RestructuringChargesMember_AADDDBBA22CB88D3B72483150424F1A4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpenseMember" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_5BB30774BED3468A4F3A831504246945" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_4D85A12D231DBD932C4D831504243052" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_5BB30774BED3468A4F3A831504246945" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_4DABD5777E75506F604983150424B931" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_33A648E2DB5C5052179C83150424628D" xlink:to="loc_us-gaap_RestructuringCharges_4DABD5777E75506F604983150424B931" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCostAndReserveLineItems" xlink:label="loc_us-gaap_RestructuringCostAndReserveLineItems_78C3846CFF88E08670BA08C418A9F44F" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfRestructuringAndRelatedCostsTable" xlink:label="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_AE6D48BA93621E4DECB808C418A98893" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_78C3846CFF88E08670BA08C418A9F44F" xlink:to="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_AE6D48BA93621E4DECB808C418A98893" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCostAndReserveAxis" xlink:label="loc_us-gaap_RestructuringCostAndReserveAxis_BACBB4B59591B62A845A08C418A9CF56" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRestructuringAndRelatedCostsTable_AE6D48BA93621E4DECB808C418A98893" xlink:to="loc_us-gaap_RestructuringCostAndReserveAxis_BACBB4B59591B62A845A08C418A9CF56" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_3C3DEF25A7148BE2349E08C418A909D0_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_BACBB4B59591B62A845A08C418A9CF56" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_3C3DEF25A7148BE2349E08C418A909D0_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfRestructuringDomain" xlink:label="loc_us-gaap_TypeOfRestructuringDomain_3C3DEF25A7148BE2349E08C418A909D0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringCostAndReserveAxis_BACBB4B59591B62A845A08C418A9CF56" xlink:to="loc_us-gaap_TypeOfRestructuringDomain_3C3DEF25A7148BE2349E08C418A909D0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringReserveRollForward" xlink:label="loc_us-gaap_RestructuringReserveRollForward_D630E887B191C5AAED1608C418A9DEF1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringCostAndReserveLineItems_78C3846CFF88E08670BA08C418A9F44F" xlink:to="loc_us-gaap_RestructuringReserveRollForward_D630E887B191C5AAED1608C418A9DEF1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringReserve" xlink:label="loc_us-gaap_RestructuringReserve_85726E562232AEBED26E08C418A9FCB9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_D630E887B191C5AAED1608C418A9DEF1" xlink:to="loc_us-gaap_RestructuringReserve_85726E562232AEBED26E08C418A9FCB9" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RestructuringChargesBusinessRealignmentReserve" xlink:label="loc_hsy_RestructuringChargesBusinessRealignmentReserve_04F423E60CA9680672AD08C418A98DC2" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_D630E887B191C5AAED1608C418A9DEF1" xlink:to="loc_hsy_RestructuringChargesBusinessRealignmentReserve_04F423E60CA9680672AD08C418A98DC2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsForRestructuring" xlink:label="loc_us-gaap_PaymentsForRestructuring_64BD5E4EA95498BF58CA08C418A92491" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_D630E887B191C5AAED1608C418A9DEF1" xlink:to="loc_us-gaap_PaymentsForRestructuring_64BD5E4EA95498BF58CA08C418A92491" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringReserveAccrualAdjustment1" xlink:label="loc_us-gaap_RestructuringReserveAccrualAdjustment1_35AD9B63FE7983BB7AD608C418A9966C" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringReserveRollForward_D630E887B191C5AAED1608C418A9DEF1" xlink:to="loc_us-gaap_RestructuringReserveAccrualAdjustment1_35AD9B63FE7983BB7AD608C418A9966C" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskLineItems" xlink:label="loc_us-gaap_ConcentrationRiskLineItems_00A3C3D92ABF9DF0999908C41AE2426D" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTable" xlink:label="loc_us-gaap_ConcentrationRiskTable_57B04C46700B40A2D69808C41AD85934" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_00A3C3D92ABF9DF0999908C41AE2426D" xlink:to="loc_us-gaap_ConcentrationRiskTable_57B04C46700B40A2D69808C41AD85934" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_344211016DE90D8AFE0C08C41AD8854D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ConcentrationRiskTable_57B04C46700B40A2D69808C41AD85934" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_344211016DE90D8AFE0C08C41AD8854D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_DBF88897782603D0E5BC08C41AD8F7C8_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_344211016DE90D8AFE0C08C41AD8854D" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_DBF88897782603D0E5BC08C41AD8F7C8_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_DBF88897782603D0E5BC08C41AD8F7C8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_344211016DE90D8AFE0C08C41AD8854D" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_DBF88897782603D0E5BC08C41AD8F7C8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember" xlink:label="loc_us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember_7823A3AA900D0C2717E708C41AD83EC2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_DBF88897782603D0E5BC08C41AD8F7C8" xlink:to="loc_us-gaap_WorkforceSubjectToCollectiveBargainingArrangementsMember_7823A3AA900D0C2717E708C41AD83EC2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_AE5D3D876DC864508CF808C41AD83240" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ConcentrationRiskTable_57B04C46700B40A2D69808C41AD85934" xlink:to="loc_us-gaap_StatementScenarioAxis_AE5D3D876DC864508CF808C41AD83240" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_3244D4912773E853865308C41AE25F44_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_AE5D3D876DC864508CF808C41AD83240" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_3244D4912773E853865308C41AE25F44_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_3244D4912773E853865308C41AE25F44" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_AE5D3D876DC864508CF808C41AD83240" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_3244D4912773E853865308C41AE25F44" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_E0ED2699C4F56D1B7CE608C41AE28A67" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_3244D4912773E853865308C41AE25F44" xlink:to="loc_us-gaap_ScenarioForecastMember_E0ED2699C4F56D1B7CE608C41AE28A67" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityNumberOfEmployees" xlink:label="loc_dei_EntityNumberOfEmployees_276043FEBAD287C8CEF408C41AE21EBA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_00A3C3D92ABF9DF0999908C41AE2426D" xlink:to="loc_dei_EntityNumberOfEmployees_276043FEBAD287C8CEF408C41AE21EBA" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_EntityNumberofPartTimeEmployees" xlink:label="loc_hsy_EntityNumberofPartTimeEmployees_BEBBC169A932FA69E6AF08C41AE207EC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_00A3C3D92ABF9DF0999908C41AE2426D" xlink:to="loc_hsy_EntityNumberofPartTimeEmployees_BEBBC169A932FA69E6AF08C41AE207EC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_4361577AA8F941F40D4D08C41AE232FB" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskLineItems_00A3C3D92ABF9DF0999908C41AE2426D" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_4361577AA8F941F40D4D08C41AE232FB" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_8D26AFA238E5D8DFBAB408C4179B9102" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationTable" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_8C965EC5A4CB3A5875E908C4179BA0AC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_8D26AFA238E5D8DFBAB408C4179B9102" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_8C965EC5A4CB3A5875E908C4179BA0AC" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_FFE8B79FC643F76CD0A108C4179B20D0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationTable_8C965EC5A4CB3A5875E908C4179BA0AC" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_FFE8B79FC643F76CD0A108C4179B20D0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain" xlink:label="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_92F75D0115CA2D1568A608C4179B811C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_FFE8B79FC643F76CD0A108C4179B20D0" xlink:to="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_92F75D0115CA2D1568A608C4179B811C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain" xlink:label="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_92F75D0115CA2D1568A608C4179B811C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationByCategoryOfItemPurchasedAxis_FFE8B79FC643F76CD0A108C4179B20D0" xlink:to="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_92F75D0115CA2D1568A608C4179B811C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InventoriesMember" xlink:label="loc_us-gaap_InventoriesMember_FF1B0DDCD5CA58574C9008C4179BF2C6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnconditionalPurchaseObligationCategoryOfGoodsOrServicesAcquiredDomain_92F75D0115CA2D1568A608C4179B811C" xlink:to="loc_us-gaap_InventoriesMember_FF1B0DDCD5CA58574C9008C4179BF2C6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationLineItems_8D26AFA238E5D8DFBAB408C4179B9102" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary_7D320804C492666359D808C4179B3A44" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFirstAnniversary_7D320804C492666359D808C4179B3A44" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary_BC435F14388741814A4708C4179B0AD5" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnSecondAnniversary_BC435F14388741814A4708C4179B0AD5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary_AE1DA30897E6372FD61F08C4179B1BB1" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnThirdAnniversary_AE1DA30897E6372FD61F08C4179B1BB1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary_C98C4F7CFC47BFC2990308C4179B22CD" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFourthAnniversary_C98C4F7CFC47BFC2990308C4179B22CD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary" xlink:label="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary_7C0B25419EB3756CA50A08C4179B7E68" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationAbstract_6D5C5D7801B9E02B4E1408C4179BF7FA" xlink:to="loc_us-gaap_UnrecordedUnconditionalPurchaseObligationBalanceOnFifthAnniversary_7C0B25419EB3756CA50A08C4179B7E68" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_C9E6F65D92EA765CC91608C418DBBD0E" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_192EE32BCCB95765AB6108C418DBB8A9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_C9E6F65D92EA765CC91608C418DBBD0E" xlink:to="loc_us-gaap_StatementTable_192EE32BCCB95765AB6108C418DBB8A9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_D5F80BA5D6D190DB8EDC08C418DB3DC8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_192EE32BCCB95765AB6108C418DBB8A9" xlink:to="loc_us-gaap_StatementClassOfStockAxis_D5F80BA5D6D190DB8EDC08C418DB3DC8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_90A000AA0DF5059AC8E508C418DB8EB7_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_D5F80BA5D6D190DB8EDC08C418DB3DC8" xlink:to="loc_us-gaap_ClassOfStockDomain_90A000AA0DF5059AC8E508C418DB8EB7_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_90A000AA0DF5059AC8E508C418DB8EB7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_D5F80BA5D6D190DB8EDC08C418DB3DC8" xlink:to="loc_us-gaap_ClassOfStockDomain_90A000AA0DF5059AC8E508C418DB8EB7" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_D121CB6B5B37E4889C7508C418DB7B38" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_90A000AA0DF5059AC8E508C418DB8EB7" xlink:to="loc_hsy_HersheyCommonStockMember_D121CB6B5B37E4889C7508C418DB7B38" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_245CC1C6F5580009C46D08C418DB0109" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_90A000AA0DF5059AC8E508C418DB8EB7" xlink:to="loc_us-gaap_CommonClassBMember_245CC1C6F5580009C46D08C418DB0109" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AssetsAbstract" xlink:label="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C9E6F65D92EA765CC91608C418DBBD0E" xlink:to="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AssetsCurrentAbstract" xlink:label="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_AC1E0BCFF69D954BCD6B08C418DB9A53" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_AC1E0BCFF69D954BCD6B08C418DB9A53" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountsReceivableNetCurrent" xlink:label="loc_us-gaap_AccountsReceivableNetCurrent_5026F4C3793D35C23E0208C418DBD031" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_5026F4C3793D35C23E0208C418DBD031" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InventoryNet" xlink:label="loc_us-gaap_InventoryNet_D1A91D4DC82F8C87C27708C418DB3BCF" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:to="loc_us-gaap_InventoryNet_D1A91D4DC82F8C87C27708C418DB3BCF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PrepaidExpenseAndOtherAssetsCurrent" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_AB5A9D4F4E46C08C02B408C418DB2225" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_AB5A9D4F4E46C08C02B408C418DB2225" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AssetsCurrent" xlink:label="loc_us-gaap_AssetsCurrent_9F90AB7090A73E3F273908C418DBA1F2" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_B0B58C771AD55DF29DD108C418DB34A2" xlink:to="loc_us-gaap_AssetsCurrent_9F90AB7090A73E3F273908C418DBA1F2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_9BD141482177C906E7B908C418DB61A9" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_9BD141482177C906E7B908C418DB61A9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_1593C1A07C363A2E624208C418DBA0C2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_Goodwill_1593C1A07C363A2E624208C418DBA0C2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_88E8E85B514C7515C04808C418DBE223" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_88E8E85B514C7515C04808C418DBE223" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherAssetsNoncurrent" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_2C303D01145DADB2D05608C418DBD183" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_2C303D01145DADB2D05608C418DBD183" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxAssetsLiabilitiesNetNoncurrent" xlink:label="loc_us-gaap_DeferredTaxAssetsLiabilitiesNetNoncurrent_52B1A4A35F13BBFDCF1A08C418DB51DA" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_DeferredTaxAssetsLiabilitiesNetNoncurrent_52B1A4A35F13BBFDCF1A08C418DB51DA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Assets" xlink:label="loc_us-gaap_Assets_7F0875A3FA4CA16DCD8D08C418DB3155" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_F6636401D1C73EE10D6408C418DBF801" xlink:to="loc_us-gaap_Assets_7F0875A3FA4CA16DCD8D08C418DB3155" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LiabilitiesAndStockholdersEquityAbstract" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C9E6F65D92EA765CC91608C418DBBD0E" xlink:to="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LiabilitiesCurrentAbstract" xlink:label="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountsPayableCurrent" xlink:label="loc_us-gaap_AccountsPayableCurrent_67FF1E95CE956651E6FC08C418DB6843" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:to="loc_us-gaap_AccountsPayableCurrent_67FF1E95CE956651E6FC08C418DB6843" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccruedLiabilitiesCurrent" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_07A2CCF2BFEAA52AE7C208C418DB6364" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:to="loc_us-gaap_AccruedLiabilitiesCurrent_07A2CCF2BFEAA52AE7C208C418DB6364" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccruedIncomeTaxesCurrent" xlink:label="loc_us-gaap_AccruedIncomeTaxesCurrent_8F8F5048EB9CCF21CB4008C418DB432B" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:to="loc_us-gaap_AccruedIncomeTaxesCurrent_8F8F5048EB9CCF21CB4008C418DB432B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShortTermBorrowings" xlink:label="loc_us-gaap_ShortTermBorrowings_C6CAC7BD74C30753A6AD08C418DBED81" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:to="loc_us-gaap_ShortTermBorrowings_C6CAC7BD74C30753A6AD08C418DBED81" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_C82A5A652F00DFE0A5F108C418DBD661" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:to="loc_us-gaap_LongTermDebtCurrent_C82A5A652F00DFE0A5F108C418DBD661" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LiabilitiesCurrent" xlink:label="loc_us-gaap_LiabilitiesCurrent_BFA6B292FB6A8C7F50EB08C418DB52E6" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_29CE96CA1002A6DECF1708C418DB8234" xlink:to="loc_us-gaap_LiabilitiesCurrent_BFA6B292FB6A8C7F50EB08C418DB52E6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtAndCapitalLeaseObligations" xlink:label="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_6680A7C6B922D57F549008C418DBDF4D" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_LongTermDebtAndCapitalLeaseObligations_6680A7C6B922D57F549008C418DBDF4D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherLiabilitiesNoncurrent" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_EDD66FCA6DC35CF94E9C08C418DB9811" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_EDD66FCA6DC35CF94E9C08C418DB9811" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxLiabilitiesNoncurrent" xlink:label="loc_us-gaap_DeferredTaxLiabilitiesNoncurrent_335B43B698267843793008C418DBEE89" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_DeferredTaxLiabilitiesNoncurrent_335B43B698267843793008C418DBEE89" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Liabilities" xlink:label="loc_us-gaap_Liabilities_A9AD70430DC0B135DD4108C418DBA609" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_Liabilities_A9AD70430DC0B135DD4108C418DBA609" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockValue" xlink:label="loc_us-gaap_PreferredStockValue_A5E878D10A2A8FF39A5108C418DB3BE8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_PreferredStockValue_A5E878D10A2A8FF39A5108C418DB3BE8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockValue" xlink:label="loc_us-gaap_CommonStockValue_52131BF61118E0EC1EA608C418DB41F5" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_CommonStockValue_52131BF61118E0EC1EA608C418DB41F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdditionalPaidInCapital" xlink:label="loc_us-gaap_AdditionalPaidInCapital_A418117970A3B2589C3908C418DB28C4" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_AdditionalPaidInCapital_A418117970A3B2589C3908C418DB28C4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetainedEarningsAccumulatedDeficit" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_C22EA8D2B80A4199D53808C418DBA2A3" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_C22EA8D2B80A4199D53808C418DBA2A3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockValue" xlink:label="loc_us-gaap_TreasuryStockValue_1260F4735BC5BE82AD4808C418DBA986" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_TreasuryStockValue_1260F4735BC5BE82AD4808C418DBA986" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_F18FDA39B23C5E77B51C08C418DBC6CA" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_F18FDA39B23C5E77B51C08C418DBC6CA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockholdersEquity" xlink:label="loc_us-gaap_StockholdersEquity_7903E2969F0B75637C1B08C418DB7BDC" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_StockholdersEquity_7903E2969F0B75637C1B08C418DB7BDC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinorityInterest" xlink:label="loc_us-gaap_MinorityInterest_F8FA34562396E547AE8F08C418DB1245" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_MinorityInterest_F8FA34562396E547AE8F08C418DB1245" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_1E07D63E16616F69085E08C418DBA0D8" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAbstract_F3B13EA089B9D96A7B7C08C418DB7AEF" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_1E07D63E16616F69085E08C418DBA0D8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LiabilitiesAndStockholdersEquity" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_69123EF94590E71107C608C418DBB813" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquityAbstract_710D3CE83D9D092695EA08C418DBD65B" xlink:to="loc_us-gaap_LiabilitiesAndStockholdersEquity_69123EF94590E71107C608C418DBB813" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_56B90B26DC52437AD10208C4186382F7" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_59E222AD70B981D5A84408C41863020A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_56B90B26DC52437AD10208C4186382F7" xlink:to="loc_us-gaap_StatementTable_59E222AD70B981D5A84408C41863020A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_E50188BE48B250EE4D7408C418630930" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_59E222AD70B981D5A84408C41863020A" xlink:to="loc_us-gaap_StatementClassOfStockAxis_E50188BE48B250EE4D7408C418630930" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BC0A8146B454DA1AF6D608C41863BADD_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_E50188BE48B250EE4D7408C418630930" xlink:to="loc_us-gaap_ClassOfStockDomain_BC0A8146B454DA1AF6D608C41863BADD_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BC0A8146B454DA1AF6D608C41863BADD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_E50188BE48B250EE4D7408C418630930" xlink:to="loc_us-gaap_ClassOfStockDomain_BC0A8146B454DA1AF6D608C41863BADD" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_E795C8A2A3F679FEE89708C418639F9E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_BC0A8146B454DA1AF6D608C41863BADD" xlink:to="loc_hsy_HersheyCommonStockMember_E795C8A2A3F679FEE89708C418639F9E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_F6343956AAB1FB35B8DE08C4186324A3" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_BC0A8146B454DA1AF6D608C41863BADD" xlink:to="loc_us-gaap_CommonClassBMember_F6343956AAB1FB35B8DE08C4186324A3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockSharesIssued" xlink:label="loc_us-gaap_PreferredStockSharesIssued_604F4027F3B14DC54C9E08C418636573" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_56B90B26DC52437AD10208C4186382F7" xlink:to="loc_us-gaap_PreferredStockSharesIssued_604F4027F3B14DC54C9E08C418636573" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockSharesIssued" xlink:label="loc_us-gaap_CommonStockSharesIssued_9BC4AB55A63FAF37A7C808C4186349F0" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_56B90B26DC52437AD10208C4186382F7" xlink:to="loc_us-gaap_CommonStockSharesIssued_9BC4AB55A63FAF37A7C808C4186349F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockShares" xlink:label="loc_us-gaap_TreasuryStockShares_878B9A7ED699CAF4BF8008C4186306B9" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_56B90B26DC52437AD10208C4186382F7" xlink:to="loc_us-gaap_TreasuryStockShares_878B9A7ED699CAF4BF8008C4186306B9" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_5BF005BF65EB028F0E1B08C419982A78" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_StatementTable_5BF005BF65EB028F0E1B08C419982A78" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_280FA068EADA3C2CC18108C419980690" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_5BF005BF65EB028F0E1B08C419982A78" xlink:to="loc_us-gaap_StatementClassOfStockAxis_280FA068EADA3C2CC18108C419980690" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_ED78B738368B4A7CD50D08C419988C21_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_280FA068EADA3C2CC18108C419980690" xlink:to="loc_us-gaap_ClassOfStockDomain_ED78B738368B4A7CD50D08C419988C21_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_ED78B738368B4A7CD50D08C419988C21" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_280FA068EADA3C2CC18108C419980690" xlink:to="loc_us-gaap_ClassOfStockDomain_ED78B738368B4A7CD50D08C419988C21" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_9CDE203AEFC4F28067B008C41998E46A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_ED78B738368B4A7CD50D08C419988C21" xlink:to="loc_hsy_HersheyCommonStockMember_9CDE203AEFC4F28067B008C41998E46A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_793F299EFEED2DE1559608C41998ACB7" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_ED78B738368B4A7CD50D08C419988C21" xlink:to="loc_us-gaap_CommonClassBMember_793F299EFEED2DE1559608C41998ACB7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueNet" xlink:label="loc_us-gaap_SalesRevenueNet_99BCCD12F0B97066B20108C41998E6B6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_SalesRevenueNet_99BCCD12F0B97066B20108C41998E6B6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostOfGoodsSold" xlink:label="loc_us-gaap_CostOfGoodsSold_457A666D6AC786CDCDD108C419982B43" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_CostOfGoodsSold_457A666D6AC786CDCDD108C419982B43" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GrossProfit" xlink:label="loc_us-gaap_GrossProfit_41CBEE623A04F1A9D46B08C419984210" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_GrossProfit_41CBEE623A04F1A9D46B08C419984210" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpense" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_ADB2F83C3335C117A99A08C419987AD7" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_ADB2F83C3335C117A99A08C419987AD7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AssetImpairmentCharges" xlink:label="loc_us-gaap_AssetImpairmentCharges_9D6CF8699B4409C1A25808C41998CBD7" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_AssetImpairmentCharges_9D6CF8699B4409C1A25808C41998CBD7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillImpairmentLoss" xlink:label="loc_us-gaap_GoodwillImpairmentLoss_462E3B137FFC6F4E967208C41998CDB5" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_GoodwillImpairmentLoss_462E3B137FFC6F4E967208C41998CDB5" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RestructuringChargesBusinessRealignment" xlink:label="loc_hsy_RestructuringChargesBusinessRealignment_F9F97582B5BDA9AD405A08C419980CE7" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_hsy_RestructuringChargesBusinessRealignment_F9F97582B5BDA9AD405A08C419980CE7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_CEB29E500DA02502E29808C41998EBAC" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_OperatingIncomeLoss_CEB29E500DA02502E29808C41998EBAC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_FF4D65AA8AB319FD1E1F08C41998A7C2" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_FF4D65AA8AB319FD1E1F08C41998A7C2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_B3B0E9D00FCF5B90B5C808C41998EBD3" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_B3B0E9D00FCF5B90B5C808C41998EBD3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_0950F3AEEB302248403208C41998E08B" xlink:type="locator"/>
<link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_0950F3AEEB302248403208C41998E08B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxExpenseBenefit" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_8CA86D304A860A22450208C41998FF1B" xlink:type="locator"/>
<link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_8CA86D304A860A22450208C41998FF1B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProfitLoss" xlink:label="loc_us-gaap_ProfitLoss_2344C7D6310885ED88E608C419982608" xlink:type="locator"/>
<link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_ProfitLoss_2344C7D6310885ED88E608C419982608" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_C3A602E2A5EF15E2598708C419984C27" xlink:type="locator"/>
<link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_C3A602E2A5EF15E2598708C419984C27" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_5537BD5274A2000B6AC008C419984CE9" xlink:type="locator"/>
<link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_NetIncomeLoss_5537BD5274A2000B6AC008C419984CE9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasicAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicAbstract_1A0B655615B95060334F08C419989A25" xlink:type="locator"/>
<link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_EarningsPerShareBasicAbstract_1A0B655615B95060334F08C419989A25" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_D946D1690A2E5564437808C41998375B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicAbstract_1A0B655615B95060334F08C419989A25" xlink:to="loc_us-gaap_EarningsPerShareBasic_D946D1690A2E5564437808C41998375B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareDilutedAbstract" xlink:label="loc_us-gaap_EarningsPerShareDilutedAbstract_51872AA1B6A42BB1AA5808C419983A62" xlink:type="locator"/>
<link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_EarningsPerShareDilutedAbstract_51872AA1B6A42BB1AA5808C419983A62" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_B80E3108237D53BE9BD008C4199868A2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedAbstract_51872AA1B6A42BB1AA5808C419983A62" xlink:to="loc_us-gaap_EarningsPerShareDiluted_B80E3108237D53BE9BD008C4199868A2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DividendsCommonStockAbstract" xlink:label="loc_us-gaap_DividendsCommonStockAbstract_12F1ACDC8802579E87D008C4199853E5" xlink:type="locator"/>
<link:definitionArc order="18" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_674AE91958B69D6A1E1608C41998BC06" xlink:to="loc_us-gaap_DividendsCommonStockAbstract_12F1ACDC8802579E87D008C4199853E5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_CCDBA42919A17C3DB72B08C419981CD9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DividendsCommonStockAbstract_12F1ACDC8802579E87D008C4199853E5" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_CCDBA42919A17C3DB72B08C419981CD9" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_B4D91C70F44E199B4CE708C41877F372" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_293220E2F088230EECF408C41877B173" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_B4D91C70F44E199B4CE708C41877F372" xlink:to="loc_us-gaap_StatementTable_293220E2F088230EECF408C41877B173" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_30AFF0AB02A6B0A77F4C08C41877F73A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_293220E2F088230EECF408C41877B173" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_30AFF0AB02A6B0A77F4C08C41877F73A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_6291404D6C84C35D77EA08C41877ED49_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_30AFF0AB02A6B0A77F4C08C41877F73A" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_6291404D6C84C35D77EA08C41877ED49_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_6291404D6C84C35D77EA08C41877ED49" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_30AFF0AB02A6B0A77F4C08C41877F73A" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_6291404D6C84C35D77EA08C41877ED49" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_4DBDA2C2B15E5C1B05AF08C4187761B7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_6291404D6C84C35D77EA08C41877ED49" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_4DBDA2C2B15E5C1B05AF08C4187761B7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_D720F7FDD1BD3493EE8F08C418772C63" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_293220E2F088230EECF408C41877B173" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_D720F7FDD1BD3493EE8F08C418772C63" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_D720F7FDD1BD3493EE8F08C418772C63" xlink:to="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_D720F7FDD1BD3493EE8F08C418772C63" xlink:to="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockMember" xlink:label="loc_us-gaap_PreferredStockMember_A75D157E8C94EEE73A6008C4187766EF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_PreferredStockMember_A75D157E8C94EEE73A6008C4187766EF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_2F0995D7896CEC0CE18108C41877748D" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_CommonStockMember_2F0995D7896CEC0CE18108C41877748D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdditionalPaidInCapitalMember" xlink:label="loc_us-gaap_AdditionalPaidInCapitalMember_38B5B20E8DDA9A0F11C208C418777AE1" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_AdditionalPaidInCapitalMember_38B5B20E8DDA9A0F11C208C418777AE1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_0C0E6901F8006C1A6A9D08C41877040A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_RetainedEarningsMember_0C0E6901F8006C1A6A9D08C41877040A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockMember" xlink:label="loc_us-gaap_TreasuryStockMember_4B4112F9062AA09EA49408C418777FA1" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_TreasuryStockMember_4B4112F9062AA09EA49408C418777FA1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeMember" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_63091023824182D2E6ED08C4187704B1" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_63091023824182D2E6ED08C4187704B1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_FA625E4F7B8E30F8C68408C41877E241" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_986FC469531784B64B0608C41877D2E3" xlink:to="loc_us-gaap_NoncontrollingInterestMember_FA625E4F7B8E30F8C68408C41877E241" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_D304B0645DFE186C813D08C41877E2D2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_293220E2F088230EECF408C41877B173" xlink:to="loc_us-gaap_StatementClassOfStockAxis_D304B0645DFE186C813D08C41877E2D2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_793FC7904B63845EDBC308C418774E37_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_D304B0645DFE186C813D08C41877E2D2" xlink:to="loc_us-gaap_ClassOfStockDomain_793FC7904B63845EDBC308C418774E37_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_793FC7904B63845EDBC308C418774E37" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_D304B0645DFE186C813D08C41877E2D2" xlink:to="loc_us-gaap_ClassOfStockDomain_793FC7904B63845EDBC308C418774E37" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_FB79C56B886950B6513808C418772F13" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_793FC7904B63845EDBC308C418774E37" xlink:to="loc_hsy_HersheyCommonStockMember_FB79C56B886950B6513808C418772F13" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_113F18404AB6195B318D08C41877E08D" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_793FC7904B63845EDBC308C418774E37" xlink:to="loc_us-gaap_CommonClassBMember_113F18404AB6195B318D08C41877E08D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInStockholdersEquityRollForward" xlink:label="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_B4D91C70F44E199B4CE708C41877F372" xlink:to="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_22EE91B1380E7707B29308C41877BA4D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_22EE91B1380E7707B29308C41877BA4D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_A0F97A2DC917AAA14ADE08C418771E36" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_NetIncomeLoss_A0F97A2DC917AAA14ADE08C418771E36" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_3F5270001BD74BC6DF0A08C4187773BD" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_3F5270001BD74BC6DF0A08C4187773BD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProfitLoss" xlink:label="loc_us-gaap_ProfitLoss_D245AB85C1D6BAB42BB608C41877F674" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_ProfitLoss_D245AB85C1D6BAB42BB608C41877F674" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_3D935563781BDBBC74AA08C41881C534" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_3D935563781BDBBC74AA08C41881C534" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DividendsCommonStockAbstract" xlink:label="loc_us-gaap_DividendsCommonStockAbstract_89FDE1E2EAAEBEF6752208C41881BB9F" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_DividendsCommonStockAbstract_89FDE1E2EAAEBEF6752208C41881BB9F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DividendsCommonStockCash" xlink:label="loc_us-gaap_DividendsCommonStockCash_08F397BE312BD10AA49F08C4188172F2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DividendsCommonStockAbstract_89FDE1E2EAAEBEF6752208C41881BB9F" xlink:to="loc_us-gaap_DividendsCommonStockCash_08F397BE312BD10AA49F08C4188172F2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue" xlink:label="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_25225CADE1313E88646408C41881345B" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_25225CADE1313E88646408C41881345B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_5696B4302CFA514F668D08C4188147A7" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_5696B4302CFA514F668D08C4188147A7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockValueAcquiredCostMethod" xlink:label="loc_us-gaap_TreasuryStockValueAcquiredCostMethod_33F1C53AADDAA3AD66A908C418818AF8" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_TreasuryStockValueAcquiredCostMethod_33F1C53AADDAA3AD66A908C418818AF8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ReclassificationsOfTemporaryToPermanentEquity" xlink:label="loc_us-gaap_ReclassificationsOfTemporaryToPermanentEquity_735D1367D0BC5284E2C908C418814FBC" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_C597223BA92C006D806008C418779B1C" xlink:to="loc_us-gaap_ReclassificationsOfTemporaryToPermanentEquity_735D1367D0BC5284E2C908C418814FBC" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_3F115423E23D9FBFCC3908C4170F6132" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_219FC2B911C5309A92D608C4170F2047" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_3F115423E23D9FBFCC3908C4170F6132" xlink:to="loc_us-gaap_StatementTable_219FC2B911C5309A92D608C4170F2047" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_3BEA99D19996145470FA08C4170F60B1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_219FC2B911C5309A92D608C4170F2047" xlink:to="loc_us-gaap_StatementClassOfStockAxis_3BEA99D19996145470FA08C4170F60B1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_938CA7E02A1F68F0873A08C4170F2566_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_3BEA99D19996145470FA08C4170F60B1" xlink:to="loc_us-gaap_ClassOfStockDomain_938CA7E02A1F68F0873A08C4170F2566_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_938CA7E02A1F68F0873A08C4170F2566" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_3BEA99D19996145470FA08C4170F60B1" xlink:to="loc_us-gaap_ClassOfStockDomain_938CA7E02A1F68F0873A08C4170F2566" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_9D0ECACBFEF6E49E54ED08C4170F482A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_938CA7E02A1F68F0873A08C4170F2566" xlink:to="loc_hsy_HersheyCommonStockMember_9D0ECACBFEF6E49E54ED08C4170F482A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_EFAB6DA69685705A441608C4170F433C" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_938CA7E02A1F68F0873A08C4170F2566" xlink:to="loc_us-gaap_CommonClassBMember_EFAB6DA69685705A441608C4170F433C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_6358DA39FA035B0D3F9008C4170F1A22" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_3F115423E23D9FBFCC3908C4170F6132" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_6358DA39FA035B0D3F9008C4170F1A22" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_544C7FA91B5176F09D2608C417911FE0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_544C7FA91B5176F09D2608C417911FE0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_544C7FA91B5176F09D2608C417911FE0" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_544C7FA91B5176F09D2608C417911FE0" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_353DE4CE3F531A342BB608C41791D64E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:to="loc_us-gaap_CommodityContractMember_353DE4CE3F531A342BB608C41791D64E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_34508711E321EC0ABAD808C417918604" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:to="loc_us-gaap_ForeignExchangeContractMember_34508711E321EC0ABAD808C417918604" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_932CEAF309BC03592EF508C417914D79" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:to="loc_us-gaap_InterestRateContractMember_932CEAF309BC03592EF508C417914D79" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_0BF9C1D3F2FD9B54E89F08C417918BBA" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:to="loc_us-gaap_EquitySwapMember_0BF9C1D3F2FD9B54E89F08C417918BBA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestRateSwapMember" xlink:label="loc_us-gaap_InterestRateSwapMember_1A92E429506511E219B908C41791A542" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_11D1914C2FFA629D8A8708C417912627" xlink:to="loc_us-gaap_InterestRateSwapMember_1A92E429506511E219B908C41791A542" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_4BF1816CA374F8BAE91808C4179147C3" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:to="loc_us-gaap_HedgingDesignationAxis_4BF1816CA374F8BAE91808C4179147C3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_65DE6AF86045C8151BAB08C417917CCB_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_4BF1816CA374F8BAE91808C4179147C3" xlink:to="loc_us-gaap_HedgingDesignationDomain_65DE6AF86045C8151BAB08C417917CCB_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_65DE6AF86045C8151BAB08C417917CCB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_4BF1816CA374F8BAE91808C4179147C3" xlink:to="loc_us-gaap_HedgingDesignationDomain_65DE6AF86045C8151BAB08C417917CCB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_722B834DF35AB59DDEE208C41791280E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_65DE6AF86045C8151BAB08C417917CCB" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_722B834DF35AB59DDEE208C41791280E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_8CF5FD5642DFBEE3A2A108C4179128E4" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_65DE6AF86045C8151BAB08C417917CCB" xlink:to="loc_us-gaap_NondesignatedMember_8CF5FD5642DFBEE3A2A108C4179128E4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B7F9AF8D852E1BCB76A608C41791E29B" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B7F9AF8D852E1BCB76A608C41791E29B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_26CC24D0C756F0941F1E08C41791E0C5_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B7F9AF8D852E1BCB76A608C41791E29B" xlink:to="loc_us-gaap_HedgingRelationshipDomain_26CC24D0C756F0941F1E08C41791E0C5_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_26CC24D0C756F0941F1E08C41791E0C5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_B7F9AF8D852E1BCB76A608C41791E29B" xlink:to="loc_us-gaap_HedgingRelationshipDomain_26CC24D0C756F0941F1E08C41791E0C5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_994FB020E366EB59694E08C4179165A0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_26CC24D0C756F0941F1E08C41791E0C5" xlink:to="loc_us-gaap_CashFlowHedgingMember_994FB020E366EB59694E08C4179165A0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_DB32FBDC336FD4D3A5CF08C417919CD0" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_26CC24D0C756F0941F1E08C41791E0C5" xlink:to="loc_us-gaap_FairValueHedgingMember_DB32FBDC336FD4D3A5CF08C417919CD0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_F2EA660A0929E9B5EC4108C41791DFDE" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:to="loc_us-gaap_RangeAxis_F2EA660A0929E9B5EC4108C41791DFDE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_2F913C4872B6730EAB6508C41791B99A_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_F2EA660A0929E9B5EC4108C41791DFDE" xlink:to="loc_us-gaap_RangeMember_2F913C4872B6730EAB6508C41791B99A_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_2F913C4872B6730EAB6508C41791B99A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_F2EA660A0929E9B5EC4108C41791DFDE" xlink:to="loc_us-gaap_RangeMember_2F913C4872B6730EAB6508C41791B99A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_E99F72729E2F39A0A4DD08C417912D4E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_2F913C4872B6730EAB6508C41791B99A" xlink:to="loc_us-gaap_MinimumMember_E99F72729E2F39A0A4DD08C417912D4E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_65E1594AB9FDA378DE8208C41791D29B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_2F913C4872B6730EAB6508C41791B99A" xlink:to="loc_us-gaap_MaximumMember_65E1594AB9FDA378DE8208C41791D29B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_60DFE33EBA2B4295136008C41791849C" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_9375FF9B09A16C097CAF08C41791502F" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_60DFE33EBA2B4295136008C41791849C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_789175C575A5E2DBE85F08C417913332_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_60DFE33EBA2B4295136008C41791849C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_789175C575A5E2DBE85F08C417913332_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_789175C575A5E2DBE85F08C417913332" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_60DFE33EBA2B4295136008C41791849C" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_789175C575A5E2DBE85F08C417913332" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestExpenseMember" xlink:label="loc_us-gaap_InterestExpenseMember_CF679F2C20F2574E357D08C417913CD6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_789175C575A5E2DBE85F08C417913332" xlink:to="loc_us-gaap_InterestExpenseMember_CF679F2C20F2574E357D08C417913CD6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeTermOfContract" xlink:label="loc_us-gaap_DerivativeTermOfContract_A6347C33F82CC4CF539708C41791480F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_us-gaap_DerivativeTermOfContract_A6347C33F82CC4CF539708C41791480F" 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_785CBDC3AA5AD2F13B2C08C41791CEA0" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_invest_DerivativeNotionalAmount_785CBDC3AA5AD2F13B2C08C41791CEA0" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MinimumLengthofTimeHedgedinCashFlowHedge" xlink:label="loc_hsy_MinimumLengthofTimeHedgedinCashFlowHedge_F8F1843589AE00D6FE4808C41791E1E2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_hsy_MinimumLengthofTimeHedgedinCashFlowHedge_F8F1843589AE00D6FE4808C41791E1E2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1" xlink:label="loc_us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1_34EDB76CCD56A312D96108C41791897D" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_us-gaap_MaximumLengthOfTimeHedgedInCashFlowHedge1_34EDB76CCD56A312D96108C41791897D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInDerivativeAssetsAndLiabilities" xlink:label="loc_us-gaap_IncreaseDecreaseInDerivativeAssetsAndLiabilities_0008C9D8A54455EC0A3F08C417913965" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_us-gaap_IncreaseDecreaseInDerivativeAssetsAndLiabilities_0008C9D8A54455EC0A3F08C417913965" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths" xlink:label="loc_us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths_9BB0834495F48847FD7408C4179192E6" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_us-gaap_CashFlowHedgeGainLossToBeReclassifiedWithinTwelveMonths_9BB0834495F48847FD7408C4179192E6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1" xlink:label="loc_us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1_ADE66D08603B1AA3430908C41791EE5E" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_51E1B7C463DEB6B5748C08C41791121F" xlink:to="loc_us-gaap_IncreaseDecreaseInFairValueOfHedgedItemInInterestRateFairValueHedge1_ADE66D08603B1AA3430908C41791EE5E" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativesFairValueLineItems" xlink:label="loc_us-gaap_DerivativesFairValueLineItems_91256DA7F8243C03D2D008C419FCBCC2" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable" xlink:label="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_6E635ACE1D87965C9BD708C419FC2B59" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_91256DA7F8243C03D2D008C419FCBCC2" xlink:to="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_6E635ACE1D87965C9BD708C419FC2B59" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_A9985952D120F33C5A6508C419FC8217" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_6E635ACE1D87965C9BD708C419FC2B59" xlink:to="loc_us-gaap_HedgingDesignationAxis_A9985952D120F33C5A6508C419FC8217" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_380F7011EE9339E41EBF08C419FC8BAA_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_A9985952D120F33C5A6508C419FC8217" xlink:to="loc_us-gaap_HedgingDesignationDomain_380F7011EE9339E41EBF08C419FC8BAA_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_380F7011EE9339E41EBF08C419FC8BAA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_A9985952D120F33C5A6508C419FC8217" xlink:to="loc_us-gaap_HedgingDesignationDomain_380F7011EE9339E41EBF08C419FC8BAA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_9E56087F1F8AF609023008C419FC8285" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_380F7011EE9339E41EBF08C419FC8BAA" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_9E56087F1F8AF609023008C419FC8285" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_C50FA1227CBF3F1AACE008C419FCBCCD" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_380F7011EE9339E41EBF08C419FC8BAA" xlink:to="loc_us-gaap_NondesignatedMember_C50FA1227CBF3F1AACE008C419FCBCCD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_46B4136A075A4A347A2508C419FCF6D6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_6E635ACE1D87965C9BD708C419FC2B59" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_46B4136A075A4A347A2508C419FCF6D6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_07D1AADE94ECD900C93608C419FCBF81_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_46B4136A075A4A347A2508C419FCF6D6" xlink:to="loc_us-gaap_HedgingRelationshipDomain_07D1AADE94ECD900C93608C419FCBF81_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_07D1AADE94ECD900C93608C419FCBF81" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_46B4136A075A4A347A2508C419FCF6D6" xlink:to="loc_us-gaap_HedgingRelationshipDomain_07D1AADE94ECD900C93608C419FCBF81" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_3A84BFB0DD962A51939708C419FCEF78" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_07D1AADE94ECD900C93608C419FCBF81" xlink:to="loc_us-gaap_CashFlowHedgingMember_3A84BFB0DD962A51939708C419FCEF78" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueHedgingMember" xlink:label="loc_us-gaap_FairValueHedgingMember_3EE569D33DAE2B60801E08C419FCDCDB" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_07D1AADE94ECD900C93608C419FCBF81" xlink:to="loc_us-gaap_FairValueHedgingMember_3EE569D33DAE2B60801E08C419FCDCDB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_0998D1DC0E2E7A4FA99008C419FCA78C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_6E635ACE1D87965C9BD708C419FC2B59" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_0998D1DC0E2E7A4FA99008C419FCA78C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_0998D1DC0E2E7A4FA99008C419FCA78C" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_0998D1DC0E2E7A4FA99008C419FCA78C" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_F7DB659552DB41DB657108C419FC560A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241" xlink:to="loc_us-gaap_CommodityContractMember_F7DB659552DB41DB657108C419FC560A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_189298B1C6447EC5680108C419FCD9D6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241" xlink:to="loc_us-gaap_ForeignExchangeContractMember_189298B1C6447EC5680108C419FCD9D6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_ED9DAD3CC74BC4E4F47508C419FCB4D6" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241" xlink:to="loc_us-gaap_InterestRateContractMember_ED9DAD3CC74BC4E4F47508C419FCB4D6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_BAC5060E148A4B5B4FD108C419FC3165" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_EB9098B2D89072050CF008C419FC6241" xlink:to="loc_us-gaap_EquitySwapMember_BAC5060E148A4B5B4FD108C419FC3165" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_308872360651DE96C9EE08C419FCADA0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_91256DA7F8243C03D2D008C419FCBCC2" xlink:to="loc_us-gaap_DerivativeAssets_308872360651DE96C9EE08C419FCADA0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_FC6F8955DFB74D7F0CDA08C419FC1F7D" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_91256DA7F8243C03D2D008C419FCBCC2" xlink:to="loc_us-gaap_DerivativeLiabilities_FC6F8955DFB74D7F0CDA08C419FC1F7D" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading" xlink:label="loc_hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_2D6A752A8DA51353E14E08C419FC488C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_91256DA7F8243C03D2D008C419FCBCC2" xlink:to="loc_hsy_DerivativeAssetCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_2D6A752A8DA51353E14E08C419FC488C" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading" xlink:label="loc_hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_84EB1DB7BE95BF6D2EB608C419FC00FC" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_91256DA7F8243C03D2D008C419FCBCC2" xlink:to="loc_hsy_DerivativeLiabilityCashTransfersReceivablePayableChangeInQuotedMarketPricesOnTheLastDayOfTrading_84EB1DB7BE95BF6D2EB608C419FC00FC" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_DBBDB91FFDC0D57685A008C41A2410C9" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_45F9FA75FD240423077808C41A24C00F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_DBBDB91FFDC0D57685A008C41A2410C9" xlink:to="loc_us-gaap_DerivativeTable_45F9FA75FD240423077808C41A24C00F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_4F52E827257DDD5D94DA08C41A24130B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_45F9FA75FD240423077808C41A24C00F" xlink:to="loc_us-gaap_HedgingDesignationAxis_4F52E827257DDD5D94DA08C41A24130B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_3A6C7545A0C4512A408608C41A24B8D7_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_4F52E827257DDD5D94DA08C41A24130B" xlink:to="loc_us-gaap_HedgingDesignationDomain_3A6C7545A0C4512A408608C41A24B8D7_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_3A6C7545A0C4512A408608C41A24B8D7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_4F52E827257DDD5D94DA08C41A24130B" xlink:to="loc_us-gaap_HedgingDesignationDomain_3A6C7545A0C4512A408608C41A24B8D7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DesignatedAsHedgingInstrumentMember" xlink:label="loc_us-gaap_DesignatedAsHedgingInstrumentMember_D97CDAF66CF9F512CDA108C41A24AAFB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_3A6C7545A0C4512A408608C41A24B8D7" xlink:to="loc_us-gaap_DesignatedAsHedgingInstrumentMember_D97CDAF66CF9F512CDA108C41A24AAFB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C216B98215212C7F2C9C08C41A244B7C" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_45F9FA75FD240423077808C41A24C00F" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C216B98215212C7F2C9C08C41A244B7C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_40B8AD127CBBBB30D0F408C41A246096_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C216B98215212C7F2C9C08C41A244B7C" xlink:to="loc_us-gaap_HedgingRelationshipDomain_40B8AD127CBBBB30D0F408C41A246096_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingRelationshipDomain" xlink:label="loc_us-gaap_HedgingRelationshipDomain_40B8AD127CBBBB30D0F408C41A246096" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentsGainLossByHedgingRelationshipAxis_C216B98215212C7F2C9C08C41A244B7C" xlink:to="loc_us-gaap_HedgingRelationshipDomain_40B8AD127CBBBB30D0F408C41A246096" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashFlowHedgingMember" xlink:label="loc_us-gaap_CashFlowHedgingMember_8EAF494EEA7D567DBE3F08C41A24C971" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingRelationshipDomain_40B8AD127CBBBB30D0F408C41A246096" xlink:to="loc_us-gaap_CashFlowHedgingMember_8EAF494EEA7D567DBE3F08C41A24C971" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_DA77F6332F61E7040CE708C41A24C3CD" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_45F9FA75FD240423077808C41A24C00F" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_DA77F6332F61E7040CE708C41A24C3CD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_DA77F6332F61E7040CE708C41A24C3CD" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_DA77F6332F61E7040CE708C41A24C3CD" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_4752BAC0A3DF6353C6E008C41A24C669" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845" xlink:to="loc_us-gaap_CommodityContractMember_4752BAC0A3DF6353C6E008C41A24C669" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_C48ECE55C562BADC0F5F08C41A24791E" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845" xlink:to="loc_us-gaap_ForeignExchangeContractMember_C48ECE55C562BADC0F5F08C41A24791E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_4D6BC8331677FD05E8F808C41A243541" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845" xlink:to="loc_us-gaap_InterestRateContractMember_4D6BC8331677FD05E8F808C41A243541" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_AC2621AA11386AFB6DBE08C41A24F1C4" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_3E20C2541BFCBAF27BCB08C41A246845" xlink:to="loc_us-gaap_EquitySwapMember_AC2621AA11386AFB6DBE08C41A24F1C4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet" xlink:label="loc_us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet_93CD1EB48B0EF5E0FC4208C41A24B28E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_DBBDB91FFDC0D57685A008C41A2410C9" xlink:to="loc_us-gaap_DerivativeInstrumentsNotDesignatedAsHedgingInstrumentsGainLossNet_93CD1EB48B0EF5E0FC4208C41A24B28E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossRecognizedInOtherComprehensiveIncomeEffectivePortionNet" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossRecognizedInOtherComprehensiveIncomeEffectivePortionNet_E0EE36403D272BE9A51D08C41A2EF1F2" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_DBBDB91FFDC0D57685A008C41A2410C9" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossRecognizedInOtherComprehensiveIncomeEffectivePortionNet_E0EE36403D272BE9A51D08C41A2EF1F2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsGainLossReclassifiedFromAccumulatedOCIIntoIncomeEffectivePortionNet" xlink:label="loc_us-gaap_DerivativeInstrumentsGainLossReclassifiedFromAccumulatedOCIIntoIncomeEffectivePortionNet_D185DCE37DCDE1F1375308C41A2EB2C1" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_DBBDB91FFDC0D57685A008C41A2410C9" xlink:to="loc_us-gaap_DerivativeInstrumentsGainLossReclassifiedFromAccumulatedOCIIntoIncomeEffectivePortionNet_D185DCE37DCDE1F1375308C41A2EB2C1" 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="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_DocumentInformationLineItems" xlink:label="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_DocumentInformationTable" xlink:label="loc_dei_DocumentInformationTable_7AE856D61E470239854808C417F5DA77" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_DocumentInformationTable_7AE856D61E470239854808C417F5DA77" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_43941B20A45367C08A9708C417F5B6B2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_dei_DocumentInformationTable_7AE856D61E470239854808C417F5DA77" xlink:to="loc_us-gaap_StatementClassOfStockAxis_43941B20A45367C08A9708C417F5B6B2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_AD9CC3A6A5DBE90C666808C417F54B55_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_43941B20A45367C08A9708C417F5B6B2" xlink:to="loc_us-gaap_ClassOfStockDomain_AD9CC3A6A5DBE90C666808C417F54B55_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_AD9CC3A6A5DBE90C666808C417F54B55" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_43941B20A45367C08A9708C417F5B6B2" xlink:to="loc_us-gaap_ClassOfStockDomain_AD9CC3A6A5DBE90C666808C417F54B55" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_D6003D91406EF47DEE6108C417F5BDEE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_AD9CC3A6A5DBE90C666808C417F54B55" xlink:to="loc_hsy_HersheyCommonStockMember_D6003D91406EF47DEE6108C417F5BDEE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_8D2BFB8A4E3C8FFEAE3408C417F5B2AC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_AD9CC3A6A5DBE90C666808C417F54B55" xlink:to="loc_us-gaap_CommonClassBMember_8D2BFB8A4E3C8FFEAE3408C417F5B2AC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityRegistrantName" xlink:label="loc_dei_EntityRegistrantName_8BE2EEC6B7EA9DB7520108C417FF608F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityRegistrantName_8BE2EEC6B7EA9DB7520108C417FF608F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityCentralIndexKey" xlink:label="loc_dei_EntityCentralIndexKey_33E515DDF132FE44E94808C417FF11A9" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityCentralIndexKey_33E515DDF132FE44E94808C417FF11A9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_CurrentFiscalYearEndDate" xlink:label="loc_dei_CurrentFiscalYearEndDate_6AC80C50E0F02494BFF308C417FF43E7" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_CurrentFiscalYearEndDate_6AC80C50E0F02494BFF308C417FF43E7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityFilerCategory" xlink:label="loc_dei_EntityFilerCategory_F571E96337FA5F36CA5208C417FF820A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityFilerCategory_F571E96337FA5F36CA5208C417FF820A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_DocumentType" xlink:label="loc_dei_DocumentType_B72C67CB20B785588D4308C417FF11F0" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_DocumentType_B72C67CB20B785588D4308C417FF11F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_DocumentPeriodEndDate" xlink:label="loc_dei_DocumentPeriodEndDate_30684C5B444D65C44BAF08C417FF91C5" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_DocumentPeriodEndDate_30684C5B444D65C44BAF08C417FF91C5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_DocumentFiscalYearFocus" xlink:label="loc_dei_DocumentFiscalYearFocus_942E7B46F9627EB0E0A708C417FF6D98" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_DocumentFiscalYearFocus_942E7B46F9627EB0E0A708C417FF6D98" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_DocumentFiscalPeriodFocus" xlink:label="loc_dei_DocumentFiscalPeriodFocus_F40220E94AC6B7D1B37C08C417FFBF12" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_DocumentFiscalPeriodFocus_F40220E94AC6B7D1B37C08C417FFBF12" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_AmendmentFlag" xlink:label="loc_dei_AmendmentFlag_5108ACB9506444D1F40A08C417FFB21A" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_AmendmentFlag_5108ACB9506444D1F40A08C417FFB21A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityCommonStockSharesOutstanding" xlink:label="loc_dei_EntityCommonStockSharesOutstanding_331AE346128384BF9D5B08C417FF7E34" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityCommonStockSharesOutstanding_331AE346128384BF9D5B08C417FF7E34" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityWellKnownSeasonedIssuer" xlink:label="loc_dei_EntityWellKnownSeasonedIssuer_AA7F57CAF08DB96593F808C417FF77F0" xlink:type="locator"/>
<link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityWellKnownSeasonedIssuer_AA7F57CAF08DB96593F808C417FF77F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityVoluntaryFilers" xlink:label="loc_dei_EntityVoluntaryFilers_DFD3E9F673E3BD64434608C417FFAD0B" xlink:type="locator"/>
<link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityVoluntaryFilers_DFD3E9F673E3BD64434608C417FFAD0B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityCurrentReportingStatus" xlink:label="loc_dei_EntityCurrentReportingStatus_50C33EBE03045083B3D808C417FF810A" xlink:type="locator"/>
<link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityCurrentReportingStatus_50C33EBE03045083B3D808C417FF810A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityPublicFloat" xlink:label="loc_dei_EntityPublicFloat_65DE353BD2014D1F622D08C417FF91D0" xlink:type="locator"/>
<link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_DocumentInformationLineItems_2E330AC5C410AD428C4808C417FFAA74" xlink:to="loc_dei_EntityPublicFloat_65DE353BD2014D1F622D08C417FF91D0" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_CBB16E28EF36AF6152DC08C41A60D579" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable" xlink:label="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_9CB5BF9D222F584AD85308C41A568961" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_CBB16E28EF36AF6152DC08C41A60D579" xlink:to="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_9CB5BF9D222F584AD85308C41A568961" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_1D12485C71DC761E87C808C41A564FB9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_9CB5BF9D222F584AD85308C41A568961" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_1D12485C71DC761E87C808C41A564FB9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AntidilutiveSecuritiesNameDomain" xlink:label="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1CE0E109B465F7D8799108C41A5688C3_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_1D12485C71DC761E87C808C41A564FB9" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1CE0E109B465F7D8799108C41A5688C3_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AntidilutiveSecuritiesNameDomain" xlink:label="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1CE0E109B465F7D8799108C41A5688C3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_1D12485C71DC761E87C808C41A564FB9" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1CE0E109B465F7D8799108C41A5688C3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_AA08BFBD20467F02358408C41A60E390" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_1CE0E109B465F7D8799108C41A5688C3" xlink:to="loc_us-gaap_EmployeeStockOptionMember_AA08BFBD20467F02358408C41A60E390" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount" xlink:label="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_56DAD0A74F200D8EAEAF08C41A606D43" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_CBB16E28EF36AF6152DC08C41A60D579" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_56DAD0A74F200D8EAEAF08C41A606D43" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_AC319B7C212AA71B1AB708C4191B8B55" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_AC319B7C212AA71B1AB708C4191B8B55" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_4430EA8A7C1274B4F5D808C4191BE74D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_AC319B7C212AA71B1AB708C4191B8B55" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_4430EA8A7C1274B4F5D808C4191BE74D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_4430EA8A7C1274B4F5D808C4191BE74D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_AC319B7C212AA71B1AB708C4191B8B55" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_4430EA8A7C1274B4F5D808C4191BE74D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpensesMember" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_20551E19D5E46D83291A08C4191BC4D4" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_4430EA8A7C1274B4F5D808C4191BE74D" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpensesMember_20551E19D5E46D83291A08C4191BC4D4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_1FDA51A2ED4B554A8F5208C4191C3DF1" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:to="loc_us-gaap_AwardTypeAxis_1FDA51A2ED4B554A8F5208C4191C3DF1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_318B2CEE1E07FFE5AE0B08C4191CF0E1_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_1FDA51A2ED4B554A8F5208C4191C3DF1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_318B2CEE1E07FFE5AE0B08C4191CF0E1_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_318B2CEE1E07FFE5AE0B08C4191CF0E1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_1FDA51A2ED4B554A8F5208C4191C3DF1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_318B2CEE1E07FFE5AE0B08C4191CF0E1" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_0E1CD2DC78920B40DE7408C4191C29EE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_318B2CEE1E07FFE5AE0B08C4191CF0E1" xlink:to="loc_hsy_HersheyTrustCompanyMember_0E1CD2DC78920B40DE7408C4191C29EE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_15E5398F3A21C49D486A08C4191C3FA6" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:to="loc_us-gaap_StatementClassOfStockAxis_15E5398F3A21C49D486A08C4191C3FA6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BAEC5DF3B1F34480BD5708C4191C604C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_15E5398F3A21C49D486A08C4191C3FA6" xlink:to="loc_us-gaap_ClassOfStockDomain_BAEC5DF3B1F34480BD5708C4191C604C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BAEC5DF3B1F34480BD5708C4191C604C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_15E5398F3A21C49D486A08C4191C3FA6" xlink:to="loc_us-gaap_ClassOfStockDomain_BAEC5DF3B1F34480BD5708C4191C604C" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_D5D3339D4B96342C13FE08C4191CCD08" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_BAEC5DF3B1F34480BD5708C4191C604C" xlink:to="loc_hsy_HersheyCommonStockMember_D5D3339D4B96342C13FE08C4191CCD08" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_A7043304036437316EE208C4191D5B61" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_BAEC5DF3B1F34480BD5708C4191C604C" xlink:to="loc_us-gaap_CommonClassBMember_A7043304036437316EE208C4191D5B61" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CounterpartyNameAxis" xlink:label="loc_us-gaap_CounterpartyNameAxis_193E973896676191D13608C4191D01AA" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:to="loc_us-gaap_CounterpartyNameAxis_193E973896676191D13608C4191D01AA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RepurchaseAgreementCounterpartyNameDomain" xlink:label="loc_us-gaap_RepurchaseAgreementCounterpartyNameDomain_4D33941D7EA95A6C749908C4191DC8E9_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CounterpartyNameAxis_193E973896676191D13608C4191D01AA" xlink:to="loc_us-gaap_RepurchaseAgreementCounterpartyNameDomain_4D33941D7EA95A6C749908C4191DC8E9_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RepurchaseAgreementCounterpartyNameDomain" xlink:label="loc_us-gaap_RepurchaseAgreementCounterpartyNameDomain_4D33941D7EA95A6C749908C4191DC8E9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CounterpartyNameAxis_193E973896676191D13608C4191D01AA" xlink:to="loc_us-gaap_RepurchaseAgreementCounterpartyNameDomain_4D33941D7EA95A6C749908C4191DC8E9" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_447F76C5AB43114E443908C4191D2FC8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RepurchaseAgreementCounterpartyNameDomain_4D33941D7EA95A6C749908C4191DC8E9" xlink:to="loc_hsy_HersheyTrustCompanyMember_447F76C5AB43114E443908C4191D2FC8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_CA21A6EB5B74BC524A3508C4191DB261" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_CA21A6EB5B74BC524A3508C4191DB261" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_C00D9F999BC2A6545D4E08C4191D0A60_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_CA21A6EB5B74BC524A3508C4191DB261" xlink:to="loc_us-gaap_EquityComponentDomain_C00D9F999BC2A6545D4E08C4191D0A60_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_C00D9F999BC2A6545D4E08C4191D0A60" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_CA21A6EB5B74BC524A3508C4191DB261" xlink:to="loc_us-gaap_EquityComponentDomain_C00D9F999BC2A6545D4E08C4191D0A60" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_853314A86CF38650FA9E08C4191D4530" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_C00D9F999BC2A6545D4E08C4191D0A60" xlink:to="loc_us-gaap_NoncontrollingInterestMember_853314A86CF38650FA9E08C4191D4530" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_LegalEntityAxis" xlink:label="loc_dei_LegalEntityAxis_242AFF28FE7DEEEFC07A08C4191E0890" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_858001BA348482A2C60D08C4191BA600" xlink:to="loc_dei_LegalEntityAxis_242AFF28FE7DEEEFC07A08C4191E0890" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_FA2C62AF7781BCCA57C308C4191E6F78_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_dei_LegalEntityAxis_242AFF28FE7DEEEFC07A08C4191E0890" xlink:to="loc_dei_EntityDomain_FA2C62AF7781BCCA57C308C4191E6F78_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_FA2C62AF7781BCCA57C308C4191E6F78" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_dei_LegalEntityAxis_242AFF28FE7DEEEFC07A08C4191E0890" xlink:to="loc_dei_EntityDomain_FA2C62AF7781BCCA57C308C4191E6F78" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_LotteShanghaiFoodCompanyMember" xlink:label="loc_hsy_LotteShanghaiFoodCompanyMember_20B82F7A826ABDCFB21D08C4191EB8B6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityDomain_FA2C62AF7781BCCA57C308C4191E6F78" xlink:to="loc_hsy_LotteShanghaiFoodCompanyMember_20B82F7A826ABDCFB21D08C4191EB8B6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_5F9478C50B33BD9BC92008C4191E2DE2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_5F9478C50B33BD9BC92008C4191E2DE2" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_CommonandPreferredStockSharesAuthorized" xlink:label="loc_hsy_CommonandPreferredStockSharesAuthorized_45A7723EE08587EDF9FE08C4191EDF36" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_hsy_CommonandPreferredStockSharesAuthorized_45A7723EE08587EDF9FE08C4191EDF36" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockSharesAuthorized" xlink:label="loc_us-gaap_CommonStockSharesAuthorized_3E6F53EBF1F6D700C07D08C4191F423A" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_CommonStockSharesAuthorized_3E6F53EBF1F6D700C07D08C4191F423A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockSharesAuthorized" xlink:label="loc_us-gaap_PreferredStockSharesAuthorized_B4C3E8F7D0142A5EF8B308C4191F71C1" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_PreferredStockSharesAuthorized_B4C3E8F7D0142A5EF8B308C4191F71C1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockParOrStatedValuePerShare" xlink:label="loc_us-gaap_CommonStockParOrStatedValuePerShare_933C2B73AB824F392D7108C4191FF7A2" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_CommonStockParOrStatedValuePerShare_933C2B73AB824F392D7108C4191FF7A2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockParOrStatedValuePerShare" xlink:label="loc_us-gaap_PreferredStockParOrStatedValuePerShare_80EB4D8362DD7B8425E408C4191F0BA0" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_PreferredStockParOrStatedValuePerShare_80EB4D8362DD7B8425E408C4191F0BA0" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_CommonStockVotingRightsBoardElectionPercentage" xlink:label="loc_hsy_CommonStockVotingRightsBoardElectionPercentage_5C7FBE6B3AB84A868D3B08C4191F5E07" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_hsy_CommonStockVotingRightsBoardElectionPercentage_5C7FBE6B3AB84A868D3B08C4191F5E07" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_CommonStockNumberofVotes" xlink:label="loc_hsy_CommonStockNumberofVotes_70E3B72713E9C5592A4208C4191FF7C1" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_hsy_CommonStockNumberofVotes_70E3B72713E9C5592A4208C4191FF7C1" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends" xlink:label="loc_hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends_388FFD0B947CDA1DDF6B08C4191F5AFA" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_hsy_DividendsCommonStockCashAdditionalPercentageOverClassBCommonStockDividends_388FFD0B947CDA1DDF6B08C4191F5AFA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConversionOfStockSharesConverted1" xlink:label="loc_us-gaap_ConversionOfStockSharesConverted1_0FCD39180237117D88B808C4191F5F67" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_ConversionOfStockSharesConverted1_0FCD39180237117D88B808C4191F5F67" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockSharesOutstanding" xlink:label="loc_us-gaap_CommonStockSharesOutstanding_DB6D9CFE087659AA195808C4191F47B5" xlink:type="locator"/>
<link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_DB6D9CFE087659AA195808C4191F47B5" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_CommonStockVotingPercentage" xlink:label="loc_hsy_CommonStockVotingPercentage_B02B22C3132CD43C569308C419200BE2" xlink:type="locator"/>
<link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_hsy_CommonStockVotingPercentage_B02B22C3132CD43C569308C419200BE2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockSharesAcquired" xlink:label="loc_us-gaap_TreasuryStockSharesAcquired_FE7C292EB377E5E95AFD08C419200F25" xlink:type="locator"/>
<link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_TreasuryStockSharesAcquired_FE7C292EB377E5E95AFD08C419200F25" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockAcquiredAverageCostPerShare" xlink:label="loc_us-gaap_TreasuryStockAcquiredAverageCostPerShare_4A9D57592EC8C5408E6908C419207559" xlink:type="locator"/>
<link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_TreasuryStockAcquiredAverageCostPerShare_4A9D57592EC8C5408E6908C419207559" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockRepurchasedDuringPeriodValue" xlink:label="loc_us-gaap_StockRepurchasedDuringPeriodValue_A7BAD8A25333C70AA3FC08C4192097F0" xlink:type="locator"/>
<link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_StockRepurchasedDuringPeriodValue_A7BAD8A25333C70AA3FC08C4192097F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinorityInterestOwnershipPercentageByParent" xlink:label="loc_us-gaap_MinorityInterestOwnershipPercentageByParent_94B3BB0E03060EE0652E08C41920E4E0" xlink:type="locator"/>
<link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_98B8115266FA46BB05B008C4191EB810" xlink:to="loc_us-gaap_MinorityInterestOwnershipPercentageByParent_94B3BB0E03060EE0652E08C41920E4E0" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinorityInterestLineItems" xlink:label="loc_us-gaap_MinorityInterestLineItems_438F632175FA5ACB19F308C41A88429F" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinorityInterestTable" xlink:label="loc_us-gaap_MinorityInterestTable_6EEFF547C5B73131B8B008C41A88B651" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_MinorityInterestLineItems_438F632175FA5ACB19F308C41A88429F" xlink:to="loc_us-gaap_MinorityInterestTable_6EEFF547C5B73131B8B008C41A88B651" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_4CA9805A2D0771D7159008C41A886FF1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_MinorityInterestTable_6EEFF547C5B73131B8B008C41A88B651" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_4CA9805A2D0771D7159008C41A886FF1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_96A48EAD77C5740969E708C41A886B8D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_4CA9805A2D0771D7159008C41A886FF1" xlink:to="loc_us-gaap_EquityComponentDomain_96A48EAD77C5740969E708C41A886B8D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityComponentDomain" xlink:label="loc_us-gaap_EquityComponentDomain_96A48EAD77C5740969E708C41A886B8D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_4CA9805A2D0771D7159008C41A886FF1" xlink:to="loc_us-gaap_EquityComponentDomain_96A48EAD77C5740969E708C41A886B8D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncontrollingInterestMember" xlink:label="loc_us-gaap_NoncontrollingInterestMember_AB457CEE182B53AC26EC08C41A88E7AD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_96A48EAD77C5740969E708C41A886B8D" xlink:to="loc_us-gaap_NoncontrollingInterestMember_AB457CEE182B53AC26EC08C41A88E7AD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MovementInMinorityInterestRollForward" xlink:label="loc_us-gaap_MovementInMinorityInterestRollForward_86FA10008FC2C60B517C08C41A88516F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MinorityInterestLineItems_438F632175FA5ACB19F308C41A88429F" xlink:to="loc_us-gaap_MovementInMinorityInterestRollForward_86FA10008FC2C60B517C08C41A88516F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinorityInterest" xlink:label="loc_us-gaap_MinorityInterest_7B47DF01025927D2249608C41A884D38" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_86FA10008FC2C60B517C08C41A88516F" xlink:to="loc_us-gaap_MinorityInterest_7B47DF01025927D2249608C41A884D38" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLossAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_DABD46C14FD17896379308C41A889837" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_86FA10008FC2C60B517C08C41A88516F" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_DABD46C14FD17896379308C41A889837" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest" xlink:label="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest_9B96545858439CAC579B08C41A88B990" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_86FA10008FC2C60B517C08C41A88516F" xlink:to="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToNoncontrollingInterest_9B96545858439CAC579B08C41A88B990" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_B06FCF88A19A2433DBF908C418139D01" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_C6D7CDA0B7BCC700AAEB08C41809C996" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_B06FCF88A19A2433DBF908C418139D01" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_C6D7CDA0B7BCC700AAEB08C41809C996" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_9C475CC9E65E3BD1ACC908C4180968C9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_C6D7CDA0B7BCC700AAEB08C41809C996" xlink:to="loc_us-gaap_StatementClassOfStockAxis_9C475CC9E65E3BD1ACC908C4180968C9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_EE59B8452DF433793EE708C418096E68_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_9C475CC9E65E3BD1ACC908C4180968C9" xlink:to="loc_us-gaap_ClassOfStockDomain_EE59B8452DF433793EE708C418096E68_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_EE59B8452DF433793EE708C418096E68" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_9C475CC9E65E3BD1ACC908C4180968C9" xlink:to="loc_us-gaap_ClassOfStockDomain_EE59B8452DF433793EE708C418096E68" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_173B810F90932A48830808C418096E39" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_EE59B8452DF433793EE708C418096E68" xlink:to="loc_hsy_HersheyCommonStockMember_173B810F90932A48830808C418096E39" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyTrustCompanyMember" xlink:label="loc_hsy_HersheyTrustCompanyMember_30AF5CF3B9D28D865C8E08C418090703" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_EE59B8452DF433793EE708C418096E68" xlink:to="loc_hsy_HersheyTrustCompanyMember_30AF5CF3B9D28D865C8E08C418090703" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_9EB9999305EDBAE464A408C4180936AE" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_C6D7CDA0B7BCC700AAEB08C41809C996" xlink:to="loc_us-gaap_AwardTypeAxis_9EB9999305EDBAE464A408C4180936AE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_D6F2EC7468E20543E91F08C41813C8C8_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_9EB9999305EDBAE464A408C4180936AE" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_D6F2EC7468E20543E91F08C41813C8C8_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_D6F2EC7468E20543E91F08C41813C8C8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_9EB9999305EDBAE464A408C4180936AE" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_D6F2EC7468E20543E91F08C41813C8C8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_72120B5CBE7CF314662F08C41813E9F5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_D6F2EC7468E20543E91F08C41813C8C8" xlink:to="loc_us-gaap_EmployeeStockOptionMember_72120B5CBE7CF314662F08C41813E9F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockSharesIssued" xlink:label="loc_us-gaap_CommonStockSharesIssued_33B161602A0523D127CF08C41813F883" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B06FCF88A19A2433DBF908C418139D01" xlink:to="loc_us-gaap_CommonStockSharesIssued_33B161602A0523D127CF08C41813F883" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockShares" xlink:label="loc_us-gaap_TreasuryStockShares_7D42D2BEC3D23C0FAD8D08C41813DAF5" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B06FCF88A19A2433DBF908C418139D01" xlink:to="loc_us-gaap_TreasuryStockShares_7D42D2BEC3D23C0FAD8D08C41813DAF5" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_TreasuryStockSharesRollForward" xlink:label="loc_hsy_TreasuryStockSharesRollForward_5C59CD52D3FF19DA761B08C4181381FF" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B06FCF88A19A2433DBF908C418139D01" xlink:to="loc_hsy_TreasuryStockSharesRollForward_5C59CD52D3FF19DA761B08C4181381FF" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShareRepurchaseProgramAbstract" xlink:label="loc_hsy_ShareRepurchaseProgramAbstract_4D496B712872AA57A4BA08C41813F549" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_5C59CD52D3FF19DA761B08C4181381FF" xlink:to="loc_hsy_ShareRepurchaseProgramAbstract_4D496B712872AA57A4BA08C41813F549" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TreasuryStockSharesAcquired" xlink:label="loc_us-gaap_TreasuryStockSharesAcquired_17A05329DFF04BA2F00E08C41813F275" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_ShareRepurchaseProgramAbstract_4D496B712872AA57A4BA08C41813F549" xlink:to="loc_us-gaap_TreasuryStockSharesAcquired_17A05329DFF04BA2F00E08C41813F275" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_D105E20FEEF350AC573208C41813530E" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_hsy_TreasuryStockSharesRollForward_5C59CD52D3FF19DA761B08C4181381FF" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_D105E20FEEF350AC573208C41813530E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross_C7D8574BFB6C4A69735308C418136210" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StockIssuedDuringPeriodSharebasedCompensationAbstract_D105E20FEEF350AC573208C41813530E" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharesShareBasedCompensationGross_C7D8574BFB6C4A69735308C418136210" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockSharesOutstanding" xlink:label="loc_us-gaap_CommonStockSharesOutstanding_48853C00A5499E465BA408C4181367B4" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_B06FCF88A19A2433DBF908C418139D01" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_48853C00A5499E465BA408C4181367B4" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeLineItems" xlink:label="loc_us-gaap_DerivativeLineItems_17FED48AA78AFD12932C08C41AEC17D7" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeTable" xlink:label="loc_us-gaap_DerivativeTable_504FD0F7390E1E8BFA1508C41AECB97B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeLineItems_17FED48AA78AFD12932C08C41AEC17D7" xlink:to="loc_us-gaap_DerivativeTable_504FD0F7390E1E8BFA1508C41AECB97B" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BBD065CC1832CEC9E1E008C41AECCD17" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_504FD0F7390E1E8BFA1508C41AECB97B" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BBD065CC1832CEC9E1E008C41AECCD17" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_8D29C5B45F7793F0D2A608C41AEC63AD_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BBD065CC1832CEC9E1E008C41AECCD17" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_8D29C5B45F7793F0D2A608C41AEC63AD_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_8D29C5B45F7793F0D2A608C41AEC63AD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_BBD065CC1832CEC9E1E008C41AECCD17" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_8D29C5B45F7793F0D2A608C41AEC63AD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_188BB7CC917BED90CBE008C41AEC9B83" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_8D29C5B45F7793F0D2A608C41AEC63AD" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_188BB7CC917BED90CBE008C41AEC9B83" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_F16CF50BE7646F91F6F208C41AEC27B0" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeTable_504FD0F7390E1E8BFA1508C41AECB97B" xlink:to="loc_us-gaap_RestructuringPlanAxis_F16CF50BE7646F91F6F208C41AEC27B0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_7519CF6AD1D76781B16008C41AEC77DF_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_F16CF50BE7646F91F6F208C41AEC27B0" xlink:to="loc_us-gaap_RestructuringPlanDomain_7519CF6AD1D76781B16008C41AEC77DF_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_7519CF6AD1D76781B16008C41AEC77DF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_F16CF50BE7646F91F6F208C41AEC27B0" xlink:to="loc_us-gaap_RestructuringPlanDomain_7519CF6AD1D76781B16008C41AEC77DF" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_EE5F3CDE7258F01772AF08C41AECAE30" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_7519CF6AD1D76781B16008C41AEC77DF" xlink:to="loc_hsy_MarginforGrowthProgramMember_EE5F3CDE7258F01772AF08C41AECAE30" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueNetAssetLiability" xlink:label="loc_us-gaap_FairValueNetAssetLiability_A64BA498E35BE4ED1B1A08C41AEC287D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_17FED48AA78AFD12932C08C41AEC17D7" xlink:to="loc_us-gaap_FairValueNetAssetLiability_A64BA498E35BE4ED1B1A08C41AEC287D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_164FAE69B7C264B4E16508C41AEC8A59" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_17FED48AA78AFD12932C08C41AEC17D7" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_164FAE69B7C264B4E16508C41AEC8A59" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ImpairmentOfLongLivedAssetsHeldForUse" xlink:label="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_41363613A70D47660BDD08C41AECBF09" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeLineItems_17FED48AA78AFD12932C08C41AEC17D7" xlink:to="loc_us-gaap_ImpairmentOfLongLivedAssetsHeldForUse_41363613A70D47660BDD08C41AECBF09" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems" xlink:label="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_7E3E6983235870E3ECC608C4170FA8B2" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByBalanceSheetGroupingTable" xlink:label="loc_us-gaap_FairValueByBalanceSheetGroupingTable_DB96E725E0502CE5E7F908C4170F9D32" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_7E3E6983235870E3ECC608C4170FA8B2" xlink:to="loc_us-gaap_FairValueByBalanceSheetGroupingTable_DB96E725E0502CE5E7F908C4170F9D32" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_46B52719E3E4940CB80208C4170F0DDE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_DB96E725E0502CE5E7F908C4170F9D32" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_46B52719E3E4940CB80208C4170F0DDE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_E888AD10C33451A80AB208C4170F3604_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_46B52719E3E4940CB80208C4170F0DDE" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_E888AD10C33451A80AB208C4170F3604_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_E888AD10C33451A80AB208C4170F3604" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_46B52719E3E4940CB80208C4170F0DDE" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_E888AD10C33451A80AB208C4170F3604" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_D32998D003D24829485D08C4170F72CD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_E888AD10C33451A80AB208C4170F3604" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_D32998D003D24829485D08C4170F72CD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_364F6909353C28772D6908C4170FCBBE" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_DB96E725E0502CE5E7F908C4170F9D32" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_364F6909353C28772D6908C4170FCBBE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_364F6909353C28772D6908C4170FCBBE" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_364F6909353C28772D6908C4170FCBBE" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ForeignExchangeContractMember" xlink:label="loc_us-gaap_ForeignExchangeContractMember_A5DA2EF158A14164DD1708C4170FA20D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04" xlink:to="loc_us-gaap_ForeignExchangeContractMember_A5DA2EF158A14164DD1708C4170FA20D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestRateContractMember" xlink:label="loc_us-gaap_InterestRateContractMember_D2079E6E4490503AAEC108C4170F2674" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04" xlink:to="loc_us-gaap_InterestRateContractMember_D2079E6E4490503AAEC108C4170F2674" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquitySwapMember" xlink:label="loc_us-gaap_EquitySwapMember_5778586F6387DF7E001D08C4170FE7B2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04" xlink:to="loc_us-gaap_EquitySwapMember_5778586F6387DF7E001D08C4170FE7B2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_9E1D7B63D54D5FC2BD6008C4170FF095" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_80597C0EAE6B355FE1A508C4170F1D04" xlink:to="loc_us-gaap_CommodityContractMember_9E1D7B63D54D5FC2BD6008C4170FF095" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_0311BC2E2E12B92FA52708C4170F4BAB" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_DB96E725E0502CE5E7F908C4170F9D32" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_0311BC2E2E12B92FA52708C4170F4BAB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_0311BC2E2E12B92FA52708C4170F4BAB" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_0311BC2E2E12B92FA52708C4170F4BAB" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel1Member" xlink:label="loc_us-gaap_FairValueInputsLevel1Member_FFB041AE292ADFB3A7B008C4170F6C37" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_FFB041AE292ADFB3A7B008C4170F6C37" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_9F791DAAF99FE2CD885408C4170F6B93" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_9F791DAAF99FE2CD885408C4170F6B93" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_FFF917518B2DAB13F9B808C4170F5D62" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_94C4AED65CBB578E908308C4170FEA0E" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_FFF917518B2DAB13F9B808C4170F5D62" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeAssets" xlink:label="loc_us-gaap_DerivativeAssets_679BA760069E9776248308C4170F92F2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_7E3E6983235870E3ECC608C4170FA8B2" xlink:to="loc_us-gaap_DerivativeAssets_679BA760069E9776248308C4170F92F2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeLiabilities" xlink:label="loc_us-gaap_DerivativeLiabilities_CC9A6EF6D5AC9D05982B08C4170FC754" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_7E3E6983235870E3ECC608C4170FA8B2" xlink:to="loc_us-gaap_DerivativeLiabilities_CC9A6EF6D5AC9D05982B08C4170FC754" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable" xlink:label="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_53AEC87E05EEA20616FF08C41A743A85" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_53AEC87E05EEA20616FF08C41A743A85" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_2ED15C5D033DCE66126508C41A74F33F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_53AEC87E05EEA20616FF08C41A743A85" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_2ED15C5D033DCE66126508C41A74F33F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EEABFB5DB5B94A6A7C7208C41A74545D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_2ED15C5D033DCE66126508C41A74F33F" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EEABFB5DB5B94A6A7C7208C41A74545D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EEABFB5DB5B94A6A7C7208C41A74545D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_2ED15C5D033DCE66126508C41A74F33F" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EEABFB5DB5B94A6A7C7208C41A74545D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_BD9C85075881F5A1707B08C41A743AB7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_EEABFB5DB5B94A6A7C7208C41A74545D" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_BD9C85075881F5A1707B08C41A743AB7" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_LongtermDebtCurrentMaturitiesFairValue" xlink:label="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_EEEE47C5873E97D34EF608C41A740C2A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_hsy_LongtermDebtCurrentMaturitiesFairValue_EEEE47C5873E97D34EF608C41A740C2A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_FEE5ED966918B2208D2B08C41A74FA32" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_us-gaap_LongTermDebtCurrent_FEE5ED966918B2208D2B08C41A74FA32" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_LongtermDebtExcludingCurrentMaturitiesFairValue" xlink:label="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_F6B4484C0FC7ADC64F9508C41A748959" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_hsy_LongtermDebtExcludingCurrentMaturitiesFairValue_F6B4484C0FC7ADC64F9508C41A748959" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtNoncurrent" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_139F15D5E63D8148854D08C41A74FCCD" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_139F15D5E63D8148854D08C41A74FCCD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtFairValue" xlink:label="loc_us-gaap_LongTermDebtFairValue_F7173228ED9621FF7CE308C41A7446C5" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_us-gaap_LongTermDebtFairValue_F7173228ED9621FF7CE308C41A7446C5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_15A72342473257652BCB08C41A74B96C" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_FB44DA9957B8F3094EA808C41A74D657" xlink:to="loc_us-gaap_LongTermDebt_15A72342473257652BCB08C41A74B96C" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssets" xlink:type="extended"/>
<link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsGoodwillAndIntangibleAssetsNarrativeDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillLineItems" xlink:label="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfGoodwillTable" xlink:label="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanAxis" xlink:label="loc_us-gaap_RestructuringPlanAxis_5071B063CA504E7996FF08C417A577FC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_RestructuringPlanAxis_5071B063CA504E7996FF08C417A577FC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_A9D7A0A2825E77C1DFCB08C417A5CBF5_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RestructuringPlanAxis_5071B063CA504E7996FF08C417A577FC" xlink:to="loc_us-gaap_RestructuringPlanDomain_A9D7A0A2825E77C1DFCB08C417A5CBF5_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringPlanDomain" xlink:label="loc_us-gaap_RestructuringPlanDomain_A9D7A0A2825E77C1DFCB08C417A5CBF5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RestructuringPlanAxis_5071B063CA504E7996FF08C417A577FC" xlink:to="loc_us-gaap_RestructuringPlanDomain_A9D7A0A2825E77C1DFCB08C417A5CBF5" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_MarginforGrowthProgramMember" xlink:label="loc_hsy_MarginforGrowthProgramMember_916D33554D767457655108C417A58166" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RestructuringPlanDomain_A9D7A0A2825E77C1DFCB08C417A5CBF5" xlink:to="loc_hsy_MarginforGrowthProgramMember_916D33554D767457655108C417A58166" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityAxis" xlink:label="loc_us-gaap_CreditFacilityAxis_294F115EB3350CD7E40608C417A5D865" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_CreditFacilityAxis_294F115EB3350CD7E40608C417A5D865" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_1E336212024CE794747F08C417A5AB26_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_294F115EB3350CD7E40608C417A5D865" xlink:to="loc_us-gaap_CreditFacilityDomain_1E336212024CE794747F08C417A5AB26_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_1E336212024CE794747F08C417A5AB26" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_294F115EB3350CD7E40608C417A5D865" xlink:to="loc_us-gaap_CreditFacilityDomain_1E336212024CE794747F08C417A5AB26" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_587908300A9F6BE1BF0A08C417AF1B0C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_587908300A9F6BE1BF0A08C417AF1B0C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_A8119850B62DF4FD4A0508C417AF8BF4_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_587908300A9F6BE1BF0A08C417AF1B0C" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_A8119850B62DF4FD4A0508C417AF8BF4_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_A8119850B62DF4FD4A0508C417AF8BF4" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_587908300A9F6BE1BF0A08C417AF1B0C" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_A8119850B62DF4FD4A0508C417AF8BF4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_6671FD2E646C06939FEB08C417AF6A66" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_6671FD2E646C06939FEB08C417AF6A66" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_63C6F45FE84D696C1BFD08C417AF06B2_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_6671FD2E646C06939FEB08C417AF6A66" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_63C6F45FE84D696C1BFD08C417AF06B2_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_63C6F45FE84D696C1BFD08C417AF06B2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_6671FD2E646C06939FEB08C417AF6A66" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_63C6F45FE84D696C1BFD08C417AF06B2" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member" xlink:label="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_C116AB81649EF4D3104708C417AFFB05" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_63C6F45FE84D696C1BFD08C417AF06B2" xlink:to="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_C116AB81649EF4D3104708C417AFFB05" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsAxis" xlink:label="loc_us-gaap_ConsolidationItemsAxis_C337E24C27621E45903E08C417AFA469" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_ConsolidationItemsAxis_C337E24C27621E45903E08C417AFA469" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_3826009C7C7B11C1B8F508C417AF1237_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConsolidationItemsAxis_C337E24C27621E45903E08C417AFA469" xlink:to="loc_us-gaap_ConsolidationItemsDomain_3826009C7C7B11C1B8F508C417AF1237_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_3826009C7C7B11C1B8F508C417AF1237" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConsolidationItemsAxis_C337E24C27621E45903E08C417AFA469" xlink:to="loc_us-gaap_ConsolidationItemsDomain_3826009C7C7B11C1B8F508C417AF1237" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_62580BCEB0491EB2471208C417AF21BB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_3826009C7C7B11C1B8F508C417AF1237" xlink:to="loc_us-gaap_OperatingSegmentsMember_62580BCEB0491EB2471208C417AF21BB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_D954FDFC81A3BD28B9B308C417AF18FA" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_D954FDFC81A3BD28B9B308C417AF18FA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_B18E7488E97D2F2E298108C417AF9EC0_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_D954FDFC81A3BD28B9B308C417AF18FA" xlink:to="loc_us-gaap_SegmentDomain_B18E7488E97D2F2E298108C417AF9EC0_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_B18E7488E97D2F2E298108C417AF9EC0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_D954FDFC81A3BD28B9B308C417AF18FA" xlink:to="loc_us-gaap_SegmentDomain_B18E7488E97D2F2E298108C417AF9EC0" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_4217ECEAD34A2AAF14BE08C417AFDDB5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_B18E7488E97D2F2E298108C417AF9EC0" xlink:to="loc_hsy_InternationalandOtherSegmentMember_4217ECEAD34A2AAF14BE08C417AFDDB5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementGeographicalAxis" xlink:label="loc_us-gaap_StatementGeographicalAxis_C9F4ED443B068684014708C417AFFEFD" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_37353CA486746468D7B808C417A59204" xlink:to="loc_us-gaap_StatementGeographicalAxis_C9F4ED443B068684014708C417AFFEFD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentGeographicalDomain" xlink:label="loc_us-gaap_SegmentGeographicalDomain_62FA0066CB8D05C2747608C417AF698C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementGeographicalAxis_C9F4ED443B068684014708C417AFFEFD" xlink:to="loc_us-gaap_SegmentGeographicalDomain_62FA0066CB8D05C2747608C417AF698C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentGeographicalDomain" xlink:label="loc_us-gaap_SegmentGeographicalDomain_62FA0066CB8D05C2747608C417AF698C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementGeographicalAxis_C9F4ED443B068684014708C417AFFEFD" xlink:to="loc_us-gaap_SegmentGeographicalDomain_62FA0066CB8D05C2747608C417AF698C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.sec.gov/country/2017/country-2017-01-31.xsd#country_CN" xlink:label="loc_country_CN_0EE9BDED45D156A5354A08C417AF5366" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentGeographicalDomain_62FA0066CB8D05C2747608C417AF698C" xlink:to="loc_country_CN_0EE9BDED45D156A5354A08C417AF5366" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillImpairmentLoss" xlink:label="loc_us-gaap_GoodwillImpairmentLoss_A55F5ACC76F42734780008C417AF3B33" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_GoodwillImpairmentLoss_A55F5ACC76F42734780008C417AF3B33" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillPurchaseAccountingAdjustments" xlink:label="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_DE937EA7F67D96EEBD0A08C417AFC853" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_GoodwillPurchaseAccountingAdjustments_DE937EA7F67D96EEBD0A08C417AFC853" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsIndefinitelivedExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsIndefinitelivedExcludingGoodwill_2A49CFAB0B6BE3736DA408C417AFE00F" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsIndefinitelivedExcludingGoodwill_2A49CFAB0B6BE3736DA408C417AFE00F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_3B4A06B79937D7B554FD08C417AFBA17" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_Goodwill_3B4A06B79937D7B554FD08C417AFBA17" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_4EE30A7B301692C7D50F08C417AFB66A" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_ImpairmentOfIntangibleAssetsExcludingGoodwill_4EE30A7B301692C7D50F08C417AFB66A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AmortizationOfIntangibleAssets" xlink:label="loc_us-gaap_AmortizationOfIntangibleAssets_4F2CF7CAD87334E6890B08C417AFB8E0" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_D707066960FE383FE61908C417AF11E7" xlink:to="loc_us-gaap_AmortizationOfIntangibleAssets_4F2CF7CAD87334E6890B08C417AFB8E0" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfAmortizationExpenseForNextFiveYearsDetails" xlink:type="extended"/>
<link:definitionLink xlink:role="http://www.hersheys.com/role/GoodwillAndIntangibleAssetsScheduleOfChangesInCarryingValueOfGoodwillByReportableSegmentDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillLineItems" xlink:label="loc_us-gaap_GoodwillLineItems_EA0E186FFBD6E91B0AE308C417411E51" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfGoodwillTable" xlink:label="loc_us-gaap_ScheduleOfGoodwillTable_9112B420B141F7582B1F08C41741A735" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_GoodwillLineItems_EA0E186FFBD6E91B0AE308C417411E51" xlink:to="loc_us-gaap_ScheduleOfGoodwillTable_9112B420B141F7582B1F08C41741A735" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsAxis" xlink:label="loc_us-gaap_ConsolidationItemsAxis_249943410561AD646E6708C417410B55" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_9112B420B141F7582B1F08C41741A735" xlink:to="loc_us-gaap_ConsolidationItemsAxis_249943410561AD646E6708C417410B55" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_973BC912244F9A528D7108C41741EDEA_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConsolidationItemsAxis_249943410561AD646E6708C417410B55" xlink:to="loc_us-gaap_ConsolidationItemsDomain_973BC912244F9A528D7108C41741EDEA_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_973BC912244F9A528D7108C41741EDEA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConsolidationItemsAxis_249943410561AD646E6708C417410B55" xlink:to="loc_us-gaap_ConsolidationItemsDomain_973BC912244F9A528D7108C41741EDEA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_7BBA97FA7D3C54C41F0A08C417415FD9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_973BC912244F9A528D7108C41741EDEA" xlink:to="loc_us-gaap_OperatingSegmentsMember_7BBA97FA7D3C54C41F0A08C417415FD9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_ADFEDB5877597DF975DB08C417412503" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfGoodwillTable_9112B420B141F7582B1F08C41741A735" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_ADFEDB5877597DF975DB08C417412503" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_8E8D077388CBE0F92A7008C41741451F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_ADFEDB5877597DF975DB08C417412503" xlink:to="loc_us-gaap_SegmentDomain_8E8D077388CBE0F92A7008C41741451F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_8E8D077388CBE0F92A7008C41741451F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_ADFEDB5877597DF975DB08C417412503" xlink:to="loc_us-gaap_SegmentDomain_8E8D077388CBE0F92A7008C41741451F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_18214E4CA09F6972FEF508C4174101A7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_8E8D077388CBE0F92A7008C41741451F" xlink:to="loc_hsy_NorthAmericaSegmentMember_18214E4CA09F6972FEF508C4174101A7" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_2870AFF9F8561F2CD43508C41741EC46" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_8E8D077388CBE0F92A7008C41741451F" xlink:to="loc_hsy_InternationalandOtherSegmentMember_2870AFF9F8561F2CD43508C41741EC46" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillGross" xlink:label="loc_us-gaap_GoodwillGross_1398D735C3F9BF8EDFE708C4174177D1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_EA0E186FFBD6E91B0AE308C417411E51" xlink:to="loc_us-gaap_GoodwillGross_1398D735C3F9BF8EDFE708C4174177D1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillImpairedAccumulatedImpairmentLoss" xlink:label="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_20199BD211AD9770DF4508C4174130B2" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_EA0E186FFBD6E91B0AE308C417411E51" xlink:to="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_20199BD211AD9770DF4508C4174130B2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillRollForward" xlink:label="loc_us-gaap_GoodwillRollForward_E831A99C5A7B0B4FF80E08C41741EBE5" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillLineItems_EA0E186FFBD6E91B0AE308C417411E51" xlink:to="loc_us-gaap_GoodwillRollForward_E831A99C5A7B0B4FF80E08C41741EBE5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Goodwill" xlink:label="loc_us-gaap_Goodwill_AA303801D5861918695A08C417411DC3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_E831A99C5A7B0B4FF80E08C41741EBE5" xlink:to="loc_us-gaap_Goodwill_AA303801D5861918695A08C417411DC3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillAcquiredDuringPeriod" xlink:label="loc_us-gaap_GoodwillAcquiredDuringPeriod_AC850BB6411D382DB99208C4174BE48C" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_E831A99C5A7B0B4FF80E08C41741EBE5" xlink:to="loc_us-gaap_GoodwillAcquiredDuringPeriod_AC850BB6411D382DB99208C4174BE48C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillForeignCurrencyTranslationGainLoss" xlink:label="loc_us-gaap_GoodwillForeignCurrencyTranslationGainLoss_792D0CFCE6D4A582EA7108C4174B2E5C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_GoodwillRollForward_E831A99C5A7B0B4FF80E08C41741EBE5" xlink:to="loc_us-gaap_GoodwillForeignCurrencyTranslationGainLoss_792D0CFCE6D4A582EA7108C4174B2E5C" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_BD255ECBCE0257AD329A08C41970CB62" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_CDECC406A1188058111D08C419708128" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_BD255ECBCE0257AD329A08C41970CB62" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_CDECC406A1188058111D08C419708128" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3C6F0C8E0005F05BDA0308C41970F719" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_CDECC406A1188058111D08C419708128" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3C6F0C8E0005F05BDA0308C41970F719" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3C6F0C8E0005F05BDA0308C41970F719" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_3C6F0C8E0005F05BDA0308C41970F719" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_2E7F0224CF402FA6226108C419703163" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384" xlink:to="loc_us-gaap_TrademarksMember_2E7F0224CF402FA6226108C419703163" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CustomerRelatedIntangibleAssetsMember" xlink:label="loc_us-gaap_CustomerRelatedIntangibleAssetsMember_C98D784891469B21403008C41970D4E0" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384" xlink:to="loc_us-gaap_CustomerRelatedIntangibleAssetsMember_C98D784891469B21403008C41970D4E0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PatentsMember" xlink:label="loc_us-gaap_PatentsMember_4B76562DC4496B9A444E08C41970EB4F" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_1DA56A7A4654E81D70A308C419704384" xlink:to="loc_us-gaap_PatentsMember_4B76562DC4496B9A444E08C41970EB4F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_AF985F676682E8212DC808C4197011D2" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_CDECC406A1188058111D08C419708128" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_AF985F676682E8212DC808C4197011D2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_FE042E12D8FAB8801F5C08C41970758C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_AF985F676682E8212DC808C4197011D2" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_FE042E12D8FAB8801F5C08C41970758C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_FE042E12D8FAB8801F5C08C41970758C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsByMajorClassAxis_AF985F676682E8212DC808C4197011D2" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_FE042E12D8FAB8801F5C08C41970758C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_BB2B12A2E8092CCB6E0F08C41970EFC0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IndefiniteLivedIntangibleAssetsMajorClassNameDomain_FE042E12D8FAB8801F5C08C41970758C" xlink:to="loc_us-gaap_TrademarksMember_BB2B12A2E8092CCB6E0F08C41970EFC0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsGross" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsGross_8BADC9A8F68E8F52451B08C41970AFBA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_BD255ECBCE0257AD329A08C41970CB62" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsGross_8BADC9A8F68E8F52451B08C41970AFBA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_600478B913656B48FC5208C41970FBAB" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_BD255ECBCE0257AD329A08C41970CB62" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_600478B913656B48FC5208C41970FBAB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill" xlink:label="loc_us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill_870DE2C316954FF90E3208C41970E1F1" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_BD255ECBCE0257AD329A08C41970CB62" xlink:to="loc_us-gaap_IndefiniteLivedIntangibleAssetsExcludingGoodwill_870DE2C316954FF90E3208C41970E1F1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IntangibleAssetsNetExcludingGoodwill" xlink:label="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_45FA8042AF23367658CA08C4197074D0" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_BD255ECBCE0257AD329A08C41970CB62" xlink:to="loc_us-gaap_IntangibleAssetsNetExcludingGoodwill_45FA8042AF23367658CA08C4197074D0" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxContingencyLineItems" xlink:label="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxContingencyTable" xlink:label="loc_us-gaap_IncomeTaxContingencyTable_15314D80F29760FAEF354ACAB214DFCE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_IncomeTaxContingencyTable_15314D80F29760FAEF354ACAB214DFCE" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_6A9C7A9C21A477F071204ACAB214E481" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_15314D80F29760FAEF354ACAB214DFCE" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_6A9C7A9C21A477F071204ACAB214E481" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_A4A664B15C570A62FDA84ACAB214362F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_6A9C7A9C21A477F071204ACAB214E481" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_A4A664B15C570A62FDA84ACAB214362F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_A4A664B15C570A62FDA84ACAB214362F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_6A9C7A9C21A477F071204ACAB214E481" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_A4A664B15C570A62FDA84ACAB214362F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpenseMember" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_EA20F6C871BA71624F3F4ACAB2140F84" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_A4A664B15C570A62FDA84ACAB214362F" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpenseMember_EA20F6C871BA71624F3F4ACAB2140F84" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis" xlink:label="loc_us-gaap_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_BFCE7C30CEE7EC6EBFC74ACAB214925E" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_15314D80F29760FAEF354ACAB214DFCE" xlink:to="loc_us-gaap_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_BFCE7C30CEE7EC6EBFC74ACAB214925E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityMethodInvesteeNameDomain" xlink:label="loc_us-gaap_EquityMethodInvesteeNameDomain_BDC8DB2949A42D858E0C4ACAB2146443_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_BFCE7C30CEE7EC6EBFC74ACAB214925E" xlink:to="loc_us-gaap_EquityMethodInvesteeNameDomain_BDC8DB2949A42D858E0C4ACAB2146443_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityMethodInvesteeNameDomain" xlink:label="loc_us-gaap_EquityMethodInvesteeNameDomain_BDC8DB2949A42D858E0C4ACAB2146443" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis_BFCE7C30CEE7EC6EBFC74ACAB214925E" xlink:to="loc_us-gaap_EquityMethodInvesteeNameDomain_BDC8DB2949A42D858E0C4ACAB2146443" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PartnershipsQualifyingForTaxCreditsMember" xlink:label="loc_hsy_PartnershipsQualifyingForTaxCreditsMember_721D49AAE4D74FD84B564ACAB21495A6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityMethodInvesteeNameDomain_BDC8DB2949A42D858E0C4ACAB2146443" xlink:to="loc_hsy_PartnershipsQualifyingForTaxCreditsMember_721D49AAE4D74FD84B564ACAB21495A6" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit" xlink:label="loc_hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit_0CC0E78F496AD958C1214ACAB214D6B1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_hsy_TaxCutsandJobsActof2017NetImpactChangeinTaxRateandMandatoryTaxonUnremittedForeignEarningsIncomeTaxExpenseBenefit_0CC0E78F496AD958C1214ACAB214D6B1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate_25E90B4F250B7FB08DF64ACAB21468E8" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsThatWouldImpactEffectiveTaxRate_25E90B4F250B7FB08DF64ACAB21468E8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense_B0C729F6E1BAD656D0494ACAB214DF06" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestExpense_B0C729F6E1BAD656D0494ACAB214DF06" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_B36F55319F86EB6336DE4ACAB2149A42" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_B36F55319F86EB6336DE4ACAB2149A42" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit" xlink:label="loc_us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit_05C04DFFAC5E41024BD54ACAB214F5B7" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_SignificantChangeInUnrecognizedTaxBenefitsIsReasonablyPossibleAmountOfUnrecordedBenefit_05C04DFFAC5E41024BD54ACAB214F5B7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UndistributedEarningsOfForeignSubsidiaries" xlink:label="loc_us-gaap_UndistributedEarningsOfForeignSubsidiaries_46136E5791E174B5314E4ACAB214836F" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_UndistributedEarningsOfForeignSubsidiaries_46136E5791E174B5314E4ACAB214836F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxCreditsAndAdjustments" xlink:label="loc_us-gaap_IncomeTaxCreditsAndAdjustments_B5E9CA50896EF3DF64E34ACAB214CDE6" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_IncomeTaxCreditsAndAdjustments_B5E9CA50896EF3DF64E34ACAB214CDE6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_B7BE15EEB420D211D6264ACAB2149DCD" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_AB66950C52DF547F82184ACAB2149CB3" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_B7BE15EEB420D211D6264ACAB2149DCD" 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/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems" xlink:label="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable" xlink:label="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_7B7023CD0CB943E0116E3B28C70602E1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_7B7023CD0CB943E0116E3B28C70602E1" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC4F59E19887773877F33B28C7062576" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_7B7023CD0CB943E0116E3B28C70602E1" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC4F59E19887773877F33B28C7062576" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_10733FD7F9840406846C3B28C706AA2C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC4F59E19887773877F33B28C7062576" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_10733FD7F9840406846C3B28C706AA2C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_10733FD7F9840406846C3B28C706AA2C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_DC4F59E19887773877F33B28C7062576" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_10733FD7F9840406846C3B28C706AA2C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_629E55B7FEEEA63DE8923B28C7067EB0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_10733FD7F9840406846C3B28C706AA2C" xlink:to="loc_us-gaap_TrademarksMember_629E55B7FEEEA63DE8923B28C7067EB0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_FD2424EF6FCBA44DF5183B28C706E124" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesTable_7B7023CD0CB943E0116E3B28C70602E1" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_FD2424EF6FCBA44DF5183B28C706E124" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_470113DB60914CCA59923B28C706A4F1_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_FD2424EF6FCBA44DF5183B28C706E124" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_470113DB60914CCA59923B28C706A4F1_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_470113DB60914CCA59923B28C706A4F1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_FD2424EF6FCBA44DF5183B28C706E124" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_470113DB60914CCA59923B28C706A4F1" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member" xlink:label="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_CEB3227EA3203374509A3B28C7067260" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_470113DB60914CCA59923B28C706A4F1" xlink:to="loc_hsy_ShanghaiGoldenMonkeyFoodJointStockCo.Ltd.Member_CEB3227EA3203374509A3B28C7067260" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_LotteShanghaiFoodCompanyMember" xlink:label="loc_hsy_LotteShanghaiFoodCompanyMember_BB851D0D22A4946F642D3B28C70667B6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_470113DB60914CCA59923B28C706A4F1" xlink:to="loc_hsy_LotteShanghaiFoodCompanyMember_BB851D0D22A4946F642D3B28C70667B6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment" xlink:label="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_33B857B0C289F1EB4F693B28C70630D0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_us-gaap_EquityMethodInvestmentOtherThanTemporaryImpairment_33B857B0C289F1EB4F693B28C70630D0" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DefinedBenefitPlanNonServiceCost" xlink:label="loc_hsy_DefinedBenefitPlanNonServiceCost_6A888C567F81862CA1993B28C868625E" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_hsy_DefinedBenefitPlanNonServiceCost_6A888C567F81862CA1993B28C868625E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount" xlink:label="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_A5E64F8B03CB52E9CD1F3B28C706BD00" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_us-gaap_BusinessCombinationBargainPurchaseGainRecognizedAmount_A5E64F8B03CB52E9CD1F3B28C706BD00" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GainLossOnDispositionOfIntangibleAssets" xlink:label="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_EB69FC4398B6A1DA8CB53B28C70630BC" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_EB69FC4398B6A1DA8CB53B28C70630BC" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_OtherNonoperatingGainLoss" xlink:label="loc_hsy_OtherNonoperatingGainLoss_266310CED2BD3A4E45E13B28C706E337" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_hsy_OtherNonoperatingGainLoss_266310CED2BD3A4E45E13B28C706E337" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_6BF9435EB78536A5F6043B28C7068858" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SummaryOfInvestmentsOtherThanInvestmentsInRelatedPartiesReportableDataLineItems_820725706F43484B64993B28C7065748" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_6BF9435EB78536A5F6043B28C7068858" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_07AE5E456F85FC1723B708C41831BB3D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:to="loc_us-gaap_RangeAxis_07AE5E456F85FC1723B708C41831BB3D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_B4D3FE2F313931A9B43208C41831480F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_07AE5E456F85FC1723B708C41831BB3D" xlink:to="loc_us-gaap_RangeMember_B4D3FE2F313931A9B43208C41831480F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_B4D3FE2F313931A9B43208C41831480F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_07AE5E456F85FC1723B708C41831BB3D" xlink:to="loc_us-gaap_RangeMember_B4D3FE2F313931A9B43208C41831480F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_783B8023452BF242FCA308C418311408" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_B4D3FE2F313931A9B43208C41831480F" xlink:to="loc_us-gaap_MinimumMember_783B8023452BF242FCA308C418311408" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_A3B95B041DBE584CDBF608C418312BB9" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_B4D3FE2F313931A9B43208C41831480F" xlink:to="loc_us-gaap_MaximumMember_A3B95B041DBE584CDBF608C418312BB9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_37EA968B90F7CE22C7DB08C41831493F" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_37EA968B90F7CE22C7DB08C41831493F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_37EA968B90F7CE22C7DB08C41831493F" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_37EA968B90F7CE22C7DB08C41831493F" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_C51D10963082DE55FFAF08C41831A1B9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_C51D10963082DE55FFAF08C41831A1B9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SupplementalEmployeeRetirementPlanDefinedBenefitMember" xlink:label="loc_us-gaap_SupplementalEmployeeRetirementPlanDefinedBenefitMember_61695BC8328D163D677508C418310006" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C" xlink:to="loc_us-gaap_SupplementalEmployeeRetirementPlanDefinedBenefitMember_61695BC8328D163D677508C418310006" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_9644D2B45039A4DBAC1808C418314872" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_4F7776FA45459563327D08C41831100C" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_9644D2B45039A4DBAC1808C418314872" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_BF2777885D51293E89AC08C41831BEF4" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:to="loc_us-gaap_StatementScenarioAxis_BF2777885D51293E89AC08C41831BEF4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_44C15651F257B050409B08C41831CFAC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_BF2777885D51293E89AC08C41831BEF4" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_44C15651F257B050409B08C41831CFAC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_44C15651F257B050409B08C41831CFAC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_BF2777885D51293E89AC08C41831BEF4" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_44C15651F257B050409B08C41831CFAC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProFormaMember" xlink:label="loc_us-gaap_ProFormaMember_C6195BD7D23ED2866A3608C4183192F8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_44C15651F257B050409B08C41831CFAC" xlink:to="loc_us-gaap_ProFormaMember_C6195BD7D23ED2866A3608C4183192F8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_0A8B6FC9A42EA32C026E08C41831B381" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_44C15651F257B050409B08C41831CFAC" xlink:to="loc_us-gaap_ScenarioForecastMember_0A8B6FC9A42EA32C026E08C41831B381" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanFundingStatusAxis" xlink:label="loc_us-gaap_RetirementPlanFundingStatusAxis_6D34EA9EAAED0685878D08C418319F89" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:to="loc_us-gaap_RetirementPlanFundingStatusAxis_6D34EA9EAAED0685878D08C418319F89" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanFundingStatusDomain" xlink:label="loc_us-gaap_RetirementPlanFundingStatusDomain_89F3E2CAC1D3B171BD0C08C418317ED7_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanFundingStatusAxis_6D34EA9EAAED0685878D08C418319F89" xlink:to="loc_us-gaap_RetirementPlanFundingStatusDomain_89F3E2CAC1D3B171BD0C08C418317ED7_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanFundingStatusDomain" xlink:label="loc_us-gaap_RetirementPlanFundingStatusDomain_89F3E2CAC1D3B171BD0C08C418317ED7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanFundingStatusAxis_6D34EA9EAAED0685878D08C418319F89" xlink:to="loc_us-gaap_RetirementPlanFundingStatusDomain_89F3E2CAC1D3B171BD0C08C418317ED7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnfundedPlanMember" xlink:label="loc_us-gaap_UnfundedPlanMember_95C3C6373837078227F208C41831C06B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanFundingStatusDomain_89F3E2CAC1D3B171BD0C08C418317ED7" xlink:to="loc_us-gaap_UnfundedPlanMember_95C3C6373837078227F208C41831C06B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanNameAxis" xlink:label="loc_us-gaap_RetirementPlanNameAxis_1CF5F38F3DB414ADE03308C41831B1DB" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_D8D288B245B916C2BC6F08C41831F841" xlink:to="loc_us-gaap_RetirementPlanNameAxis_1CF5F38F3DB414ADE03308C41831B1DB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanNameDomain" xlink:label="loc_us-gaap_RetirementPlanNameDomain_60D9F6A091B412B530E308C418310E3D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanNameAxis_1CF5F38F3DB414ADE03308C41831B1DB" xlink:to="loc_us-gaap_RetirementPlanNameDomain_60D9F6A091B412B530E308C418310E3D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanNameDomain" xlink:label="loc_us-gaap_RetirementPlanNameDomain_60D9F6A091B412B530E308C418310E3D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanNameAxis_1CF5F38F3DB414ADE03308C41831B1DB" xlink:to="loc_us-gaap_RetirementPlanNameDomain_60D9F6A091B412B530E308C418310E3D" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCompanyPuertoRicoHourlyPensionPlanMember" xlink:label="loc_hsy_HersheyCompanyPuertoRicoHourlyPensionPlanMember_9F2AD6D4D3121EB7960308C41831B859" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanNameDomain_60D9F6A091B412B530E308C418310E3D" xlink:to="loc_hsy_HersheyCompanyPuertoRicoHourlyPensionPlanMember_9F2AD6D4D3121EB7960308C41831B859" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans" xlink:label="loc_hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans_6191659D02A73FA5318308C418319524" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_hsy_NumberofDefinedBenefitOtherPostretirementPlansandDefinedContributionOtherPostretirementPlans_6191659D02A73FA5318308C418319524" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation_32E48BA43F464833AF3908C418315E81" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedBenefitObligation_32E48BA43F464833AF3908C418315E81" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Definedbenefitplaneffectofchangeininterestmethodonserviceandinterestcostcomponents" xlink:label="loc_hsy_Definedbenefitplaneffectofchangeininterestmethodonserviceandinterestcostcomponents_6FD30B617907BABF5EFA08C41831D010" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_hsy_Definedbenefitplaneffectofchangeininterestmethodonserviceandinterestcostcomponents_6FD30B617907BABF5EFA08C41831D010" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear_1E787156D82F50EE8FB108C418318A41" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_us-gaap_DefinedBenefitPlanHealthCareCostTrendRateAssumedNextFiscalYear_1E787156D82F50EE8FB108C418318A41" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1" xlink:label="loc_us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1_F468AB30839768CC8E8308C41831696E" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_us-gaap_DefinedBenefitPlanUltimateHealthCareCostTrendRate1_F468AB30839768CC8E8308C41831696E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanContributionsByEmployer" xlink:label="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_C1609C2AB2BDC9C4C73F08C418313668" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_C1609C2AB2BDC9C4C73F08C418313668" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear" xlink:label="loc_hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear_C0465A05FDA1891338A008C418312863" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_hsy_DefinedBenefitPlansMinimumFutureEmployerContributionsinNextFiscalYear_C0465A05FDA1891338A008C418312863" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedContributionPlanCostRecognized" xlink:label="loc_us-gaap_DefinedContributionPlanCostRecognized_E948421D4FAB3D8210E008C41831C9D8" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_66F0DDB07D1CC057E01E08C418319B26" xlink:to="loc_us-gaap_DefinedContributionPlanCostRecognized_E948421D4FAB3D8210E008C41831C9D8" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E9B7F394701CD06E6AA408C4188BE875" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1496620D728BEB50F91F08C418816AD3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E9B7F394701CD06E6AA408C4188BE875" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1496620D728BEB50F91F08C418816AD3" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_3256C4AC59639B5FEBE208C4188B518B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1496620D728BEB50F91F08C418816AD3" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_3256C4AC59639B5FEBE208C4188B518B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_77FA933F6B0D3828358908C4188BDB24_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_3256C4AC59639B5FEBE208C4188B518B" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_77FA933F6B0D3828358908C4188BDB24_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_77FA933F6B0D3828358908C4188BDB24" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_3256C4AC59639B5FEBE208C4188B518B" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_77FA933F6B0D3828358908C4188BDB24" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_67F4550C202749D7EA2008C4188B4DCA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_77FA933F6B0D3828358908C4188BDB24" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_67F4550C202749D7EA2008C4188B4DCA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_41B51EB53EB2D725B22E08C4188BA94F" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_77FA933F6B0D3828358908C4188BDB24" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_41B51EB53EB2D725B22E08C4188BA94F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedAmortizationOfGainLossNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfGainLossNextFiscalYear_C88B7A1518719CB6F91A08C4188B4944" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E9B7F394701CD06E6AA408C4188BE875" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfGainLossNextFiscalYear_C88B7A1518719CB6F91A08C4188B4944" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedAmortizationOfPriorServiceCostCreditNextFiscalYear" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfPriorServiceCostCreditNextFiscalYear_AF25BD1AFF3D12733DC908C4188B6EAC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_E9B7F394701CD06E6AA408C4188BE875" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedAmortizationOfPriorServiceCostCreditNextFiscalYear_AF25BD1AFF3D12733DC908C4188B6EAC" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_93369C7D281A00B806AB08C41BB4DA0C" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_8BC451B822443796BF6A08C41BAA52E7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_93369C7D281A00B806AB08C41BB4DA0C" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_8BC451B822443796BF6A08C41BAA52E7" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_D7A63AE04B822A5769C108C41BAA2846" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_8BC451B822443796BF6A08C41BAA52E7" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_D7A63AE04B822A5769C108C41BAA2846" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_C06B762BD0CB42750BA508C41BAA2B2C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_D7A63AE04B822A5769C108C41BAA2846" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_C06B762BD0CB42750BA508C41BAA2B2C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_C06B762BD0CB42750BA508C41BAA2B2C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_D7A63AE04B822A5769C108C41BAA2846" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_C06B762BD0CB42750BA508C41BAA2B2C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_6B49394EBFC366FADD3C08C41BAA1369" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_C06B762BD0CB42750BA508C41BAA2B2C" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_6B49394EBFC366FADD3C08C41BAA1369" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_AD12E9058C07D65FFF3508C41BB4E150" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_C06B762BD0CB42750BA508C41BAA2B2C" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_AD12E9058C07D65FFF3508C41BB4E150" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_93369C7D281A00B806AB08C41BB4DA0C" xlink:to="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanServiceCost" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_50D6A1DD3E1B34F5223E08C41BB480E6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_50D6A1DD3E1B34F5223E08C41BB480E6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanInterestCost" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_C26EB950BEF5D1A1968208C41BB496C1" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_C26EB950BEF5D1A1968208C41BB496C1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_0EB6A0258B5F2D7CC90C08C41BB44D9E" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedReturnOnPlanAssets_0EB6A0258B5F2D7CC90C08C41BB44D9E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_F05984853450A828705B08C41BB4485C" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfPriorServiceCostCredit_F05984853450A828705B08C41BB4485C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses" xlink:label="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_AC8E29E6C1ABF59FB56508C41BB4806D" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanAmortizationOfGainsLosses_AC8E29E6C1ABF59FB56508C41BB4806D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments_7B9CDF76E3C2E236B12208C41BB43F37" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToCurtailments_7B9CDF76E3C2E236B12208C41BB43F37" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1" xlink:label="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_CCCF56651765BC30461908C41BB41B5F" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanRecognizedNetGainLossDueToSettlements1_CCCF56651765BC30461908C41BB41B5F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost" xlink:label="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_5E3B33AD511E432C745F08C41BB4E0A8" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCostAbstract_D90320B224A554C6BBB608C41BB4C12D" xlink:to="loc_us-gaap_DefinedBenefitPlanNetPeriodicBenefitCost_5E3B33AD511E432C745F08C41BB4E0A8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract" xlink:label="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_D01FC725018A7B07EEDE08C41BB42CAF" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_93369C7D281A00B806AB08C41BB4DA0C" xlink:to="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_D01FC725018A7B07EEDE08C41BB42CAF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax_CA766DCA1D184A6ADAB508C41BB45988" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_D01FC725018A7B07EEDE08C41BB42CAF" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeLossNetGainLossBeforeTax_CA766DCA1D184A6ADAB508C41BB45988" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax_9FF100307C72D3FC693308C41BB4FA40" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_D01FC725018A7B07EEDE08C41BB42CAF" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInOtherComprehensiveIncomeNetPriorServiceCostCreditBeforeTax_9FF100307C72D3FC693308C41BB4FA40" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax_604384620195448A584308C41BB442C2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentBeforeTaxPeriodIncreaseDecreaseAbstract_D01FC725018A7B07EEDE08C41BB42CAF" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossPensionAndOtherPostretirementBenefitPlansAdjustmentBeforeTax_604384620195448A584308C41BB442C2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax" xlink:label="loc_us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax_64816F790E23BD2A199908C41BB4E616" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_93369C7D281A00B806AB08C41BB4DA0C" xlink:to="loc_us-gaap_AmountRecognizedInNetPeriodicBenefitCostAndOtherComprehensiveIncomeLossBeforeTax_64816F790E23BD2A199908C41BB4E616" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_734FA2AE65D312CFF13608C4184F4086" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_734FA2AE65D312CFF13608C4184F4086" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_FA99A72A783DE7574E9708C4184F24B6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_734FA2AE65D312CFF13608C4184F4086" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_FA99A72A783DE7574E9708C4184F24B6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_B2B2CB8E5A6F9EC2901308C4184F14DF_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_FA99A72A783DE7574E9708C4184F24B6" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_B2B2CB8E5A6F9EC2901308C4184F14DF_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_B2B2CB8E5A6F9EC2901308C4184F14DF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_FA99A72A783DE7574E9708C4184F24B6" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_B2B2CB8E5A6F9EC2901308C4184F14DF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_92347B32662E3602EFD408C4184FF00E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_B2B2CB8E5A6F9EC2901308C4184F14DF" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_92347B32662E3602EFD408C4184FF00E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_AE072D889C1CAA65E03D08C4184FB76B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_B2B2CB8E5A6F9EC2901308C4184F14DF" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_AE072D889C1CAA65E03D08C4184FB76B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward" xlink:label="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:to="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanBenefitObligation_A46D99DA42F6724039B408C4184FDA1F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanBenefitObligation_A46D99DA42F6724039B408C4184FDA1F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanServiceCost" xlink:label="loc_us-gaap_DefinedBenefitPlanServiceCost_01D8D28F9B5788148E0708C4184F5C76" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanServiceCost_01D8D28F9B5788148E0708C4184F5C76" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanInterestCost" xlink:label="loc_us-gaap_DefinedBenefitPlanInterestCost_F90836D7608E7F62E6CC08C4184F030A" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanInterestCost_F90836D7608E7F62E6CC08C4184F030A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAmendments" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAmendments_CE23E04CA0BF4901BBA608C4184F929A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAmendments_CE23E04CA0BF4901BBA608C4184F929A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanActuarialGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_9B76C1228E1C9D98310808C4184FC197" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanActuarialGainLoss_9B76C1228E1C9D98310808C4184FC197" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanSettlementsBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanSettlementsBenefitObligation_82894C1B28C23354A1D708C4184F52D7" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanSettlementsBenefitObligation_82894C1B28C23354A1D708C4184F52D7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation" xlink:label="loc_us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation_E6A4410ECFAC7F50104C08C4184F0942" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanForeignCurrencyExchangeRateChangesBenefitObligation_E6A4410ECFAC7F50104C08C4184F0942" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid" xlink:label="loc_us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid_9DBB3CB8F82E1E15102308C4184F683A" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInBenefitObligationRollForward_A32EA4388070348529D008C4184F9702" xlink:to="loc_us-gaap_DefinedBenefitPlanBenefitObligationBenefitsPaid_9DBB3CB8F82E1E15102308C4184F683A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward" xlink:label="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:to="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanFairValueOfPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_6BC869592C49ECEEFDEF08C4184FE9AD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:to="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_6BC869592C49ECEEFDEF08C4184FE9AD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets_1D2588E5B9582AE6A4D108C4184F2493" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:to="loc_us-gaap_DefinedBenefitPlanActualReturnOnPlanAssets_1D2588E5B9582AE6A4D108C4184F2493" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanContributionsByEmployer" xlink:label="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_937FB53C235059ECDDAA08C4184F3D63" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:to="loc_us-gaap_DefinedBenefitPlanContributionsByEmployer_937FB53C235059ECDDAA08C4184F3D63" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanSettlementsPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanSettlementsPlanAssets_5138671B94406B4887F108C4184F6DA5" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:to="loc_us-gaap_DefinedBenefitPlanSettlementsPlanAssets_5138671B94406B4887F108C4184F6DA5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss_AA222A9E2CF7701F577108C4184F4833" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsForeignCurrencyTranslationGainLoss_AA222A9E2CF7701F577108C4184F4833" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid_935813CF26DA017535E708C4184FAC6C" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanChangeInFairValueOfPlanAssetsRollForward_E7045EC12350453D57F108C4184F0F1A" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsBenefitsPaid_935813CF26DA017535E708C4184FAC6C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanFundedStatusOfPlan" xlink:label="loc_us-gaap_DefinedBenefitPlanFundedStatusOfPlan_20C345870C21480E32E508C4184F72EF" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:to="loc_us-gaap_DefinedBenefitPlanFundedStatusOfPlan_20C345870C21480E32E508C4184F72EF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_E93544714B8B080A5FAA08C4184F19EE" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_E93544714B8B080A5FAA08C4184F19EE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent" xlink:label="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_115750E3B209D1839BD108C4184F38DC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_E93544714B8B080A5FAA08C4184F19EE" xlink:to="loc_us-gaap_DefinedBenefitPlanAssetsForPlanBenefitsNoncurrent_115750E3B209D1839BD108C4184F38DC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities" xlink:label="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities_C97B6327A30EE8065A3908C4184F8688" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_E93544714B8B080A5FAA08C4184F19EE" xlink:to="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansCurrentLiabilities_C97B6327A30EE8065A3908C4184F8688" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent" xlink:label="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent_C314C3932ABDB602293508C4184FA21C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_E93544714B8B080A5FAA08C4184F19EE" xlink:to="loc_us-gaap_PensionAndOtherPostretirementDefinedBenefitPlansLiabilitiesNoncurrent_C314C3932ABDB602293508C4184FA21C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet" xlink:label="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet_0527FB871B24401311A508C4184FC877" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheetAbstract_E93544714B8B080A5FAA08C4184F19EE" xlink:to="loc_us-gaap_DefinedBenefitPlanAmountsRecognizedInBalanceSheet_0527FB871B24401311A508C4184FC877" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B36302FE96A3B36D3BA608C4184FAE15" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_FEC7916323D4CC97EF7508C4184FA8BE" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B36302FE96A3B36D3BA608C4184FAE15" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax_DC3BD67B24E793250E2608C4184F7FC1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B36302FE96A3B36D3BA608C4184FAE15" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetGainsLossesAfterTax_DC3BD67B24E793250E2608C4184F7FC1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax" xlink:label="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax_68396FC29B96A344149408C4184F0407" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B36302FE96A3B36D3BA608C4184FAE15" xlink:to="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeNetPriorServiceCostCreditAfterTax_68396FC29B96A344149408C4184F0407" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_622AC89065CA089A773A08C4184F9E0E" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanAccumulatedOtherComprehensiveIncomeLossAfterTaxAbstract_B36302FE96A3B36D3BA608C4184FAE15" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossDefinedBenefitPensionAndOtherPostretirementPlansNetOfTax_622AC89065CA089A773A08C4184F9E0E" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FF107DBCB6529C84D4308C4189FCB67" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FF107DBCB6529C84D4308C4189FCB67" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_2051A61D058A14ADF28708C4189FB983" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_7FF107DBCB6529C84D4308C4189FCB67" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_2051A61D058A14ADF28708C4189FB983" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_EA29AFF32D594206F33008C418A9142E_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_2051A61D058A14ADF28708C4189FB983" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_EA29AFF32D594206F33008C418A9142E_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_EA29AFF32D594206F33008C418A9142E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_2051A61D058A14ADF28708C4189FB983" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_EA29AFF32D594206F33008C418A9142E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_9D6193D242D654B9F54208C418A9109A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_EA29AFF32D594206F33008C418A9142E" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_9D6193D242D654B9F54208C418A9109A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_DAA65D7563908BC44A3508C418A96EAF" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_EA29AFF32D594206F33008C418A9142E" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_DAA65D7563908BC44A3508C418A96EAF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths_21EAD8FF877148FCC27C08C418A90223" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsNextTwelveMonths_21EAD8FF877148FCC27C08C418A90223" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo_D66AF054327BEB21A3CC08C418A90957" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearTwo_D66AF054327BEB21A3CC08C418A90957" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree_E3231844C0336564BC5008C418A9FDD2" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearThree_E3231844C0336564BC5008C418A9FDD2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour_4983D72343EC8E82489108C418A9E101" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFour_4983D72343EC8E82489108C418A9E101" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive_F0AF8F0F2DBC38B08ADA08C418A9B32B" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsYearFive_F0AF8F0F2DBC38B08ADA08C418A9B32B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter" xlink:label="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter_676BF3AED6BB28C0AC2908C418A94052" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_612CB613C4F14D82023E08C418A90A6D" xlink:to="loc_us-gaap_DefinedBenefitPlanExpectedFutureBenefitPaymentsFiveFiscalYearsThereafter_676BF3AED6BB28C0AC2908C418A94052" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D470C00034336B853DDC08C41B0A8FFD" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1EA807A389E12DC400B208C41B0A39A6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D470C00034336B853DDC08C41B0A8FFD" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1EA807A389E12DC400B208C41B0A39A6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_23F55158091435BE3ACA08C41B0A39CB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1EA807A389E12DC400B208C41B0A39A6" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_23F55158091435BE3ACA08C41B0A39CB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_C73393FC6D7665DBBFCF08C41B0A1B4F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_23F55158091435BE3ACA08C41B0A39CB" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_C73393FC6D7665DBBFCF08C41B0A1B4F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_C73393FC6D7665DBBFCF08C41B0A1B4F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_23F55158091435BE3ACA08C41B0A39CB" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_C73393FC6D7665DBBFCF08C41B0A1B4F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_FA9425C7F8BCB1277A3908C41B0A2430" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_C73393FC6D7665DBBFCF08C41B0A1B4F" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_FA9425C7F8BCB1277A3908C41B0A2430" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_9D51586315AD65489C0208C41B0A4885" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1EA807A389E12DC400B208C41B0A39A6" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_9D51586315AD65489C0208C41B0A4885" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_AECF34C96C061F8BBFD108C41B0A757D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_9D51586315AD65489C0208C41B0A4885" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_AECF34C96C061F8BBFD108C41B0A757D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_AECF34C96C061F8BBFD108C41B0A757D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_9D51586315AD65489C0208C41B0A4885" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_AECF34C96C061F8BBFD108C41B0A757D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_8E169D783ACBEA9A1FF308C41B0AF396" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_AECF34C96C061F8BBFD108C41B0A757D" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_8E169D783ACBEA9A1FF308C41B0AF396" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis" xlink:label="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_F54B8ACD7FFED634F92C08C41B0AC757" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1EA807A389E12DC400B208C41B0A39A6" xlink:to="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_F54B8ACD7FFED634F92C08C41B0AC757" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_F54B8ACD7FFED634F92C08C41B0AC757" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_F54B8ACD7FFED634F92C08C41B0AC757" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashAndCashEquivalentsMember" xlink:label="loc_us-gaap_CashAndCashEquivalentsMember_CD1BF0044BFCBDB9813C08C41B0A9B8E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_us-gaap_CashAndCashEquivalentsMember_CD1BF0044BFCBDB9813C08C41B0A9B8E" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_GlobalAllCapMember" xlink:label="loc_hsy_GlobalAllCapMember_A8CB6E52EEA38E2642FB08C41B0AA9CD" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_hsy_GlobalAllCapMember_A8CB6E52EEA38E2642FB08C41B0AA9CD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_USTreasuryAndGovernmentMember" xlink:label="loc_us-gaap_USTreasuryAndGovernmentMember_971D511499859C016B5C08C41B0AF89D" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_us-gaap_USTreasuryAndGovernmentMember_971D511499859C016B5C08C41B0AF89D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CorporateBondSecuritiesMember" xlink:label="loc_us-gaap_CorporateBondSecuritiesMember_55681BDC0664C7826F7A08C41B0A404A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_us-gaap_CorporateBondSecuritiesMember_55681BDC0664C7826F7A08C41B0A404A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CollateralizedDebtObligationsMember" xlink:label="loc_us-gaap_CollateralizedDebtObligationsMember_93343AC9E5C47A98851508C41B0A7CFF" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_us-gaap_CollateralizedDebtObligationsMember_93343AC9E5C47A98851508C41B0A7CFF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ForeignGovernmentDebtSecuritiesMember" xlink:label="loc_us-gaap_ForeignGovernmentDebtSecuritiesMember_261D24F0C465CE0AA7BE08C41B0AB972" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_us-gaap_ForeignGovernmentDebtSecuritiesMember_261D24F0C465CE0AA7BE08C41B0AB972" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_GlobaldiversifiedassetsMember" xlink:label="loc_hsy_GlobaldiversifiedassetsMember_05C94D279174B25264F008C41B0A8E24" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_hsy_GlobaldiversifiedassetsMember_05C94D279174B25264F008C41B0A8E24" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_GlobalrealestateinvestmenttrustsMember" xlink:label="loc_hsy_GlobalrealestateinvestmenttrustsMember_D008600A507967F113BD08C41B0A5F59" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_hsy_GlobalrealestateinvestmenttrustsMember_D008600A507967F113BD08C41B0A5F59" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_GlobalinfrastructureMember" xlink:label="loc_hsy_GlobalinfrastructureMember_6DB5140E1D35AF6613D608C41B0A1CF3" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_2F0CE9ACF01A9B58784908C41B0A7DFD" xlink:to="loc_hsy_GlobalinfrastructureMember_6DB5140E1D35AF6613D608C41B0A1CF3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByFairValueHierarchyLevelAxis" xlink:label="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_58A6F366EEB36C5B10FE08C41B0A3223" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_1EA807A389E12DC400B208C41B0A39A6" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_58A6F366EEB36C5B10FE08C41B0A3223" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_58A6F366EEB36C5B10FE08C41B0A3223" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsFairValueHierarchyDomain" xlink:label="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_58A6F366EEB36C5B10FE08C41B0A3223" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel1Member" xlink:label="loc_us-gaap_FairValueInputsLevel1Member_42372949EDC145D415C408C41B0A23E2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_42372949EDC145D415C408C41B0A23E2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel2Member" xlink:label="loc_us-gaap_FairValueInputsLevel2Member_3D5F8F3D2CD69277F8D208C41B0A7F27" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_3D5F8F3D2CD69277F8D208C41B0A7F27" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueInputsLevel3Member" xlink:label="loc_us-gaap_FairValueInputsLevel3Member_6FBF957BE46BDBBC73E608C41B0A63F0" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_89F8C6C8BB697DB6B83808C41B0AE3E4" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_6FBF957BE46BDBBC73E608C41B0A63F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanFairValueOfPlanAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_8A8EDCE7062E3D81B85208C41B0AB0CF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D470C00034336B853DDC08C41B0A8FFD" xlink:to="loc_us-gaap_DefinedBenefitPlanFairValueOfPlanAssets_8A8EDCE7062E3D81B85208C41B0AB0CF" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue" xlink:label="loc_hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue_283CE802D78046325D7D08C41B0A9DA2" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_D470C00034336B853DDC08C41B0A8FFD" xlink:to="loc_hsy_DefinedBenefitPlanPlanAssetsMeasuredatNetAssetValue_283CE802D78046325D7D08C41B0A9DA2" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_014692A1FCC48961C74208C418F0D70F" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C79AA2520FE1B40DAA8F08C418F0F91A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_014692A1FCC48961C74208C418F0D70F" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C79AA2520FE1B40DAA8F08C418F0F91A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_69276E1127FCC9C6820808C418F09582" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C79AA2520FE1B40DAA8F08C418F0F91A" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_69276E1127FCC9C6820808C418F09582" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_21B3A3D1AD09C53462C208C418F070AB_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_69276E1127FCC9C6820808C418F09582" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_21B3A3D1AD09C53462C208C418F070AB_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_21B3A3D1AD09C53462C208C418F070AB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_69276E1127FCC9C6820808C418F09582" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_21B3A3D1AD09C53462C208C418F070AB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticPlanMember" xlink:label="loc_us-gaap_DomesticPlanMember_BC7FA03FD81FAA7D138A08C418F0BC85" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_21B3A3D1AD09C53462C208C418F070AB" xlink:to="loc_us-gaap_DomesticPlanMember_BC7FA03FD81FAA7D138A08C418F0BC85" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis" xlink:label="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_336AABC4BB23097B198A08C418F0EFE5" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_C79AA2520FE1B40DAA8F08C418F0F91A" xlink:to="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_336AABC4BB23097B198A08C418F0EFE5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_336AABC4BB23097B198A08C418F0EFE5" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PlanAssetCategoriesDomain" xlink:label="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DefinedBenefitPlanByPlanAssetCategoriesAxis_336AABC4BB23097B198A08C418F0EFE5" xlink:to="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashAndCashEquivalentsMember" xlink:label="loc_us-gaap_CashAndCashEquivalentsMember_BE8067AB785FEFADC00E08C418F026BA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A" xlink:to="loc_us-gaap_CashAndCashEquivalentsMember_BE8067AB785FEFADC00E08C418F026BA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquitySecuritiesMember" xlink:label="loc_us-gaap_EquitySecuritiesMember_2B1477E5CF9AEEDF820908C418F0F9B4" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A" xlink:to="loc_us-gaap_EquitySecuritiesMember_2B1477E5CF9AEEDF820908C418F0F9B4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtSecuritiesMember" xlink:label="loc_us-gaap_DebtSecuritiesMember_B6CDD3F529DD3A29470C08C418F05948" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A" xlink:to="loc_us-gaap_DebtSecuritiesMember_B6CDD3F529DD3A29470C08C418F05948" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherInvestmentsMember" xlink:label="loc_us-gaap_OtherInvestmentsMember_BADF13AEA74B10CFB99D08C418F0E0E9" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanAssetCategoriesDomain_C248B321412813A9D10808C418F06C8A" xlink:to="loc_us-gaap_OtherInvestmentsMember_BADF13AEA74B10CFB99D08C418F0E0E9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage" xlink:label="loc_us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage_90C2599B7BCD223F9EE008C418F0F72F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_014692A1FCC48961C74208C418F0D70F" xlink:to="loc_us-gaap_DefinedBenefitPlanPlanAssetsTargetAllocationPercentage_90C2599B7BCD223F9EE008C418F0F72F" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_99AD8A0D79372AE6D7FD08C417378CFF" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F41A81DB8F84A39C6A0B08C417370E41" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_99AD8A0D79372AE6D7FD08C417378CFF" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F41A81DB8F84A39C6A0B08C417370E41" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_32AD9C89C473207B81B908C417379DB7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_F41A81DB8F84A39C6A0B08C417370E41" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_32AD9C89C473207B81B908C417379DB7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_CB9BBA4130D6C72AE75008C4173704CC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_32AD9C89C473207B81B908C417379DB7" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_CB9BBA4130D6C72AE75008C4173704CC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_CB9BBA4130D6C72AE75008C4173704CC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_32AD9C89C473207B81B908C417379DB7" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_CB9BBA4130D6C72AE75008C4173704CC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_53327C0BF129F210EB0508C41737B1F4" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_CB9BBA4130D6C72AE75008C4173704CC" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_53327C0BF129F210EB0508C41737B1F4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_B1ED5CF38C7C6CDFFA7208C41737473C" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_CB9BBA4130D6C72AE75008C4173704CC" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_B1ED5CF38C7C6CDFFA7208C41737473C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_43EAC294FADE3460CBE808C417377FC3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_99AD8A0D79372AE6D7FD08C417378CFF" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationDiscountRate_43EAC294FADE3460CBE808C417377FC3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease_674D4A0CCAE2844A175708C4173723DD" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_99AD8A0D79372AE6D7FD08C417378CFF" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingBenefitObligationRateOfCompensationIncrease_674D4A0CCAE2844A175708C4173723DD" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanDisclosureLineItems" xlink:label="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_38580F45F89AABA7481D08C416DD321D" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable" xlink:label="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_B2314DA747F3EB4224E008C416DD690A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_38580F45F89AABA7481D08C416DD321D" xlink:to="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_B2314DA747F3EB4224E008C416DD690A" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeAxis" xlink:label="loc_us-gaap_RetirementPlanTypeAxis_BDDD6C94FB4CDF9FE4FE08C416DDE723" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfDefinedBenefitPlansDisclosuresTable_B2314DA747F3EB4224E008C416DD690A" xlink:to="loc_us-gaap_RetirementPlanTypeAxis_BDDD6C94FB4CDF9FE4FE08C416DDE723" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_9AF914F5E996FFD15DD308C416DD9197_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_BDDD6C94FB4CDF9FE4FE08C416DDE723" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_9AF914F5E996FFD15DD308C416DD9197_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetirementPlanTypeDomain" xlink:label="loc_us-gaap_RetirementPlanTypeDomain_9AF914F5E996FFD15DD308C416DD9197" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RetirementPlanTypeAxis_BDDD6C94FB4CDF9FE4FE08C416DDE723" xlink:to="loc_us-gaap_RetirementPlanTypeDomain_9AF914F5E996FFD15DD308C416DD9197" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PensionPlansDefinedBenefitMember" xlink:label="loc_us-gaap_PensionPlansDefinedBenefitMember_EF1CEA9B93505C61751708C416DD26AE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_9AF914F5E996FFD15DD308C416DD9197" xlink:to="loc_us-gaap_PensionPlansDefinedBenefitMember_EF1CEA9B93505C61751708C416DD26AE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember" xlink:label="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_1407D4BC4D89A5DEBB4008C416DD76CF" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RetirementPlanTypeDomain_9AF914F5E996FFD15DD308C416DD9197" xlink:to="loc_us-gaap_OtherPostretirementBenefitPlansDefinedBenefitMember_1407D4BC4D89A5DEBB4008C416DD76CF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate_7239BE83987E346983D108C416DD8922" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_38580F45F89AABA7481D08C416DD321D" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostDiscountRate_7239BE83987E346983D108C416DD8922" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets_C67A549F209C2FCBEC3B08C416DD6A22" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_38580F45F89AABA7481D08C416DD321D" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostExpectedLongTermReturnOnAssets_C67A549F209C2FCBEC3B08C416DD6A22" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease" xlink:label="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease_C76EBE2D3089EDC60F8408C416DDEF03" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DefinedBenefitPlanDisclosureLineItems_38580F45F89AABA7481D08C416DD321D" xlink:to="loc_us-gaap_DefinedBenefitPlanAssumptionsUsedCalculatingNetPeriodicBenefitCostRateOfCompensationIncrease_C76EBE2D3089EDC60F8408C416DDEF03" 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/ScheduleIiValuationAndQualifyingAccounts" xlink:type="extended"/>
<link:definitionLink xlink:role="http://www.hersheys.com/role/ScheduleIiValuationAndQualifyingAccountsDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAndQualifyingAccountsDisclosureLineItems" xlink:label="loc_us-gaap_ValuationAndQualifyingAccountsDisclosureLineItems_747E42671E2B181A3CB508C416FBEB09" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAndQualifyingAccountsDisclosureTable" xlink:label="loc_us-gaap_ValuationAndQualifyingAccountsDisclosureTable_7943B1A9C7FBFFD2937F08C416FBC118" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ValuationAndQualifyingAccountsDisclosureLineItems_747E42671E2B181A3CB508C416FBEB09" xlink:to="loc_us-gaap_ValuationAndQualifyingAccountsDisclosureTable_7943B1A9C7FBFFD2937F08C416FBC118" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesTypeAxis" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_07B2876B10CFAC66D67208C416FBA656" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ValuationAndQualifyingAccountsDisclosureTable_7943B1A9C7FBFFD2937F08C416FBC118" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_07B2876B10CFAC66D67208C416FBA656" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_07B2876B10CFAC66D67208C416FBA656" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDomain" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesTypeAxis_07B2876B10CFAC66D67208C416FBA656" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AllowanceForTradeReceivablesMember" xlink:label="loc_us-gaap_AllowanceForTradeReceivablesMember_927FE31874F0D916369308C416FBEE26" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274" xlink:to="loc_us-gaap_AllowanceForTradeReceivablesMember_927FE31874F0D916369308C416FBEE26" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember" xlink:label="loc_us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember_E2435E04BACFBE0AB67B08C416FB4CF6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274" xlink:to="loc_us-gaap_ValuationAllowanceOfDeferredTaxAssetsMember_E2435E04BACFBE0AB67B08C416FB4CF6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InventoryValuationReserveMember" xlink:label="loc_us-gaap_InventoryValuationReserveMember_732F467B6FF30964D28C08C416FBBF71" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAllowancesAndReservesDomain_7D55E96743612FD5CB2208C416FBC274" xlink:to="loc_us-gaap_InventoryValuationReserveMember_732F467B6FF30964D28C08C416FBBF71" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MovementInValuationAllowancesAndReservesRollForward" xlink:label="loc_us-gaap_MovementInValuationAllowancesAndReservesRollForward_09C26A0964E54ACE991008C416FB266A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ValuationAndQualifyingAccountsDisclosureLineItems_747E42671E2B181A3CB508C416FBEB09" xlink:to="loc_us-gaap_MovementInValuationAllowancesAndReservesRollForward_09C26A0964E54ACE991008C416FB266A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesBalance" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesBalance_7D3DC04005ADAD31BCD708C416FBB0F0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInValuationAllowancesAndReservesRollForward_09C26A0964E54ACE991008C416FB266A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesBalance_7D3DC04005ADAD31BCD708C416FBB0F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense_73BEF579ED971EA914CB08C416FBE025" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInValuationAllowancesAndReservesRollForward_09C26A0964E54ACE991008C416FB266A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesChargedToCostAndExpense_73BEF579ED971EA914CB08C416FBE025" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts_D37D3E9E4C182C9FC81708C416FBA952" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInValuationAllowancesAndReservesRollForward_09C26A0964E54ACE991008C416FB266A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesChargedToOtherAccounts_D37D3E9E4C182C9FC81708C416FBA952" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowancesAndReservesDeductions" xlink:label="loc_us-gaap_ValuationAllowancesAndReservesDeductions_0581CE411328827B02E808C416FBB8A4" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInValuationAllowancesAndReservesRollForward_09C26A0964E54ACE991008C416FB266A" xlink:to="loc_us-gaap_ValuationAllowancesAndReservesDeductions_0581CE411328827B02E808C416FBB8A4" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasicLineItems" xlink:label="loc_us-gaap_EarningsPerShareBasicLineItems_C71CB68267F655463F4C08C4195C5895" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable" xlink:label="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_5263AFF776472ACD1F8208C4195C73BB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_C71CB68267F655463F4C08C4195C5895" xlink:to="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_5263AFF776472ACD1F8208C4195C73BB" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_AF9FD30CA1588A388AAB08C4195C5612" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_5263AFF776472ACD1F8208C4195C73BB" xlink:to="loc_us-gaap_StatementClassOfStockAxis_AF9FD30CA1588A388AAB08C4195C5612" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_F0EDF81ECFF93379DF2808C4195C7C2A_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_AF9FD30CA1588A388AAB08C4195C5612" xlink:to="loc_us-gaap_ClassOfStockDomain_F0EDF81ECFF93379DF2808C4195C7C2A_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_F0EDF81ECFF93379DF2808C4195C7C2A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_AF9FD30CA1588A388AAB08C4195C5612" xlink:to="loc_us-gaap_ClassOfStockDomain_F0EDF81ECFF93379DF2808C4195C7C2A" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_0171E67EDF8286CBCFA408C4195CD0CF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_F0EDF81ECFF93379DF2808C4195C7C2A" xlink:to="loc_hsy_HersheyCommonStockMember_0171E67EDF8286CBCFA408C4195CD0CF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_D4E27251B0C38305DAA208C4195C8813" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_F0EDF81ECFF93379DF2808C4195C7C2A" xlink:to="loc_us-gaap_CommonClassBMember_D4E27251B0C38305DAA208C4195C8813" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_1494DAFE484AC0AC58D908C4195CB4B9" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEarningsPerShareBasicByCommonClassTable_5263AFF776472ACD1F8208C4195C73BB" xlink:to="loc_us-gaap_AwardTypeAxis_1494DAFE484AC0AC58D908C4195CB4B9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_15894F5A4A0AFEB297AF08C4195C5AE3_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_1494DAFE484AC0AC58D908C4195CB4B9" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_15894F5A4A0AFEB297AF08C4195C5AE3_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_15894F5A4A0AFEB297AF08C4195C5AE3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_1494DAFE484AC0AC58D908C4195CB4B9" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_15894F5A4A0AFEB297AF08C4195C5AE3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_ACE4505E7EE1361BCDF808C4195C63DE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_15894F5A4A0AFEB297AF08C4195C5AE3" xlink:to="loc_us-gaap_EmployeeStockOptionMember_ACE4505E7EE1361BCDF808C4195C63DE" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_C7911257601A1AD9441A08C4195C99D6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_15894F5A4A0AFEB297AF08C4195C5AE3" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_C7911257601A1AD9441A08C4195C99D6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasicTwoClassMethodAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_C71CB68267F655463F4C08C4195C5895" xlink:to="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Dividends" xlink:label="loc_us-gaap_Dividends_DDBB23DCDB3E9438A11108C4195CAEF3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:to="loc_us-gaap_Dividends_DDBB23DCDB3E9438A11108C4195CAEF3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_F1FB3847B8FF11C74F3508C4195CE53C" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesBasic_F1FB3847B8FF11C74F3508C4195CE53C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_231B41829102DDDDA39908C4195C5177" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossBasic_231B41829102DDDDA39908C4195C5177" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingBasic" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_3F21C738B424B20A708A08C4195C82E8" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_3F21C738B424B20A708A08C4195C82E8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_88A90A97A87CBC9140F708C4195CF119" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicTwoClassMethodAbstract_32A75C5FF91CCE31B8BF08C4195CADCB" xlink:to="loc_us-gaap_EarningsPerShareBasic_88A90A97A87CBC9140F708C4195CF119" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract" xlink:label="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicLineItems_C71CB68267F655463F4C08C4195C5895" xlink:to="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DistributedEarnings" xlink:label="loc_us-gaap_DistributedEarnings_E50BAD7753AD5219AE2D08C4195CC695" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_us-gaap_DistributedEarnings_E50BAD7753AD5219AE2D08C4195CC695" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted" xlink:label="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_9D0B43180A3660C7C16B08C4195C1CF4" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_us-gaap_UndistributedEarningsLossAllocatedToParticipatingSecuritiesDiluted_9D0B43180A3660C7C16B08C4195C1CF4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted" xlink:label="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_91D980128B6F2BF8AB4B08C4195C79B8" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_us-gaap_ParticipatingSecuritiesDistributedAndUndistributedEarningsLossDiluted_91D980128B6F2BF8AB4B08C4195C79B8" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock" xlink:label="loc_hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock_0165B4FD99AEA0B47CAB08C4195C5FAE" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_hsy_IncrementalCommonSharesAttributabletoDilutiveEffectofConversionofCommonStock_0165B4FD99AEA0B47CAB08C4195C5FAE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements" xlink:label="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_414D58F229D0992FC7ED08C4195CFB63" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_414D58F229D0992FC7ED08C4195CFB63" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding" xlink:label="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_0E04A7BA617114EF133008C4195CE8F6" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_0E04A7BA617114EF133008C4195CE8F6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_F00014BEB08243B7599908C4195C6F7E" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareDilutedTwoClassMethodAbstract_40B4B5DD1EF47686486D08C4195CEF67" xlink:to="loc_us-gaap_EarningsPerShareDiluted_F00014BEB08243B7599908C4195C6F7E" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_43856A82331D3D00B92308C41A38DE51" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D65112A28793DBF1027808C41A389AC6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_43856A82331D3D00B92308C41A38DE51" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D65112A28793DBF1027808C41A389AC6" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsAxis" xlink:label="loc_us-gaap_ConsolidationItemsAxis_41499115676A9E1836C408C41A381C87" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D65112A28793DBF1027808C41A389AC6" xlink:to="loc_us-gaap_ConsolidationItemsAxis_41499115676A9E1836C408C41A381C87" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_51E716259FF8C164216B08C41A385E92_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConsolidationItemsAxis_41499115676A9E1836C408C41A381C87" xlink:to="loc_us-gaap_ConsolidationItemsDomain_51E716259FF8C164216B08C41A385E92_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_51E716259FF8C164216B08C41A385E92" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConsolidationItemsAxis_41499115676A9E1836C408C41A381C87" xlink:to="loc_us-gaap_ConsolidationItemsDomain_51E716259FF8C164216B08C41A385E92" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_166D79A3F0F316ADAA7308C41A381C58" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_51E716259FF8C164216B08C41A385E92" xlink:to="loc_us-gaap_OperatingSegmentsMember_166D79A3F0F316ADAA7308C41A381C58" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CorporateNonSegmentMember" xlink:label="loc_us-gaap_CorporateNonSegmentMember_9504DDD6C9265ECFF47C08C41A38B7C8" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_51E716259FF8C164216B08C41A385E92" xlink:to="loc_us-gaap_CorporateNonSegmentMember_9504DDD6C9265ECFF47C08C41A38B7C8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_C40131C1E32B3F6F0A3D08C41A381F77" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_D65112A28793DBF1027808C41A389AC6" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_C40131C1E32B3F6F0A3D08C41A381F77" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_C40131C1E32B3F6F0A3D08C41A381F77" xlink:to="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_C40131C1E32B3F6F0A3D08C41A381F77" xlink:to="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_E545F926ED08953B562F08C41A38930A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11" xlink:to="loc_hsy_NorthAmericaSegmentMember_E545F926ED08953B562F08C41A38930A" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_F9D391068C16EFF7FCE008C41A38F5A3" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11" xlink:to="loc_hsy_InternationalandOtherSegmentMember_F9D391068C16EFF7FCE008C41A38F5A3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CorporateMember" xlink:label="loc_us-gaap_CorporateMember_E494F66860A9FCF0D99A08C41A3860F5" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_2C1E7D70C2C72A4975E208C41A383D11" xlink:to="loc_us-gaap_CorporateMember_E494F66860A9FCF0D99A08C41A3860F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DepreciationDepletionAndAmortization" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_C64031B948B6E12D0ED308C41A3877C0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_43856A82331D3D00B92308C41A38DE51" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_C64031B948B6E12D0ED308C41A3877C0" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_B248D1C7A092A66DB9C208C4174B8471" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_B248D1C7A092A66DB9C208C4174B8471" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsAxis" xlink:label="loc_us-gaap_ConsolidationItemsAxis_8AF49C04B48A7B95AA7008C4174B7A93" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_B248D1C7A092A66DB9C208C4174B8471" xlink:to="loc_us-gaap_ConsolidationItemsAxis_8AF49C04B48A7B95AA7008C4174B7A93" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConsolidationItemsAxis_8AF49C04B48A7B95AA7008C4174B7A93" xlink:to="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConsolidationItemsAxis_8AF49C04B48A7B95AA7008C4174B7A93" xlink:to="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_DAE81BF85F40614AB50808C4174BF138" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61" xlink:to="loc_us-gaap_OperatingSegmentsMember_DAE81BF85F40614AB50808C4174BF138" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CorporateNonSegmentMember" xlink:label="loc_us-gaap_CorporateNonSegmentMember_A1B1808B2F65DD9E1E8708C4174B9434" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61" xlink:to="loc_us-gaap_CorporateNonSegmentMember_A1B1808B2F65DD9E1E8708C4174B9434" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_2604F012F837E775875108C4174B143F" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_8B4AA6A882CEE0D6C01A08C4174B6D61" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_2604F012F837E775875108C4174B143F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_7DF73E462EA077B3340208C4174B862B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_B248D1C7A092A66DB9C208C4174B8471" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_7DF73E462EA077B3340208C4174B862B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_7DF73E462EA077B3340208C4174B862B" xlink:to="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_7DF73E462EA077B3340208C4174B862B" xlink:to="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_AD14A59F2D636469C5A208C41755941D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_AD14A59F2D636469C5A208C41755941D" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_820B2E1F362235E2B16608C417552C06" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28" xlink:to="loc_hsy_NorthAmericaSegmentMember_820B2E1F362235E2B16608C417552C06" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_InternationalandOtherSegmentMember" xlink:label="loc_hsy_InternationalandOtherSegmentMember_A496075CCD6F70620C4F08C417551AB4" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_D27AD562194450C41BCB08C417553C28" xlink:to="loc_hsy_InternationalandOtherSegmentMember_A496075CCD6F70620C4F08C417551AB4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueNet" xlink:label="loc_us-gaap_SalesRevenueNet_FABF03FFC4FDCBE1DDA808C4175579F0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_SalesRevenueNet_FABF03FFC4FDCBE1DDA808C4175579F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_175C7D8F0F019CA042BA08C417550B62" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_OperatingIncomeLoss_175C7D8F0F019CA042BA08C417550B62" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_6EC9EA023294B2A514B208C41755FC65" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_6EC9EA023294B2A514B208C41755FC65" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GoodwillAndIntangibleAssetImpairment" xlink:label="loc_us-gaap_GoodwillAndIntangibleAssetImpairment_ED9F9947B0DF66433CD108C41755C71D" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_GoodwillAndIntangibleAssetImpairment_ED9F9947B0DF66433CD108C41755C71D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestructuringCharges" xlink:label="loc_us-gaap_RestructuringCharges_20B30F954342D7FF2C9C08C417551E85" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_RestructuringCharges_20B30F954342D7FF2C9C08C417551E85" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PensionExpenseNonServiceRelated" xlink:label="loc_hsy_PensionExpenseNonServiceRelated_FA8B3B13FDDAF7C4C4C908C4175547F9" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_hsy_PensionExpenseNonServiceRelated_FA8B3B13FDDAF7C4C4C908C4175547F9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationIntegrationRelatedCosts" xlink:label="loc_us-gaap_BusinessCombinationIntegrationRelatedCosts_C759D72ADD22F5DC646D08C41755A21A" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_BusinessCombinationIntegrationRelatedCosts_C759D72ADD22F5DC646D08C41755A21A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestIncomeExpenseNonoperatingNet" xlink:label="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_09512C67C87A2CDD21FA08C417550183" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_09512C67C87A2CDD21FA08C417550183" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_F8785495F099FB9F118A08C41755B4F0" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_F8785495F099FB9F118A08C41755B4F0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_D5C6DCB2B3019CB786C108C417552685" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_31C7F48DA329F49413C008C41755F0B5" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_D5C6DCB2B3019CB786C108C417552685" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_337FD3D9EE1BA53F23E108C41895B9DD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_StatementTable_337FD3D9EE1BA53F23E108C41895B9DD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_E2B8875202BEED40BA6308C418951080" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_337FD3D9EE1BA53F23E108C41895B9DD" xlink:to="loc_us-gaap_StatementClassOfStockAxis_E2B8875202BEED40BA6308C418951080" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_06F6955FA4DB5FB1123908C41895D1D2_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_E2B8875202BEED40BA6308C418951080" xlink:to="loc_us-gaap_ClassOfStockDomain_06F6955FA4DB5FB1123908C41895D1D2_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_06F6955FA4DB5FB1123908C41895D1D2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_E2B8875202BEED40BA6308C418951080" xlink:to="loc_us-gaap_ClassOfStockDomain_06F6955FA4DB5FB1123908C41895D1D2" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_HersheyCommonStockMember" xlink:label="loc_hsy_HersheyCommonStockMember_C6A39E2C37E1E3641C4708C4189578E9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_06F6955FA4DB5FB1123908C41895D1D2" xlink:to="loc_hsy_HersheyCommonStockMember_C6A39E2C37E1E3641C4708C4189578E9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonClassBMember" xlink:label="loc_us-gaap_CommonClassBMember_E51E6116F0A42707384D08C418953390" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_06F6955FA4DB5FB1123908C41895D1D2" xlink:to="loc_us-gaap_CommonClassBMember_E51E6116F0A42707384D08C418953390" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_1111483E72834B83506D08C418953CDC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_337FD3D9EE1BA53F23E108C41895B9DD" xlink:to="loc_us-gaap_RangeAxis_1111483E72834B83506D08C418953CDC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_C1A9247BCC0D2FE960D308C418951A44_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_1111483E72834B83506D08C418953CDC" xlink:to="loc_us-gaap_RangeMember_C1A9247BCC0D2FE960D308C418951A44_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_C1A9247BCC0D2FE960D308C418951A44" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_1111483E72834B83506D08C418953CDC" xlink:to="loc_us-gaap_RangeMember_C1A9247BCC0D2FE960D308C418951A44" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_492DBCCE8A5B2277CD1008C418952C6E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_C1A9247BCC0D2FE960D308C418951A44" xlink:to="loc_us-gaap_MaximumMember_492DBCCE8A5B2277CD1008C418952C6E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_9340B1396B0BC72BC14408C418952D9F" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_C1A9247BCC0D2FE960D308C418951A44" xlink:to="loc_us-gaap_MinimumMember_9340B1396B0BC72BC14408C418952D9F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueNet" xlink:label="loc_us-gaap_SalesRevenueNet_3163F0D9339EA980FB7708C41895401E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_SalesRevenueNet_3163F0D9339EA980FB7708C41895401E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GrossProfit" xlink:label="loc_us-gaap_GrossProfit_1757C9EA38EF012C0F4908C418955FF1" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_GrossProfit_1757C9EA38EF012C0F4908C418955FF1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLoss" xlink:label="loc_us-gaap_NetIncomeLoss_22EC809E66A67B387B5908C41895727F" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_NetIncomeLoss_22EC809E66A67B387B5908C41895727F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasic" xlink:label="loc_us-gaap_EarningsPerShareBasic_71C64370AF32813360F408C41895DA24" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_EarningsPerShareBasic_71C64370AF32813360F408C41895DA24" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareDiluted" xlink:label="loc_us-gaap_EarningsPerShareDiluted_B262FEB8FCBE1BA0929608C41895043E" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_EarningsPerShareDiluted_B262FEB8FCBE1BA0929608C41895043E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockDividendsPerShareCashPaid" xlink:label="loc_us-gaap_CommonStockDividendsPerShareCashPaid_99EF396CF97A6B4ACFAB08C418950431" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_CommonStockDividendsPerShareCashPaid_99EF396CF97A6B4ACFAB08C418950431" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_EC01E74C7ABB90091CF708C41895CE28" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_6760D1137970DED43E5A08C4189517AB" xlink:to="loc_us-gaap_SharePrice_EC01E74C7ABB90091CF708C41895CE28" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems" xlink:label="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_8C60F1A3C8FAF89209F508C41719F283" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable" xlink:label="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_64C73934264A11A11FF508C41719054C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_8C60F1A3C8FAF89209F508C41719F283" xlink:to="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_64C73934264A11A11FF508C41719054C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementGeographicalAxis" xlink:label="loc_us-gaap_StatementGeographicalAxis_ABE3CBCBB472B9E6EBFF08C41719F2E1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRevenuesFromExternalCustomersAndLongLivedAssetsTable_64C73934264A11A11FF508C41719054C" xlink:to="loc_us-gaap_StatementGeographicalAxis_ABE3CBCBB472B9E6EBFF08C41719F2E1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentGeographicalDomain" xlink:label="loc_us-gaap_SegmentGeographicalDomain_66692BAD38C347F56E8008C417190AAE_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementGeographicalAxis_ABE3CBCBB472B9E6EBFF08C41719F2E1" xlink:to="loc_us-gaap_SegmentGeographicalDomain_66692BAD38C347F56E8008C417190AAE_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentGeographicalDomain" xlink:label="loc_us-gaap_SegmentGeographicalDomain_66692BAD38C347F56E8008C417190AAE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementGeographicalAxis_ABE3CBCBB472B9E6EBFF08C41719F2E1" xlink:to="loc_us-gaap_SegmentGeographicalDomain_66692BAD38C347F56E8008C417190AAE" 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_8A9E7DC0525DF660E6EA08C41719D53B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentGeographicalDomain_66692BAD38C347F56E8008C417190AAE" xlink:to="loc_country_US_8A9E7DC0525DF660E6EA08C41719D53B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NonUsMember" xlink:label="loc_us-gaap_NonUsMember_6FCA7A9483797B64FD6108C41719EB77" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentGeographicalDomain_66692BAD38C347F56E8008C417190AAE" xlink:to="loc_us-gaap_NonUsMember_6FCA7A9483797B64FD6108C41719EB77" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueNet" xlink:label="loc_us-gaap_SalesRevenueNet_26FC02AE636DA7D5111B08C41719DF04" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_8C60F1A3C8FAF89209F508C41719F283" xlink:to="loc_us-gaap_SalesRevenueNet_26FC02AE636DA7D5111B08C41719DF04" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_FC1CD99B0CB8FD11215C08C41719036B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesFromExternalCustomersAndLongLivedAssetsLineItems_8C60F1A3C8FAF89209F508C41719F283" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_FC1CD99B0CB8FD11215C08C41719036B" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EntityWideRevenueMajorCustomerLineItems" xlink:label="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_4BC4E19440CDA3541C4708C4193EE509" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable" xlink:label="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_4BC4E19440CDA3541C4708C4193EE509" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_421A26B90E3B7CED7B1008C4193ED821" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_421A26B90E3B7CED7B1008C4193ED821" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_1570DBCACCD333F2159508C4193E2698_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_421A26B90E3B7CED7B1008C4193ED821" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_1570DBCACCD333F2159508C4193E2698_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationDomain" xlink:label="loc_us-gaap_IncomeStatementLocationDomain_1570DBCACCD333F2159508C4193E2698" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_421A26B90E3B7CED7B1008C4193ED821" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_1570DBCACCD333F2159508C4193E2698" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostOfSalesMember" xlink:label="loc_us-gaap_CostOfSalesMember_7EEAF2D9F01D3144425308C4193E0CEB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_1570DBCACCD333F2159508C4193E2698" xlink:to="loc_us-gaap_CostOfSalesMember_7EEAF2D9F01D3144425308C4193E0CEB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_9494DE24DD73A1D0739008C4193EA9A7" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_StatementScenarioAxis_9494DE24DD73A1D0739008C4193EA9A7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_3133FD2BEA1EE6C02ACC08C4193E1EDB_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_9494DE24DD73A1D0739008C4193EA9A7" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_3133FD2BEA1EE6C02ACC08C4193E1EDB_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_3133FD2BEA1EE6C02ACC08C4193E1EDB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_9494DE24DD73A1D0739008C4193EA9A7" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_3133FD2BEA1EE6C02ACC08C4193E1EDB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_B66C1A3E8737365068DE08C4193EBDE1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_3133FD2BEA1EE6C02ACC08C4193E1EDB" xlink:to="loc_us-gaap_ScenarioForecastMember_B66C1A3E8737365068DE08C4193EBDE1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsAxis" xlink:label="loc_us-gaap_ConsolidationItemsAxis_20C0D8CF7832A74C7EC308C4193E8CB8" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_ConsolidationItemsAxis_20C0D8CF7832A74C7EC308C4193E8CB8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_B18B1B3425084B2C4C6008C4193EC1E5_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConsolidationItemsAxis_20C0D8CF7832A74C7EC308C4193E8CB8" xlink:to="loc_us-gaap_ConsolidationItemsDomain_B18B1B3425084B2C4C6008C4193EC1E5_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_B18B1B3425084B2C4C6008C4193EC1E5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConsolidationItemsAxis_20C0D8CF7832A74C7EC308C4193E8CB8" xlink:to="loc_us-gaap_ConsolidationItemsDomain_B18B1B3425084B2C4C6008C4193EC1E5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_D3A08F6A9D5CC50E245008C4193E9CBD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_B18B1B3425084B2C4C6008C4193EC1E5" xlink:to="loc_us-gaap_OperatingSegmentsMember_D3A08F6A9D5CC50E245008C4193E9CBD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_C8253A9F2A157FCF492008C4193E3196" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_C8253A9F2A157FCF492008C4193E3196" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_AF6F2835BF662FD4217508C4193EED1D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_C8253A9F2A157FCF492008C4193E3196" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_AF6F2835BF662FD4217508C4193EED1D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_AF6F2835BF662FD4217508C4193EED1D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_C8253A9F2A157FCF492008C4193E3196" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_AF6F2835BF662FD4217508C4193EED1D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_61356073089AACAEB78108C4193E095B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_AF6F2835BF662FD4217508C4193EED1D" xlink:to="loc_us-gaap_CommodityContractMember_61356073089AACAEB78108C4193E095B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_874BDFC0F97D537BED9808C4193E2805" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_874BDFC0F97D537BED9808C4193E2805" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_83F5B8F5DD8BACE21D1308C4193EB73F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_874BDFC0F97D537BED9808C4193E2805" xlink:to="loc_us-gaap_SegmentDomain_83F5B8F5DD8BACE21D1308C4193EB73F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_83F5B8F5DD8BACE21D1308C4193EB73F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_874BDFC0F97D537BED9808C4193E2805" xlink:to="loc_us-gaap_SegmentDomain_83F5B8F5DD8BACE21D1308C4193EB73F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NorthAmericaSegmentMember" xlink:label="loc_hsy_NorthAmericaSegmentMember_72B03DE9F8CFD85F98F808C4193E82F6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_83F5B8F5DD8BACE21D1308C4193EB73F" xlink:to="loc_hsy_NorthAmericaSegmentMember_72B03DE9F8CFD85F98F808C4193E82F6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_C5F853810628600F021808C4193E60F5" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_C5F853810628600F021808C4193E60F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_E363339A14E3031BD3FD08C4193E151F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_C5F853810628600F021808C4193E60F5" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_E363339A14E3031BD3FD08C4193E151F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_E363339A14E3031BD3FD08C4193E151F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_C5F853810628600F021808C4193E60F5" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_E363339A14E3031BD3FD08C4193E151F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GeographicConcentrationRiskMember" xlink:label="loc_us-gaap_GeographicConcentrationRiskMember_90CAAA5226CE58AE413508C4193EA397" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_E363339A14E3031BD3FD08C4193E151F" xlink:to="loc_us-gaap_GeographicConcentrationRiskMember_90CAAA5226CE58AE413508C4193EA397" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_B9DDA4FF7F8990F4AA6E08C4193E1813" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_159BDC70BCFA1129BF1A08C4193E608D" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_B9DDA4FF7F8990F4AA6E08C4193E1813" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F0B43DF0842BFFCD518308C4193E2263_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_B9DDA4FF7F8990F4AA6E08C4193E1813" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F0B43DF0842BFFCD518308C4193E2263_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F0B43DF0842BFFCD518308C4193E2263" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_B9DDA4FF7F8990F4AA6E08C4193E1813" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F0B43DF0842BFFCD518308C4193E2263" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueGoodsNetMember" xlink:label="loc_us-gaap_SalesRevenueGoodsNetMember_DD42A1050C5B8621524C08C4193E11B0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F0B43DF0842BFFCD518308C4193E2263" xlink:to="loc_us-gaap_SalesRevenueGoodsNetMember_DD42A1050C5B8621524C08C4193E11B0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_933697F9147A673F7BC008C4193E13F9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_4BC4E19440CDA3541C4708C4193EE509" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_933697F9147A673F7BC008C4193E13F9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_EAC180C9648C252A862108C4193E5CA3" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_4BC4E19440CDA3541C4708C4193EE509" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_EAC180C9648C252A862108C4193E5CA3" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome" xlink:label="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_70364E2D261BC361A08708C4193EE361" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_4BC4E19440CDA3541C4708C4193EE509" xlink:to="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_70364E2D261BC361A08708C4193EE361" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentReportingInformationLineItems" xlink:label="loc_us-gaap_SegmentReportingInformationLineItems_962C02609E6B52BCDCA708C4181D99F3" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable" xlink:label="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_962C02609E6B52BCDCA708C4181D99F3" xlink:to="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationAxis" xlink:label="loc_us-gaap_HedgingDesignationAxis_32BD9FB0A79DAD7BD54908C4181D606A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:to="loc_us-gaap_HedgingDesignationAxis_32BD9FB0A79DAD7BD54908C4181D606A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_150E54882B5995A8186A08C4181D06AE_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_HedgingDesignationAxis_32BD9FB0A79DAD7BD54908C4181D606A" xlink:to="loc_us-gaap_HedgingDesignationDomain_150E54882B5995A8186A08C4181D06AE_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_HedgingDesignationDomain" xlink:label="loc_us-gaap_HedgingDesignationDomain_150E54882B5995A8186A08C4181D06AE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_HedgingDesignationAxis_32BD9FB0A79DAD7BD54908C4181D606A" xlink:to="loc_us-gaap_HedgingDesignationDomain_150E54882B5995A8186A08C4181D06AE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NondesignatedMember" xlink:label="loc_us-gaap_NondesignatedMember_E6259FBA1E273F1B1B1608C4181D8AF6" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_HedgingDesignationDomain_150E54882B5995A8186A08C4181D06AE" xlink:to="loc_us-gaap_NondesignatedMember_E6259FBA1E273F1B1B1608C4181D8AF6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentRiskAxis" xlink:label="loc_us-gaap_DerivativeInstrumentRiskAxis_E444EB8839926CC45E5308C4181D6535" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_E444EB8839926CC45E5308C4181D6535" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_A113D006DDF3D03DED3C08C4181D2049_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_E444EB8839926CC45E5308C4181D6535" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A113D006DDF3D03DED3C08C4181D2049_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeContractTypeDomain" xlink:label="loc_us-gaap_DerivativeContractTypeDomain_A113D006DDF3D03DED3C08C4181D2049" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_E444EB8839926CC45E5308C4181D6535" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A113D006DDF3D03DED3C08C4181D2049" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommodityContractMember" xlink:label="loc_us-gaap_CommodityContractMember_EC2C14E9B16A0F0856A708C4181D0D7D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A113D006DDF3D03DED3C08C4181D2049" xlink:to="loc_us-gaap_CommodityContractMember_EC2C14E9B16A0F0856A708C4181D0D7D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsAxis" xlink:label="loc_us-gaap_ConsolidationItemsAxis_89243A227E0C93807BB208C4181DA7C4" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:to="loc_us-gaap_ConsolidationItemsAxis_89243A227E0C93807BB208C4181DA7C4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_9190B6B95951E8998B7A08C4181D21CC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConsolidationItemsAxis_89243A227E0C93807BB208C4181DA7C4" xlink:to="loc_us-gaap_ConsolidationItemsDomain_9190B6B95951E8998B7A08C4181D21CC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConsolidationItemsDomain" xlink:label="loc_us-gaap_ConsolidationItemsDomain_9190B6B95951E8998B7A08C4181D21CC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConsolidationItemsAxis_89243A227E0C93807BB208C4181DA7C4" xlink:to="loc_us-gaap_ConsolidationItemsDomain_9190B6B95951E8998B7A08C4181D21CC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingSegmentsMember" xlink:label="loc_us-gaap_OperatingSegmentsMember_F5773C10C1C1267838C008C4181D9FB8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConsolidationItemsDomain_9190B6B95951E8998B7A08C4181D21CC" xlink:to="loc_us-gaap_OperatingSegmentsMember_F5773C10C1C1267838C008C4181D9FB8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementBusinessSegmentsAxis" xlink:label="loc_us-gaap_StatementBusinessSegmentsAxis_C971582582456C369A4608C4181D4434" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:to="loc_us-gaap_StatementBusinessSegmentsAxis_C971582582456C369A4608C4181D4434" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_CEBE71DC9B2C51D25BA708C4181D4E14_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_C971582582456C369A4608C4181D4434" xlink:to="loc_us-gaap_SegmentDomain_CEBE71DC9B2C51D25BA708C4181D4E14_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SegmentDomain" xlink:label="loc_us-gaap_SegmentDomain_CEBE71DC9B2C51D25BA708C4181D4E14" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementBusinessSegmentsAxis_C971582582456C369A4608C4181D4434" xlink:to="loc_us-gaap_SegmentDomain_CEBE71DC9B2C51D25BA708C4181D4E14" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaterialReconcilingItemsMember" xlink:label="loc_us-gaap_MaterialReconcilingItemsMember_BA216FA1B5E3C6AACBEC08C4181D36C9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentDomain_CEBE71DC9B2C51D25BA708C4181D4E14" xlink:to="loc_us-gaap_MaterialReconcilingItemsMember_BA216FA1B5E3C6AACBEC08C4181D36C9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsegmentsAxis" xlink:label="loc_us-gaap_SubsegmentsAxis_D0E2174A95C32401894808C4181D4B8D" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:to="loc_us-gaap_SubsegmentsAxis_D0E2174A95C32401894808C4181D4B8D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsegmentsDomain" xlink:label="loc_us-gaap_SubsegmentsDomain_547C601E6907415AA48208C4181DA64A_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsegmentsAxis_D0E2174A95C32401894808C4181D4B8D" xlink:to="loc_us-gaap_SubsegmentsDomain_547C601E6907415AA48208C4181DA64A_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsegmentsDomain" xlink:label="loc_us-gaap_SubsegmentsDomain_547C601E6907415AA48208C4181DA64A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsegmentsAxis_D0E2174A95C32401894808C4181D4B8D" xlink:to="loc_us-gaap_SubsegmentsDomain_547C601E6907415AA48208C4181DA64A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsAxis" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BCD2AE43012CA19F36F108C4181D63A0" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable_30170F3D99619505C60108C4181D5D51" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BCD2AE43012CA19F36F108C4181D63A0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsDomain" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsDomain_3BFE4CBB8271D4A3041B08C4181D58C3_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BCD2AE43012CA19F36F108C4181D63A0" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsDomain_3BFE4CBB8271D4A3041B08C4181D58C3_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsegmentsConsolidationItemsDomain" xlink:label="loc_us-gaap_SubsegmentsConsolidationItemsDomain_3BFE4CBB8271D4A3041B08C4181D58C3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsegmentsConsolidationItemsAxis_BCD2AE43012CA19F36F108C4181D63A0" xlink:to="loc_us-gaap_SubsegmentsConsolidationItemsDomain_3BFE4CBB8271D4A3041B08C4181D58C3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeGainLossOnDerivativeNet" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_420641BC10890B18D84108C4181D840E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_962C02609E6B52BCDCA708C4181D99F3" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_420641BC10890B18D84108C4181D840E" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome" xlink:label="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_9B3EAAA2C517AF7969CF08C4181DBD29" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_962C02609E6B52BCDCA708C4181D99F3" xlink:to="loc_hsy_NetGainLossOnCommodityDerivativePositionsReclassifiedFromUnallocatedDerivativeGainsLossesToSegmentIncome_9B3EAAA2C517AF7969CF08C4181DBD29" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses" xlink:label="loc_hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses_53D8A82180DB817DB99E08C4181D1BA3" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SegmentReportingInformationLineItems_962C02609E6B52BCDCA708C4181D99F3" xlink:to="loc_hsy_NetMarktoMarketValuationofCertainDerivativePositionsRecognizedinUnallocatedDerivativeGainsLosses_53D8A82180DB817DB99E08C4181D1BA3" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_BB6A102D6723F06C652408C41A4CE11B" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_71C31DFC19B0A8818D6F08C41A4CE466" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB6A102D6723F06C652408C41A4CE11B" xlink:to="loc_us-gaap_DebtInstrumentTable_71C31DFC19B0A8818D6F08C41A4CE466" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_F41341E8E4205CE9A26108C41A4C55BF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_71C31DFC19B0A8818D6F08C41A4CE466" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_F41341E8E4205CE9A26108C41A4C55BF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_ED0586A9A9FEF25F5D0308C41A4C89E1_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_F41341E8E4205CE9A26108C41A4C55BF" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_ED0586A9A9FEF25F5D0308C41A4C89E1_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_ED0586A9A9FEF25F5D0308C41A4C89E1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_F41341E8E4205CE9A26108C41A4C55BF" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_ED0586A9A9FEF25F5D0308C41A4C89E1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_4B437D503B816F9B949708C41A4CBBAB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_ED0586A9A9FEF25F5D0308C41A4C89E1" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_4B437D503B816F9B949708C41A4CBBAB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_67F4D1766CB59EC4718408C41A4CB4EB" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_71C31DFC19B0A8818D6F08C41A4CE466" xlink:to="loc_us-gaap_DebtInstrumentAxis_67F4D1766CB59EC4718408C41A4CB4EB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_67F4D1766CB59EC4718408C41A4CB4EB" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_67F4D1766CB59EC4718408C41A4CB4EB" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes5.45Due2016Member" xlink:label="loc_hsy_Notes5.45Due2016Member_E712E9DBA7097BBFBF0808C41A4C3044" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes5.45Due2016Member_E712E9DBA7097BBFBF0808C41A4C3044" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes1.50Due2016Member" xlink:label="loc_hsy_Notes1.50Due2016Member_2DEC204878AC83E9D42108C41A4CA226" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes1.50Due2016Member_2DEC204878AC83E9D42108C41A4CA226" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes1.60Due2018Member" xlink:label="loc_hsy_Notes1.60Due2018Member_0A92CB49E09988A2028E08C41A4C782B" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes1.60Due2018Member_0A92CB49E09988A2028E08C41A4C782B" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes4.125Due2020Member" xlink:label="loc_hsy_Notes4.125Due2020Member_64695BC4817020E6DBFD08C41A4C619C" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes4.125Due2020Member_64695BC4817020E6DBFD08C41A4C619C" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_16695CB4AB74051F1FDD08C41A4CF08D" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Debentures8.8Due2021Member_16695CB4AB74051F1FDD08C41A4CF08D" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes2.625Due2023Member" xlink:label="loc_hsy_Notes2.625Due2023Member_4ACB78AA49504F89A5B408C41A4C77DB" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes2.625Due2023Member_4ACB78AA49504F89A5B408C41A4C77DB" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.20Due2025Member" xlink:label="loc_hsy_Notes3.20Due2025Member_4054EB7747FFEBEF5ED708C41A4C9044" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes3.20Due2025Member_4054EB7747FFEBEF5ED708C41A4C9044" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_EC28D7A67F0122C5296208C41A4C8442" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes2.30Due2026Member_EC28D7A67F0122C5296208C41A4C8442" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_48DC12FC7B16BA82D1AD08C41A4C237A" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Debentures7.2Due2027Member_48DC12FC7B16BA82D1AD08C41A4C237A" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_92599CB205FB882DC4F008C41A4C4066" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_EC410CC57109AAEE94B508C41A4C0F82" xlink:to="loc_hsy_Notes3.375Due2046Member_92599CB205FB882DC4F008C41A4C4066" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_2260A25657C008FD1BD308C41A4C96A9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_BB6A102D6723F06C652408C41A4CE11B" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_2260A25657C008FD1BD308C41A4C96A9" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_44AD7C129577DA7A919308C417EBB9CD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_DebtInstrumentTable_44AD7C129577DA7A919308C417EBB9CD" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_F0CD7A08689F392B794608C417EB8D03" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_44AD7C129577DA7A919308C417EBB9CD" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_F0CD7A08689F392B794608C417EB8D03" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_74B64713CA53C3CFDCA008C417EBF09C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_F0CD7A08689F392B794608C417EB8D03" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_74B64713CA53C3CFDCA008C417EBF09C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_74B64713CA53C3CFDCA008C417EBF09C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_F0CD7A08689F392B794608C417EB8D03" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_74B64713CA53C3CFDCA008C417EBF09C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_12E2FE5CF0453595A7FB08C417EB91FA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_74B64713CA53C3CFDCA008C417EBF09C" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_12E2FE5CF0453595A7FB08C417EB91FA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_014B4B7E1F5426DC744808C417EB8B56" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_44AD7C129577DA7A919308C417EBB9CD" xlink:to="loc_us-gaap_DebtInstrumentAxis_014B4B7E1F5426DC744808C417EB8B56" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_014B4B7E1F5426DC744808C417EB8B56" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_014B4B7E1F5426DC744808C417EB8B56" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes5.45Due2016Member" xlink:label="loc_hsy_Notes5.45Due2016Member_BC3CFB0C4328CC0B44C208C417EBA661" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:to="loc_hsy_Notes5.45Due2016Member_BC3CFB0C4328CC0B44C208C417EBA661" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes1.50Due2016Member" xlink:label="loc_hsy_Notes1.50Due2016Member_65D33C15807F931FFCEF08C417EB4428" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:to="loc_hsy_Notes1.50Due2016Member_65D33C15807F931FFCEF08C417EB4428" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_74D801D8EB50FFE7C76608C417EBABB6" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:to="loc_hsy_Notes2.30Due2026Member_74D801D8EB50FFE7C76608C417EBABB6" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_4362A166AC59F95F2C0108C417EBA2F1" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:to="loc_hsy_Notes3.375Due2046Member_4362A166AC59F95F2C0108C417EBA2F1" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_622868150C870AA17F0808C417EBDD54" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:to="loc_hsy_Debentures8.8Due2021Member_622868150C870AA17F0808C417EBDD54" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_0304C2F6A72A258F38B208C417EBB439" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_BC658133F6AB12BA374208C417EB976F" xlink:to="loc_hsy_Debentures7.2Due2027Member_0304C2F6A72A258F38B208C417EBB439" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ExtinguishmentOfDebtAxis" xlink:label="loc_us-gaap_ExtinguishmentOfDebtAxis_770FE21AD4432272B38908C417EB2C74" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_44AD7C129577DA7A919308C417EBB9CD" xlink:to="loc_us-gaap_ExtinguishmentOfDebtAxis_770FE21AD4432272B38908C417EB2C74" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ExtinguishmentOfDebtTypeDomain" xlink:label="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_16C5078C8319D9832BA208C417EBC731_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ExtinguishmentOfDebtAxis_770FE21AD4432272B38908C417EB2C74" xlink:to="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_16C5078C8319D9832BA208C417EBC731_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ExtinguishmentOfDebtTypeDomain" xlink:label="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_16C5078C8319D9832BA208C417EBC731" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ExtinguishmentOfDebtAxis_770FE21AD4432272B38908C417EB2C74" xlink:to="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_16C5078C8319D9832BA208C417EBC731" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_B4246BD5EFFE3A46207408C417EB1D55" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ExtinguishmentOfDebtTypeDomain_16C5078C8319D9832BA208C417EBC731" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_B4246BD5EFFE3A46207408C417EB1D55" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RepaymentsOfDebt" xlink:label="loc_us-gaap_RepaymentsOfDebt_1A3B3586DCDFC2922A8108C417F56EAF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_RepaymentsOfDebt_1A3B3586DCDFC2922A8108C417F56EAF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_7526889AE22228C7B55F08C417F5DF68" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_7526889AE22228C7B55F08C417F5DF68" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentFaceAmount" xlink:label="loc_us-gaap_DebtInstrumentFaceAmount_4A9FF01669CD1AD772FA08C417F5EF04" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_DebtInstrumentFaceAmount_4A9FF01669CD1AD772FA08C417F5EF04" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_7E295A359AB0DD6486BA08C417F5D294" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_7E295A359AB0DD6486BA08C417F5D294" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentRepurchaseAmount" xlink:label="loc_us-gaap_DebtInstrumentRepurchaseAmount_B4D0B77C0548D7F7688A08C417F5AC03" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_DebtInstrumentRepurchaseAmount_B4D0B77C0548D7F7688A08C417F5AC03" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ExtinguishmentOfDebtAmount" xlink:label="loc_us-gaap_ExtinguishmentOfDebtAmount_7B3899D3D579F008FA2608C417F59C72" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_ExtinguishmentOfDebtAmount_7B3899D3D579F008FA2608C417F59C72" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GainsLossesOnExtinguishmentOfDebt" xlink:label="loc_us-gaap_GainsLossesOnExtinguishmentOfDebt_1833183CCE67AFB7E63C08C417F5D86C" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_GainsLossesOnExtinguishmentOfDebt_1833183CCE67AFB7E63C08C417F5D86C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GainOnFairValueHedgeIneffectiveness" xlink:label="loc_us-gaap_GainOnFairValueHedgeIneffectiveness_FC3B4D9175907B963DCE08C417F5EE2A" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_4080700E00DCB49131A408C417EB6880" xlink:to="loc_us-gaap_GainOnFairValueHedgeIneffectiveness_FC3B4D9175907B963DCE08C417F5EE2A" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentLineItems" xlink:label="loc_us-gaap_DebtInstrumentLineItems_C6A85EB2174E25BCA51B08C416F1D66A" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentTable" xlink:label="loc_us-gaap_DebtInstrumentTable_93271C76AEB7A844D54508C416F13B64" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_C6A85EB2174E25BCA51B08C416F1D66A" xlink:to="loc_us-gaap_DebtInstrumentTable_93271C76AEB7A844D54508C416F13B64" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_5B9C225DF2B2CA41F8B808C416F1600B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_93271C76AEB7A844D54508C416F13B64" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_5B9C225DF2B2CA41F8B808C416F1600B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_C5B5D7E7DC2F38F9445308C416F19417_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_5B9C225DF2B2CA41F8B808C416F1600B" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_C5B5D7E7DC2F38F9445308C416F19417_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_C5B5D7E7DC2F38F9445308C416F19417" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_5B9C225DF2B2CA41F8B808C416F1600B" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_C5B5D7E7DC2F38F9445308C416F19417" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_4845453798B515439B1808C416F1167D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_C5B5D7E7DC2F38F9445308C416F19417" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_4845453798B515439B1808C416F1167D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CapitalLeaseObligationsMember" xlink:label="loc_us-gaap_CapitalLeaseObligationsMember_C09724AB4505440C65A808C416F1A95B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_C5B5D7E7DC2F38F9445308C416F19417" xlink:to="loc_us-gaap_CapitalLeaseObligationsMember_C09724AB4505440C65A808C416F1A95B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_446BE05EF41791681C0E08C416F14FBE" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_93271C76AEB7A844D54508C416F13B64" xlink:to="loc_us-gaap_DebtInstrumentAxis_446BE05EF41791681C0E08C416F14FBE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_446BE05EF41791681C0E08C416F14FBE" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_446BE05EF41791681C0E08C416F14FBE" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes5.45Due2016Member" xlink:label="loc_hsy_Notes5.45Due2016Member_717610C8D03A2D287B2808C416F156C0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes5.45Due2016Member_717610C8D03A2D287B2808C416F156C0" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes1.50Due2016Member" xlink:label="loc_hsy_Notes1.50Due2016Member_327D3C5A81423CF7D81B08C416F19C89" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes1.50Due2016Member_327D3C5A81423CF7D81B08C416F19C89" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes1.60Due2018Member" xlink:label="loc_hsy_Notes1.60Due2018Member_7FB37435AEC384CAD64508C416F1C9B5" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes1.60Due2018Member_7FB37435AEC384CAD64508C416F1C9B5" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes4.125Due2020Member" xlink:label="loc_hsy_Notes4.125Due2020Member_298130634012DEAA019A08C416F189E6" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes4.125Due2020Member_298130634012DEAA019A08C416F189E6" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Debentures8.8Due2021Member" xlink:label="loc_hsy_Debentures8.8Due2021Member_0A6F741860D1A19D902808C416F1736F" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Debentures8.8Due2021Member_0A6F741860D1A19D902808C416F1736F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes2.625Due2023Member" xlink:label="loc_hsy_Notes2.625Due2023Member_5C13D6E0D0E6DE014DDB08C416F19858" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes2.625Due2023Member_5C13D6E0D0E6DE014DDB08C416F19858" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.20Due2025Member" xlink:label="loc_hsy_Notes3.20Due2025Member_1A564BFD22BD343901A708C416F1EA96" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes3.20Due2025Member_1A564BFD22BD343901A708C416F1EA96" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes2.30Due2026Member" xlink:label="loc_hsy_Notes2.30Due2026Member_102A1571FF5BD86FDEA408C416F1C808" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes2.30Due2026Member_102A1571FF5BD86FDEA408C416F1C808" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Debentures7.2Due2027Member" xlink:label="loc_hsy_Debentures7.2Due2027Member_D25927A88E641AEBAC9A08C416F19F91" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Debentures7.2Due2027Member_D25927A88E641AEBAC9A08C416F19F91" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.375Due2046Member" xlink:label="loc_hsy_Notes3.375Due2046Member_50E7AE42BE0F26E4BA4A08C416F14AD6" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FDD663F2FAFE9E2581DD08C416F18710" xlink:to="loc_hsy_Notes3.375Due2046Member_50E7AE42BE0F26E4BA4A08C416F14AD6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_A2021DBFAF9428F440A608C416F13F02" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_C6A85EB2174E25BCA51B08C416F1D66A" xlink:to="loc_us-gaap_LongTermDebt_A2021DBFAF9428F440A608C416F13F02" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet" xlink:label="loc_hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet_78D14762E1E17CB1749E08C416F1ED57" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_C6A85EB2174E25BCA51B08C416F1D66A" xlink:to="loc_hsy_DebtInstrumentImpactofDerivativesUnamortizedDiscountPremiumandDebtIssuanceCostsNet_78D14762E1E17CB1749E08C416F1ED57" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtCurrent" xlink:label="loc_us-gaap_LongTermDebtCurrent_3EFCE4233272B10AEF7708C416F1D4E1" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_C6A85EB2174E25BCA51B08C416F1D66A" xlink:to="loc_us-gaap_LongTermDebtCurrent_3EFCE4233272B10AEF7708C416F1D4E1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebtNoncurrent" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_91323CE342906BAE79A008C416F19F5D" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_C6A85EB2174E25BCA51B08C416F1D66A" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_91323CE342906BAE79A008C416F19F5D" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityLineItems" xlink:label="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityTable" xlink:label="loc_us-gaap_LineOfCreditFacilityTable_924AD1C7A2D2143CB8AE08C417D7767F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_us-gaap_LineOfCreditFacilityTable_924AD1C7A2D2143CB8AE08C417D7767F" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_E54719A23DD9A84DE2DA08C417D73FAF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_924AD1C7A2D2143CB8AE08C417D7767F" xlink:to="loc_us-gaap_DebtInstrumentAxis_E54719A23DD9A84DE2DA08C417D73FAF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_2DE1A9F2FE98683432C108C417D76D2E_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_E54719A23DD9A84DE2DA08C417D73FAF" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_2DE1A9F2FE98683432C108C417D76D2E_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_2DE1A9F2FE98683432C108C417D76D2E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_E54719A23DD9A84DE2DA08C417D73FAF" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_2DE1A9F2FE98683432C108C417D76D2E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_590F7F6A0BFA72E0E98F08C417D7ABB3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_2DE1A9F2FE98683432C108C417D76D2E" xlink:to="loc_us-gaap_LineOfCreditMember_590F7F6A0BFA72E0E98F08C417D7ABB3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityAxis" xlink:label="loc_us-gaap_CreditFacilityAxis_93B6AECCC809DAAF4AFD08C417D7C1AA" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_924AD1C7A2D2143CB8AE08C417D7767F" xlink:to="loc_us-gaap_CreditFacilityAxis_93B6AECCC809DAAF4AFD08C417D7C1AA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_1739C37DF1EB2CC11B0408C417D78CA8_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_93B6AECCC809DAAF4AFD08C417D7C1AA" xlink:to="loc_us-gaap_CreditFacilityDomain_1739C37DF1EB2CC11B0408C417D78CA8_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_1739C37DF1EB2CC11B0408C417D78CA8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_93B6AECCC809DAAF4AFD08C417D7C1AA" xlink:to="loc_us-gaap_CreditFacilityDomain_1739C37DF1EB2CC11B0408C417D78CA8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevolvingCreditFacilityMember" xlink:label="loc_us-gaap_RevolvingCreditFacilityMember_720423646F4A1A5AC21008C417D7A4DE" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_1739C37DF1EB2CC11B0408C417D78CA8" xlink:to="loc_us-gaap_RevolvingCreditFacilityMember_720423646F4A1A5AC21008C417D7A4DE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_75951E79A45CFC473CE308C417D70445" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_924AD1C7A2D2143CB8AE08C417D7767F" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_75951E79A45CFC473CE308C417D70445" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_14A5344563736893B51308C417D7A6D9_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_75951E79A45CFC473CE308C417D70445" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_14A5344563736893B51308C417D7A6D9_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_14A5344563736893B51308C417D7A6D9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_75951E79A45CFC473CE308C417D70445" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_14A5344563736893B51308C417D7A6D9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_22972D22F8FF9D09392308C417D73D3B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_14A5344563736893B51308C417D7A6D9" xlink:to="loc_us-gaap_LineOfCreditMember_22972D22F8FF9D09392308C417D73D3B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ForeignLineOfCreditMember" xlink:label="loc_us-gaap_ForeignLineOfCreditMember_8980021A53727FDF9BC308C417D73D65" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_14A5344563736893B51308C417D7A6D9" xlink:to="loc_us-gaap_ForeignLineOfCreditMember_8980021A53727FDF9BC308C417D73D65" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShortTermDebtTypeAxis" xlink:label="loc_us-gaap_ShortTermDebtTypeAxis_510B5A34A199EBBABB4708C417D707EF" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_LineOfCreditFacilityTable_924AD1C7A2D2143CB8AE08C417D7767F" xlink:to="loc_us-gaap_ShortTermDebtTypeAxis_510B5A34A199EBBABB4708C417D707EF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShortTermDebtTypeDomain" xlink:label="loc_us-gaap_ShortTermDebtTypeDomain_C2C211CCEDED618745B008C417D7BECB_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ShortTermDebtTypeAxis_510B5A34A199EBBABB4708C417D707EF" xlink:to="loc_us-gaap_ShortTermDebtTypeDomain_C2C211CCEDED618745B008C417D7BECB_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShortTermDebtTypeDomain" xlink:label="loc_us-gaap_ShortTermDebtTypeDomain_C2C211CCEDED618745B008C417D7BECB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ShortTermDebtTypeAxis_510B5A34A199EBBABB4708C417D707EF" xlink:to="loc_us-gaap_ShortTermDebtTypeDomain_C2C211CCEDED618745B008C417D7BECB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommercialPaperMember" xlink:label="loc_us-gaap_CommercialPaperMember_04F46C80C741151700EA08C417D7C1D7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShortTermDebtTypeDomain_C2C211CCEDED618745B008C417D7BECB" xlink:to="loc_us-gaap_CommercialPaperMember_04F46C80C741151700EA08C417D7C1D7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_59C2A704A32FF9D8D5F408C417D7AF2F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_59C2A704A32FF9D8D5F408C417D7AF2F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_LineOfCreditFacilityAccordionFeatureIncreaseLimit" xlink:label="loc_hsy_LineOfCreditFacilityAccordionFeatureIncreaseLimit_67E8D222EF6E05035D6E08C417D7A653" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_hsy_LineOfCreditFacilityAccordionFeatureIncreaseLimit_67E8D222EF6E05035D6E08C417D7A653" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum" xlink:label="loc_hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum_F99AAE23535C70EC24D508C417D75E8F" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_hsy_DebtInstrumentCovenantPretaxIncomeFromOperationsToConsolidatedInterestExpenseMinimum_F99AAE23535C70EC24D508C417D75E8F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LinesOfCreditCurrent" xlink:label="loc_us-gaap_LinesOfCreditCurrent_7E8FB192988463650F9308C417D7655A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_us-gaap_LinesOfCreditCurrent_7E8FB192988463650F9308C417D7655A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShortTermBorrowings" xlink:label="loc_us-gaap_ShortTermBorrowings_FA8CD80B9590BF50106308C417D747C7" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_us-gaap_ShortTermBorrowings_FA8CD80B9590BF50106308C417D747C7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShortTermDebtWeightedAverageInterestRate" xlink:label="loc_us-gaap_ShortTermDebtWeightedAverageInterestRate_ABB557C3992B16D428E008C417D70A2E" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_us-gaap_ShortTermDebtWeightedAverageInterestRate_ABB557C3992B16D428E008C417D70A2E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod_ABA1678C35FDAEAF051908C417E17127" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLineItems_59498BB8ED177855586108C417D746F9" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumAmountOutstandingDuringPeriod_ABA1678C35FDAEAF051908C417E17127" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_3554DFF1192250E71A6B08C4177351C6" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_25E6A4EB1C615F9DA94008C41773FC7C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_3554DFF1192250E71A6B08C4177351C6" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_25E6A4EB1C615F9DA94008C41773FC7C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_17B3014B43A4F2E9EB0E08C41773269A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_25E6A4EB1C615F9DA94008C41773FC7C" xlink:to="loc_us-gaap_AwardTypeAxis_17B3014B43A4F2E9EB0E08C41773269A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_053B83D8F5AEAC7AC41508C41773541D_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_17B3014B43A4F2E9EB0E08C41773269A" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_053B83D8F5AEAC7AC41508C41773541D_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_053B83D8F5AEAC7AC41508C41773541D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_17B3014B43A4F2E9EB0E08C41773269A" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_053B83D8F5AEAC7AC41508C41773541D" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_9B20CA0CF6B5A2E319FA08C41773BB44" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_053B83D8F5AEAC7AC41508C41773541D" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_9B20CA0CF6B5A2E319FA08C41773BB44" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_3554DFF1192250E71A6B08C4177351C6" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_E8B624DFEEF99AACA56008C4177375E1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_E8B624DFEEF99AACA56008C4177375E1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_3EDB1379DDD6FC4B39ED08C4177321B6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_3EDB1379DDD6FC4B39ED08C4177321B6" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange_6B124660B9ABA78B926B08C417739C07" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChange_6B124660B9ABA78B926B08C417739C07" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_4902422585A4FAB127A008C417739FD5" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_4902422585A4FAB127A008C417739FD5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_93086987DD8787408E9108C41773A052" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNonOptionEquityInstrumentsOutstandingRollForward_EA324BF70E92C666C82708C4177319CB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_93086987DD8787408E9108C41773A052" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_3554DFF1192250E71A6B08C4177351C6" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_9B3A20900A2068E36A0608C4177331AF" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_9B3A20900A2068E36A0608C4177331AF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_331C61DB6613EC75C54A08C41773935C" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_331C61DB6613EC75C54A08C41773935C" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue_6A4050C309D0A0AC504C08C4177328FA" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceAssumptionChangeWeightedAverageGrantDateFairValue_6A4050C309D0A0AC504C08C4177328FA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_03AF1BB8E40F61DA9A1F08C41773BCB3" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_03AF1BB8E40F61DA9A1F08C41773BCB3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_03E51D663EBB07EBB1E908C41773CDB8" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_BAFBC0ED268F863A449A08C41773BF57" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_03E51D663EBB07EBB1E908C41773CDB8" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8A259A41245D95B151DF08C418C72894" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8A259A41245D95B151DF08C418C72894" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_3A5474006713F7AD6EBF08C418C719B2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8A259A41245D95B151DF08C418C72894" xlink:to="loc_us-gaap_AwardTypeAxis_3A5474006713F7AD6EBF08C418C719B2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3F3B40884C0B1D5CC69308C418C7386E_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_3A5474006713F7AD6EBF08C418C719B2" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3F3B40884C0B1D5CC69308C418C7386E_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3F3B40884C0B1D5CC69308C418C7386E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_3A5474006713F7AD6EBF08C418C719B2" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3F3B40884C0B1D5CC69308C418C7386E" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember" xlink:label="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_F59C9FE729BAADEC88A408C418C722EC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_3F3B40884C0B1D5CC69308C418C7386E" xlink:to="loc_hsy_PerformanceSharesAndRestrictedStockUnitsRSUMember_F59C9FE729BAADEC88A408C418C722EC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_A91B8B64455159A529E508C418C7E09F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_A91B8B64455159A529E508C418C7E09F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_8FB20B8671D39B10A54708C418C7E4A5" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_8FB20B8671D39B10A54708C418C7E4A5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharePrice" xlink:label="loc_us-gaap_SharePrice_858516AB4F2DAF6CB4D308C418C7115B" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:to="loc_us-gaap_SharePrice_858516AB4F2DAF6CB4D308C418C7115B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_97CA57FFF5DFD31208B808C418C77E2A" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_97CA57FFF5DFD31208B808C418C77E2A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_8AEE404E992AEFF83A1C08C418C7A1B5" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_DB3687EC0EB9FEA7E71108C418C71B9E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_8AEE404E992AEFF83A1C08C418C7A1B5" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_1CC24D617F6A3902ADEF08C4183BB29E" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_1CC24D617F6A3902ADEF08C4183BB29E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_D4DA83A4276C3267D95908C4183BFF06" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeTable_1CC24D617F6A3902ADEF08C4183BB29E" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_D4DA83A4276C3267D95908C4183BFF06" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_D4DA83A4276C3267D95908C4183BFF06" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansByExercisePriceRangeAxis_D4DA83A4276C3267D95908C4183BFF06" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ExercisePriceRangeOneMember" xlink:label="loc_hsy_ExercisePriceRangeOneMember_1EEC61C51ACB180D4D9A08C4183BCAC3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8" xlink:to="loc_hsy_ExercisePriceRangeOneMember_1EEC61C51ACB180D4D9A08C4183BCAC3" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ExercisePriceRangeTwoMember" xlink:label="loc_hsy_ExercisePriceRangeTwoMember_F787642A06A1F86AE32308C4183BE5D6" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8" xlink:to="loc_hsy_ExercisePriceRangeTwoMember_F787642A06A1F86AE32308C4183BE5D6" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ExercisePriceRangeThreeMember" xlink:label="loc_hsy_ExercisePriceRangeThreeMember_9BAC4A18A00F44DC089708C4183B8686" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8" xlink:to="loc_hsy_ExercisePriceRangeThreeMember_9BAC4A18A00F44DC089708C4183B8686" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ExercisePriceRangeFourMember" xlink:label="loc_hsy_ExercisePriceRangeFourMember_23C317E013F175730FB308C4183BEBBE" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeDomain_E11FBA5C2258017EFCAF08C4183B4BF8" xlink:to="loc_hsy_ExercisePriceRangeFourMember_23C317E013F175730FB308C4183BEBBE" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit_DBF1128C2B803E04081608C4183BE503" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLowerRangeLimit_DBF1128C2B803E04081608C4183BE503" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit_EEF797878A614E28D60308C4183B00FA" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeUpperRangeLimit_EEF797878A614E28D60308C4183B00FA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions_53945BF07FD418E1806B08C4183B7D88" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfOutstandingOptions_53945BF07FD418E1806B08C4183B7D88" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2_7994F16FB06102A51F5A08C4183B44C4" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageRemainingContractualTerm2_7994F16FB06102A51F5A08C4183B44C4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1_55C130695BE3E779B75B08C4183BBD53" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeOutstandingOptionsWeightedAverageExercisePriceBeginningBalance1_55C130695BE3E779B75B08C4183BBD53" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions" xlink:label="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions_05EDC5DA55FE396A34F108C4183B3BC2" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeNumberOfExercisableOptions_05EDC5DA55FE396A34F108C4183B3BC2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1" xlink:label="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1_C3EA7BB235B4ED2A46D008C4183B9303" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeLineItems_5D42327883D5F9AA2CE008C4183BD07C" xlink:to="loc_us-gaap_SharebasedCompensationSharesAuthorizedUnderStockOptionPlansExercisePriceRangeExercisableOptionsWeightedAverageExercisePrice1_C3EA7BB235B4ED2A46D008C4183B9303" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable" xlink:label="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_48DCA13DADB010AA258B08C418BD3419" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_48DCA13DADB010AA258B08C418BD3419" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_FA18EA70F7BA7C904CF508C418BD0AA7" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_48DCA13DADB010AA258B08C418BD3419" xlink:to="loc_us-gaap_AwardTypeAxis_FA18EA70F7BA7C904CF508C418BD0AA7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_FA18EA70F7BA7C904CF508C418BD0AA7" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_FA18EA70F7BA7C904CF508C418BD0AA7" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeStockOptionMember" xlink:label="loc_us-gaap_EmployeeStockOptionMember_E8473C35BE7BCA88D84508C418BDA6D5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A" xlink:to="loc_us-gaap_EmployeeStockOptionMember_E8473C35BE7BCA88D84508C418BDA6D5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PerformanceSharesMember" xlink:label="loc_us-gaap_PerformanceSharesMember_C1CBC0D18B3BE467E47108C418BD4E9F" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A" xlink:to="loc_us-gaap_PerformanceSharesMember_C1CBC0D18B3BE467E47108C418BD4E9F" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_PerformanceStockUnitsandRestrictedStockUnitsMember" xlink:label="loc_hsy_PerformanceStockUnitsandRestrictedStockUnitsMember_53102C46481A59D5882608C418BDAA77" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_C56F4A02111888CDB6B208C418BD713A" xlink:to="loc_hsy_PerformanceStockUnitsandRestrictedStockUnitsMember_53102C46481A59D5882608C418BDAA77" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_2145C44348313651A9B808C418BD07B1" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_48DCA13DADB010AA258B08C418BD3419" xlink:to="loc_us-gaap_RangeAxis_2145C44348313651A9B808C418BD07B1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_0EB5CADA7A610FD46F7508C418BD0B99_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_2145C44348313651A9B808C418BD07B1" xlink:to="loc_us-gaap_RangeMember_0EB5CADA7A610FD46F7508C418BD0B99_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_0EB5CADA7A610FD46F7508C418BD0B99" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_2145C44348313651A9B808C418BD07B1" xlink:to="loc_us-gaap_RangeMember_0EB5CADA7A610FD46F7508C418BD0B99" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_7E09C7DEC02B9E585D8608C418BDB36C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_0EB5CADA7A610FD46F7508C418BD0B99" xlink:to="loc_us-gaap_MinimumMember_7E09C7DEC02B9E585D8608C418BDB36C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_BE2F833F7AEF8519E24A08C418BDC1D7" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_0EB5CADA7A610FD46F7508C418BD0B99" xlink:to="loc_us-gaap_MaximumMember_BE2F833F7AEF8519E24A08C418BDC1D7" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized_1958BA434A63F15CC6A008C418BDA6D5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized_1958BA434A63F15CC6A008C418BDA6D5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_1D7E0525129B86ED3E6D08C418BD4A48" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_1D7E0525129B86ED3E6D08C418BD4A48" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_A3EC335B1904176EA55708C418BD75F3" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_A3EC335B1904176EA55708C418BD75F3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod" xlink:label="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_D708D9EA61B95141DDD508C418BDC1ED" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_D708D9EA61B95141DDD508C418BDC1ED" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_950FC4924B445CFE182E08C418BD63BF" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_950FC4924B445CFE182E08C418BD63BF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_0472C9D4930B2B4444FB08C418BD279F" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_0472C9D4930B2B4444FB08C418BD279F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_B5AF1AC7E5DB1EBD90E008C418BD385A" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_B5AF1AC7E5DB1EBD90E008C418BD385A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions_DE20E8B920EF976B387408C418BD0477" xlink:type="locator"/>
<link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions_DE20E8B920EF976B387408C418BD0477" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage_9D1929733D1EE3671F2008C418BD09F7" xlink:type="locator"/>
<link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsPerformanceScorePercentage_9D1929733D1EE3671F2008C418BD09F7" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested" xlink:label="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested_202AC7B61AC3BE7795BF08C418BDD598" xlink:type="locator"/>
<link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_hsy_ShareBasedCompensationArrangementByShareBasedPaymentAwardIntrinsicValueOfShareBasedLiabilitiesPaidCombinedWithFairValueOfSharesVested_202AC7B61AC3BE7795BF08C418BDD598" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued" xlink:label="loc_us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued_EC7DA79DA7CD10E7299608C418BDEB0A" xlink:type="locator"/>
<link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_us-gaap_DeferredCompensationArrangementWithIndividualSharesIssued_EC7DA79DA7CD10E7299608C418BDEB0A" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_DeferredCompensationArrangementwithIndividualConversionBasis" xlink:label="loc_hsy_DeferredCompensationArrangementwithIndividualConversionBasis_CF0946A36B7B4473DF4808C418BD273F" xlink:type="locator"/>
<link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_AF68F302E5AF3FF9D5B308C418BD899D" xlink:to="loc_hsy_DeferredCompensationArrangementwithIndividualConversionBasis_CF0946A36B7B4473DF4808C418BD273F" 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/SubsequentEventsSubsequentEvents" xlink:type="extended"/>
<link:definitionLink xlink:role="http://www.hersheys.com/role/SubsequentEventsSubsequentEventsDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsequentEventLineItems" xlink:label="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsequentEventTable" xlink:label="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeAxis" xlink:label="loc_us-gaap_LongtermDebtTypeAxis_7CBC09E81F0C624DDBAE832A3145AD88" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_7CBC09E81F0C624DDBAE832A3145AD88" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_5B5E1D091DB84ADB7A18832A314FF1C9_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_7CBC09E81F0C624DDBAE832A3145AD88" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_5B5E1D091DB84ADB7A18832A314FF1C9_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongtermDebtTypeDomain" xlink:label="loc_us-gaap_LongtermDebtTypeDomain_5B5E1D091DB84ADB7A18832A314FF1C9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_7CBC09E81F0C624DDBAE832A3145AD88" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_5B5E1D091DB84ADB7A18832A314FF1C9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCorporateDebtSecuritiesMember" xlink:label="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_3B36BD6DB6BDA1A45277832A32E9F182" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_5B5E1D091DB84ADB7A18832A314FF1C9" xlink:to="loc_us-gaap_DomesticCorporateDebtSecuritiesMember_3B36BD6DB6BDA1A45277832A32E9F182" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsequentEventTypeAxis" xlink:label="loc_us-gaap_SubsequentEventTypeAxis_EA13E3A06459259384778317377A9F0D" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_SubsequentEventTypeAxis_EA13E3A06459259384778317377A9F0D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsequentEventTypeDomain" xlink:label="loc_us-gaap_SubsequentEventTypeDomain_6645925E873D0FA0511C8317377A27FB_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsequentEventTypeAxis_EA13E3A06459259384778317377A9F0D" xlink:to="loc_us-gaap_SubsequentEventTypeDomain_6645925E873D0FA0511C8317377A27FB_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsequentEventTypeDomain" xlink:label="loc_us-gaap_SubsequentEventTypeDomain_6645925E873D0FA0511C8317377A27FB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsequentEventTypeAxis_EA13E3A06459259384778317377A9F0D" xlink:to="loc_us-gaap_SubsequentEventTypeDomain_6645925E873D0FA0511C8317377A27FB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubsequentEventMember" xlink:label="loc_us-gaap_SubsequentEventMember_AB0244E3AAA31C9F4C468317377A664F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventTypeDomain_6645925E873D0FA0511C8317377A27FB" xlink:to="loc_us-gaap_SubsequentEventMember_AB0244E3AAA31C9F4C468317377A664F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_2D2197198FE430EA58178317377A91F5" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_2D2197198FE430EA58178317377A91F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_FC0B31D8E4F50DAC377B8317377AA532_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_2D2197198FE430EA58178317377A91F5" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_FC0B31D8E4F50DAC377B8317377AA532_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_FC0B31D8E4F50DAC377B8317377AA532" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_2D2197198FE430EA58178317377A91F5" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_FC0B31D8E4F50DAC377B8317377AA532" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_AmplifySnackBrandsInc.Member" xlink:label="loc_hsy_AmplifySnackBrandsInc.Member_69F9F8371868530A6C648317377A1AE3" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_FC0B31D8E4F50DAC377B8317377AA532" xlink:to="loc_hsy_AmplifySnackBrandsInc.Member_69F9F8371868530A6C648317377A1AE3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_A690047073CC6E6F5F938317377A6C66" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_RangeAxis_A690047073CC6E6F5F938317377A6C66" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_B41FE6ACE37BFB531CA98317377A49B0_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_A690047073CC6E6F5F938317377A6C66" xlink:to="loc_us-gaap_RangeMember_B41FE6ACE37BFB531CA98317377A49B0_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_B41FE6ACE37BFB531CA98317377A49B0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_A690047073CC6E6F5F938317377A6C66" xlink:to="loc_us-gaap_RangeMember_B41FE6ACE37BFB531CA98317377A49B0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_7792568D9B758ED04E0F8317377A6736" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_B41FE6ACE37BFB531CA98317377A49B0" xlink:to="loc_us-gaap_MinimumMember_7792568D9B758ED04E0F8317377A6736" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_53F7BD6A8A1AA4DCEC458317377ACABC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_B41FE6ACE37BFB531CA98317377A49B0" xlink:to="loc_us-gaap_MaximumMember_53F7BD6A8A1AA4DCEC458317377ACABC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityAxis" xlink:label="loc_us-gaap_CreditFacilityAxis_0A36B7F4B85381A20C288317377A23B6" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_CreditFacilityAxis_0A36B7F4B85381A20C288317377A23B6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_44944F6336547D7E81DE8317377AA3F5_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_0A36B7F4B85381A20C288317377A23B6" xlink:to="loc_us-gaap_CreditFacilityDomain_44944F6336547D7E81DE8317377AA3F5_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditFacilityDomain" xlink:label="loc_us-gaap_CreditFacilityDomain_44944F6336547D7E81DE8317377AA3F5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_0A36B7F4B85381A20C288317377A23B6" xlink:to="loc_us-gaap_CreditFacilityDomain_44944F6336547D7E81DE8317377AA3F5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevolvingCreditFacilityMember" xlink:label="loc_us-gaap_RevolvingCreditFacilityMember_9FFFE853856BAD21CFBA8317377A3522" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_44944F6336547D7E81DE8317377AA3F5" xlink:to="loc_us-gaap_RevolvingCreditFacilityMember_9FFFE853856BAD21CFBA8317377A3522" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentAxis" xlink:label="loc_us-gaap_DebtInstrumentAxis_EF28FCE668B49E43A39A8317377AE4B8" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_DebtInstrumentAxis_EF28FCE668B49E43A39A8317377AE4B8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_EF28FCE668B49E43A39A8317377AE4B8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentNameDomain" xlink:label="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_EF28FCE668B49E43A39A8317377AE4B8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditMember" xlink:label="loc_us-gaap_LineOfCreditMember_782F78DCEDF6F492679F8317377A62F4" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76" xlink:to="loc_us-gaap_LineOfCreditMember_782F78DCEDF6F492679F8317377A62F4" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes2.90Due2020Domain" xlink:label="loc_hsy_Notes2.90Due2020Domain_F8372D9FBD1BF47E06D9832A32713ABD" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76" xlink:to="loc_hsy_Notes2.90Due2020Domain_F8372D9FBD1BF47E06D9832A32713ABD" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.10Due2021Domain" xlink:label="loc_hsy_Notes3.10Due2021Domain_CDD95C4D42AC07440231832AE88789B0" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76" xlink:to="loc_hsy_Notes3.10Due2021Domain_CDD95C4D42AC07440231832AE88789B0" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_Notes3.375Due2023Domain" xlink:label="loc_hsy_Notes3.375Due2023Domain_9A1E540A2583E8B48B0C832E49D5B3F6" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_B3F31F8FB1DF27C1FC178317377A5B76" xlink:to="loc_hsy_Notes3.375Due2023Domain_9A1E540A2583E8B48B0C832E49D5B3F6" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_F282FEED44AB0F60C8C68317377A6158" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_SubsequentEventTable_5F626F7C077D878F64A08317377AA305" xlink:to="loc_us-gaap_StatementScenarioAxis_F282FEED44AB0F60C8C68317377A6158" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_95E371FFB7D442DA8C7C8317377A9DE2_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_F282FEED44AB0F60C8C68317377A6158" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_95E371FFB7D442DA8C7C8317377A9DE2_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioUnspecifiedDomain" xlink:label="loc_us-gaap_ScenarioUnspecifiedDomain_95E371FFB7D442DA8C7C8317377A9DE2" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_F282FEED44AB0F60C8C68317377A6158" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_95E371FFB7D442DA8C7C8317377A9DE2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioForecastMember" xlink:label="loc_us-gaap_ScenarioForecastMember_F67798C748C0986948538317377AE65B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_95E371FFB7D442DA8C7C8317377A9DE2" xlink:to="loc_us-gaap_ScenarioForecastMember_F67798C748C0986948538317377AE65B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity" xlink:label="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_60639E709A71FC63AC828317377AF6B1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_60639E709A71FC63AC828317377AF6B1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueNet" xlink:label="loc_us-gaap_SalesRevenueNet_8E1C4A3E19E353558CF98317377AABE3" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_SalesRevenueNet_8E1C4A3E19E353558CF98317377AABE3" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationConsiderationTransferred1" xlink:label="loc_us-gaap_BusinessCombinationConsiderationTransferred1_A766E8E30FBED2CE253B8317377A32E9" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_BusinessCombinationConsiderationTransferred1_A766E8E30FBED2CE253B8317377A32E9" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_BusinessCombinationConsiderationTransferredPerShareofCommonStock" xlink:label="loc_hsy_BusinessCombinationConsiderationTransferredPerShareofCommonStock_C2BAB44F9C450ABB25F98317377A8784" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_hsy_BusinessCombinationConsiderationTransferredPerShareofCommonStock_C2BAB44F9C450ABB25F98317377A8784" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilitiesLongTermDebt" xlink:label="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilitiesLongTermDebt_7DEC57204F41B2C3E8E58317377A735C" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_BusinessCombinationRecognizedIdentifiableAssetsAcquiredAndLiabilitiesAssumedNoncurrentLiabilitiesLongTermDebt_7DEC57204F41B2C3E8E58317377A735C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermDebt" xlink:label="loc_us-gaap_LongTermDebt_269B565CE80293E67C63832A30C3C572" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_LongTermDebt_269B565CE80293E67C63832A30C3C572" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentInterestRateStatedPercentage" xlink:label="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_02183C02A308146C88D0832AB6B55382" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventLineItems_8502C0E801FFF63473CD8317377A21DC" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_02183C02A308146C88D0832AB6B55382" xlink:type="arc"/>
</link:definitionLink>
<link:definitionLink xlink:role="http://www.hersheys.com/role/SubsequentEventsSubsequentEventsTables" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EntityWideRevenueMajorCustomerLineItems" xlink:label="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_CA12CC4E700436132A8F08C417057316" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable" xlink:label="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_294B8A0EF54C27EA37E808C4170513A0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_CA12CC4E700436132A8F08C417057316" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_294B8A0EF54C27EA37E808C4170513A0" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MajorCustomersAxis" xlink:label="loc_us-gaap_MajorCustomersAxis_BF41FC65C83F02D5188808C41705E202" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_294B8A0EF54C27EA37E808C4170513A0" xlink:to="loc_us-gaap_MajorCustomersAxis_BF41FC65C83F02D5188808C41705E202" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NameOfMajorCustomerDomain" xlink:label="loc_us-gaap_NameOfMajorCustomerDomain_E8BA58A8F62516B7644C08C4170539BC_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_MajorCustomersAxis_BF41FC65C83F02D5188808C41705E202" xlink:to="loc_us-gaap_NameOfMajorCustomerDomain_E8BA58A8F62516B7644C08C4170539BC_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NameOfMajorCustomerDomain" xlink:label="loc_us-gaap_NameOfMajorCustomerDomain_E8BA58A8F62516B7644C08C4170539BC" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_MajorCustomersAxis_BF41FC65C83F02D5188808C41705E202" xlink:to="loc_us-gaap_NameOfMajorCustomerDomain_E8BA58A8F62516B7644C08C4170539BC" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_McLaneCompanyInc.Member" xlink:label="loc_hsy_McLaneCompanyInc.Member_2D13F97938DFC784B44808C41705C782" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NameOfMajorCustomerDomain_E8BA58A8F62516B7644C08C4170539BC" xlink:to="loc_hsy_McLaneCompanyInc.Member_2D13F97938DFC784B44808C41705C782" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_TargetCorporationMember" xlink:label="loc_hsy_TargetCorporationMember_EB8780BA9DE264EDB19708C4170582BC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NameOfMajorCustomerDomain_E8BA58A8F62516B7644C08C4170539BC" xlink:to="loc_hsy_TargetCorporationMember_EB8780BA9DE264EDB19708C4170582BC" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_804D6622347E8EC48F8608C4170543DA" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_294B8A0EF54C27EA37E808C4170513A0" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_804D6622347E8EC48F8608C4170543DA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_0B7166F76F0FBCFC74D508C417058C9B_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_804D6622347E8EC48F8608C4170543DA" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_0B7166F76F0FBCFC74D508C417058C9B_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_0B7166F76F0FBCFC74D508C417058C9B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_804D6622347E8EC48F8608C4170543DA" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_0B7166F76F0FBCFC74D508C417058C9B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CustomerConcentrationRiskMember" xlink:label="loc_us-gaap_CustomerConcentrationRiskMember_1BF18811A639B1BF038708C417051DAB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_0B7166F76F0FBCFC74D508C417058C9B" xlink:to="loc_us-gaap_CustomerConcentrationRiskMember_1BF18811A639B1BF038708C417051DAB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_DCC96E158D18B79A3E5408C41705A1CB" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_294B8A0EF54C27EA37E808C4170513A0" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_DCC96E158D18B79A3E5408C41705A1CB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_21080721E0DAE8955A0708C41705D77F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_DCC96E158D18B79A3E5408C41705A1CB" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_21080721E0DAE8955A0708C41705D77F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_21080721E0DAE8955A0708C41705D77F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_DCC96E158D18B79A3E5408C41705A1CB" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_21080721E0DAE8955A0708C41705D77F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountsReceivableMember" xlink:label="loc_us-gaap_AccountsReceivableMember_96BAD93AAFF20416891C08C41705CD2A" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_21080721E0DAE8955A0708C41705D77F" xlink:to="loc_us-gaap_AccountsReceivableMember_96BAD93AAFF20416891C08C41705CD2A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_03280C49642EF0773E1908C41705D26B" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_CA12CC4E700436132A8F08C417057316" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_03280C49642EF0773E1908C41705D26B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent" xlink:label="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_E1ECDDBEDAB2D01A862208C41705ABCC" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_CA12CC4E700436132A8F08C417057316" xlink:to="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_E1ECDDBEDAB2D01A862208C41705ABCC" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_75E699B3CBA938EC6D5708C419021C81" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_599DADFA5A7257BF220708C419019A85" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_75E699B3CBA938EC6D5708C419021C81" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_599DADFA5A7257BF220708C419019A85" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_99E7679190AE1FD53E8108C419019874" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_599DADFA5A7257BF220708C419019A85" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_99E7679190AE1FD53E8108C419019874" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_4AB9CF369C21AAAD4AA008C41901B53F_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_99E7679190AE1FD53E8108C419019874" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_4AB9CF369C21AAAD4AA008C41901B53F_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_4AB9CF369C21AAAD4AA008C41901B53F" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_99E7679190AE1FD53E8108C419019874" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_4AB9CF369C21AAAD4AA008C41901B53F" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SoftwareAndSoftwareDevelopmentCostsMember" xlink:label="loc_us-gaap_SoftwareAndSoftwareDevelopmentCostsMember_457174A1652722E2D22708C419028D0D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_4AB9CF369C21AAAD4AA008C41901B53F" xlink:to="loc_us-gaap_SoftwareAndSoftwareDevelopmentCostsMember_457174A1652722E2D22708C419028D0D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_D1F0B330A12150A16DF608C41902A51A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_599DADFA5A7257BF220708C419019A85" xlink:to="loc_us-gaap_RangeAxis_D1F0B330A12150A16DF608C41902A51A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_A69CEE7DC3006AFE1ACF08C4190265F9_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_D1F0B330A12150A16DF608C41902A51A" xlink:to="loc_us-gaap_RangeMember_A69CEE7DC3006AFE1ACF08C4190265F9_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_A69CEE7DC3006AFE1ACF08C4190265F9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_D1F0B330A12150A16DF608C41902A51A" xlink:to="loc_us-gaap_RangeMember_A69CEE7DC3006AFE1ACF08C4190265F9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_6D2169E71B90BE376B2F08C4190290B4" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_A69CEE7DC3006AFE1ACF08C4190265F9" xlink:to="loc_us-gaap_MinimumMember_6D2169E71B90BE376B2F08C4190290B4" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_8B7F1EAF9B3AB01177E008C419020DF1" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_A69CEE7DC3006AFE1ACF08C4190265F9" xlink:to="loc_us-gaap_MaximumMember_8B7F1EAF9B3AB01177E008C419020DF1" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CapitalizedComputerSoftwareNet" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareNet_A9B1C6C2168C0EEC0D9B08C419024B01" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_75E699B3CBA938EC6D5708C419021C81" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareNet_A9B1C6C2168C0EEC0D9B08C419024B01" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_6245A2C8DE761F46C97408C419032DC2" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_75E699B3CBA938EC6D5708C419021C81" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_6245A2C8DE761F46C97408C419032DC2" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization" xlink:label="loc_us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization_40F76526C4F27579838208C419036CCE" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_75E699B3CBA938EC6D5708C419021C81" xlink:to="loc_us-gaap_CapitalizedComputerSoftwareAccumulatedAmortization_40F76526C4F27579838208C419036CCE" 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/SummaryOfSignificantAccountingPoliciesGoodwillAndOtherIntangibleAssetsDetails" xlink:type="extended">
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_CD0DA9CE68DDCFA7342D08C4176981CE" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_EB53913503F202D5F89E08C4175FFFD9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_CD0DA9CE68DDCFA7342D08C4176981CE" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_EB53913503F202D5F89E08C4175FFFD9" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_12E895E07BAE3FA939CF08C4175F3A4D" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_EB53913503F202D5F89E08C4175FFFD9" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_12E895E07BAE3FA939CF08C4175F3A4D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_12E895E07BAE3FA939CF08C4175F3A4D" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_12E895E07BAE3FA939CF08C4175F3A4D" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TrademarksMember" xlink:label="loc_us-gaap_TrademarksMember_71A6494AB02F9C85CF3008C4175F9162" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692" xlink:to="loc_us-gaap_TrademarksMember_71A6494AB02F9C85CF3008C4175F9162" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_66CB65A249913DD7166908C4175F4FEF" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692" xlink:to="loc_us-gaap_CustomerRelationshipsMember_66CB65A249913DD7166908C4175F4FEF" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PatentsMember" xlink:label="loc_us-gaap_PatentsMember_6359C171978F0D4CA55408C4175FD56C" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_2166CAA42E5248D0B0B808C4175F7692" xlink:to="loc_us-gaap_PatentsMember_6359C171978F0D4CA55408C4175FD56C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_1FA3ACAF26143F6EADB308C4176929C8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_CD0DA9CE68DDCFA7342D08C4176981CE" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_1FA3ACAF26143F6EADB308C4176929C8" xlink:type="arc"/>
</link:definitionLink>
<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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DC8151328882D4DCF7A08C4176968F3" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_964C0155A1B5880E3A7008C417690035" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DC8151328882D4DCF7A08C4176968F3" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_964C0155A1B5880E3A7008C417690035" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentByTypeAxis" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_05B985A0F7047ED1B2B408C417697B58" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_964C0155A1B5880E3A7008C417690035" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_05B985A0F7047ED1B2B408C417697B58" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_A48B8B5057EF6C1376E808C4176933B9_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_05B985A0F7047ED1B2B408C417697B58" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_A48B8B5057EF6C1376E808C4176933B9_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentTypeDomain" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_A48B8B5057EF6C1376E808C4176933B9" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_05B985A0F7047ED1B2B408C417697B58" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_A48B8B5057EF6C1376E808C4176933B9" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MachineryAndEquipmentMember" xlink:label="loc_us-gaap_MachineryAndEquipmentMember_307BD7F52C61C95E33B708C41769E506" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_A48B8B5057EF6C1376E808C4176933B9" xlink:to="loc_us-gaap_MachineryAndEquipmentMember_307BD7F52C61C95E33B708C41769E506" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BuildingAndBuildingImprovementsMember" xlink:label="loc_us-gaap_BuildingAndBuildingImprovementsMember_5D37E0F2E3C6A05FA2A208C41769377E" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_A48B8B5057EF6C1376E808C4176933B9" xlink:to="loc_us-gaap_BuildingAndBuildingImprovementsMember_5D37E0F2E3C6A05FA2A208C41769377E" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_B2E572D67915632F20B408C41769F485" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_964C0155A1B5880E3A7008C417690035" xlink:to="loc_us-gaap_RangeAxis_B2E572D67915632F20B408C41769F485" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_017CD45F845363A5D6BB08C417691ADD_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_B2E572D67915632F20B408C41769F485" xlink:to="loc_us-gaap_RangeMember_017CD45F845363A5D6BB08C417691ADD_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeMember" xlink:label="loc_us-gaap_RangeMember_017CD45F845363A5D6BB08C417691ADD" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_B2E572D67915632F20B408C41769F485" xlink:to="loc_us-gaap_RangeMember_017CD45F845363A5D6BB08C417691ADD" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinimumMember" xlink:label="loc_us-gaap_MinimumMember_FC57C344552998D92DEB08C4176957F8" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_017CD45F845363A5D6BB08C417691ADD" xlink:to="loc_us-gaap_MinimumMember_FC57C344552998D92DEB08C4176957F8" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MaximumMember" xlink:label="loc_us-gaap_MaximumMember_3F0AE599901C0B06CBC408C41769ACEB" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_017CD45F845363A5D6BB08C417691ADD" xlink:to="loc_us-gaap_MaximumMember_3F0AE599901C0B06CBC408C41769ACEB" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_F45E6D41724DB429350308C41769C1CB" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DC8151328882D4DCF7A08C4176968F3" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_F45E6D41724DB429350308C41769C1CB" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_CapitalLeasedAssetsNet" xlink:label="loc_hsy_CapitalLeasedAssetsNet_DD7B8522B31EE1EDA4F408C417699B1A" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DC8151328882D4DCF7A08C4176968F3" xlink:to="loc_hsy_CapitalLeasedAssetsNet_DD7B8522B31EE1EDA4F408C417699B1A" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Depreciation" xlink:label="loc_us-gaap_Depreciation_5C2CC9C70456A371DE6408C41769713F" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DC8151328882D4DCF7A08C4176968F3" xlink:to="loc_us-gaap_Depreciation_5C2CC9C70456A371DE6408C41769713F" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems" xlink:label="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable" xlink:label="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_FE4365D07A9A3ED564BC835FA614A2D0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_FE4365D07A9A3ED564BC835FA614A2D0" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdjustmentsForNewAccountingPronouncementsAxis" xlink:label="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_67AD6EE07A03A11F5408835FA61476ED" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleTable_FE4365D07A9A3ED564BC835FA614A2D0" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_67AD6EE07A03A11F5408835FA61476ED" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_29409CEDDF5EEB89DE04835FA6149490_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_67AD6EE07A03A11F5408835FA61476ED" xlink:to="loc_us-gaap_TypeOfAdoptionMember_29409CEDDF5EEB89DE04835FA6149490_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TypeOfAdoptionMember" xlink:label="loc_us-gaap_TypeOfAdoptionMember_29409CEDDF5EEB89DE04835FA6149490" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_67AD6EE07A03A11F5408835FA61476ED" xlink:to="loc_us-gaap_TypeOfAdoptionMember_29409CEDDF5EEB89DE04835FA6149490" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_AccountingStandardsUpdate201707Member" xlink:label="loc_hsy_AccountingStandardsUpdate201707Member_9DAC8F476F6FCC6DA5BB835FA6147AC1" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_29409CEDDF5EEB89DE04835FA6149490" xlink:to="loc_hsy_AccountingStandardsUpdate201707Member_9DAC8F476F6FCC6DA5BB835FA6147AC1" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_AccountingStandardsUpdate201609ExcessTaxBenefitComponentMember" xlink:label="loc_hsy_AccountingStandardsUpdate201609ExcessTaxBenefitComponentMember_3887652596167DBBAC72835FA6143050" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_29409CEDDF5EEB89DE04835FA6149490" xlink:to="loc_hsy_AccountingStandardsUpdate201609ExcessTaxBenefitComponentMember_3887652596167DBBAC72835FA6143050" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostOfGoodsSold" xlink:label="loc_us-gaap_CostOfGoodsSold_4847C2C93B5D718FEA99835FA6149497" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_us-gaap_CostOfGoodsSold_4847C2C93B5D718FEA99835FA6149497" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_EffectiveIncomeTaxRateReconciliationSharebasedCompensationExcessTaxBenefitAmount" xlink:label="loc_hsy_EffectiveIncomeTaxRateReconciliationSharebasedCompensationExcessTaxBenefitAmount_2BFF7EBEE976C7C603ED835FA6142A98" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_hsy_EffectiveIncomeTaxRateReconciliationSharebasedCompensationExcessTaxBenefitAmount_2BFF7EBEE976C7C603ED835FA6142A98" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_D250DB192D82DF9BF1B8835FA6145A09" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_D250DB192D82DF9BF1B8835FA6145A09" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_BF732710CC97C180B37C835FA614BD8D" xlink:type="locator"/>
<link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_BF732710CC97C180B37C835FA614BD8D" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingGeneralAndAdministrativeExpense" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_23BDEBFB3534DCCA7B50835FA6145E5B" xlink:type="locator"/>
<link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_23BDEBFB3534DCCA7B50835FA6145E5B" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_RestructuringChargesBusinessRealignment" xlink:label="loc_hsy_RestructuringChargesBusinessRealignment_D1D65EE6134C7C983931835FA6141591" xlink:type="locator"/>
<link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_hsy_RestructuringChargesBusinessRealignment_D1D65EE6134C7C983931835FA6141591" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_C4E9CF3F5B90CE5924C0835FA614F279" xlink:type="locator"/>
<link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NewAccountingPronouncementsOrChangeInAccountingPrincipleLineItems_E5913306D44F5F7618E5835FA61435AE" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_C4E9CF3F5B90CE5924C0835FA614F279" 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/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementLineItems" xlink:label="loc_us-gaap_StatementLineItems_A0C9910FC0A49C484BD008C41AA64D35" xlink:type="locator"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementTable" xlink:label="loc_us-gaap_StatementTable_8A979DCC24F8236F160A08C41A9CB91C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_A0C9910FC0A49C484BD008C41AA64D35" xlink:to="loc_us-gaap_StatementTable_8A979DCC24F8236F160A08C41A9CB91C" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByBenchmarkAxis" xlink:label="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_62458F7A179453B252D008C41A9C2EA0" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_8A979DCC24F8236F160A08C41A9CB91C" xlink:to="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_62458F7A179453B252D008C41A9C2EA0" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F17A0732A2123042435708C41A9C529C_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_62458F7A179453B252D008C41A9C2EA0" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F17A0732A2123042435708C41A9C529C_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskBenchmarkDomain" xlink:label="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F17A0732A2123042435708C41A9C529C" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByBenchmarkAxis_62458F7A179453B252D008C41A9C2EA0" xlink:to="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F17A0732A2123042435708C41A9C529C" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueGoodsNetMember" xlink:label="loc_us-gaap_SalesRevenueGoodsNetMember_B9AE0B2E9D087EF63EC708C41AA69339" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskBenchmarkDomain_F17A0732A2123042435708C41A9C529C" xlink:to="loc_us-gaap_SalesRevenueGoodsNetMember_B9AE0B2E9D087EF63EC708C41AA69339" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskByTypeAxis" xlink:label="loc_us-gaap_ConcentrationRiskByTypeAxis_7E10BD6B632617DB730508C41AA6D54B" xlink:type="locator"/>
<link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_8A979DCC24F8236F160A08C41A9CB91C" xlink:to="loc_us-gaap_ConcentrationRiskByTypeAxis_7E10BD6B632617DB730508C41AA6D54B" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_69429900534A33CD062B08C41AA64AAA_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_7E10BD6B632617DB730508C41AA6D54B" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_69429900534A33CD062B08C41AA64AAA_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskTypeDomain" xlink:label="loc_us-gaap_ConcentrationRiskTypeDomain_69429900534A33CD062B08C41AA64AAA" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ConcentrationRiskByTypeAxis_7E10BD6B632617DB730508C41AA6D54B" xlink:to="loc_us-gaap_ConcentrationRiskTypeDomain_69429900534A33CD062B08C41AA64AAA" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CustomerConcentrationRiskMember" xlink:label="loc_us-gaap_CustomerConcentrationRiskMember_45B488D7CBB42775908608C41AA6BBD5" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ConcentrationRiskTypeDomain_69429900534A33CD062B08C41AA64AAA" xlink:to="loc_us-gaap_CustomerConcentrationRiskMember_45B488D7CBB42775908608C41AA6BBD5" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MajorCustomersAxis" xlink:label="loc_us-gaap_MajorCustomersAxis_940D1B4C0018E193273308C41AA65F79" xlink:type="locator"/>
<link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_8A979DCC24F8236F160A08C41A9CB91C" xlink:to="loc_us-gaap_MajorCustomersAxis_940D1B4C0018E193273308C41AA65F79" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NameOfMajorCustomerDomain" xlink:label="loc_us-gaap_NameOfMajorCustomerDomain_40F0D8E2E02C5C78CF6208C41AA61F00_default" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_MajorCustomersAxis_940D1B4C0018E193273308C41AA65F79" xlink:to="loc_us-gaap_NameOfMajorCustomerDomain_40F0D8E2E02C5C78CF6208C41AA61F00_default" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NameOfMajorCustomerDomain" xlink:label="loc_us-gaap_NameOfMajorCustomerDomain_40F0D8E2E02C5C78CF6208C41AA61F00" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_MajorCustomersAxis_940D1B4C0018E193273308C41AA65F79" xlink:to="loc_us-gaap_NameOfMajorCustomerDomain_40F0D8E2E02C5C78CF6208C41AA61F00" xlink:type="arc"/>
<link:loc xlink:href="hsy-20180525.xsd#hsy_McLaneCompanyInc.Member" xlink:label="loc_hsy_McLaneCompanyInc.Member_5BD314ED145D10107D0508C41AA6C735" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NameOfMajorCustomerDomain_40F0D8E2E02C5C78CF6208C41AA61F00" xlink:to="loc_hsy_McLaneCompanyInc.Member_5BD314ED145D10107D0508C41AA6C735" xlink:type="arc"/>
<link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConcentrationRiskPercentage1" xlink:label="loc_us-gaap_ConcentrationRiskPercentage1_1AE3F239BF37715EB77C08C41AA61A72" xlink:type="locator"/>
<link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A0C9910FC0A49C484BD008C41AA64D35" xlink:to="loc_us-gaap_ConcentrationRiskPercentage1_1AE3F239BF37715EB77C08C41AA61A72" 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>

Top
Filing Submission 0000047111-18-000029   –   Alternative Formats (Word / Rich Text, HTML, Plain Text, et al.)

Copyright © 2024 Fran Finnegan & Company LLC – All Rights Reserved.
AboutPrivacyRedactionsHelp — Tue., Apr. 30, 1:49:13.2am ET