<?xml version="1.0" encoding="US-ASCII"?>
<!--XBRL Document Created with Wdesk from Workiva-->
<!-- -->
<link:linkbase xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd" xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xbrldt="http://xbrl.org/2005/xbrldt" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <link:roleRef roleURI="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilities" xlink:href="run-20180331.xsd#AccruedExpensesAndOtherLiabilities" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilitiesDetails" xlink:href="run-20180331.xsd#AccruedExpensesAndOtherLiabilitiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilitiesTables" xlink:href="run-20180331.xsd#AccruedExpensesAndOtherLiabilitiesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingencies" xlink:href="run-20180331.xsd#CommitmentsAndContingencies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesAdditionalInformationDetails" xlink:href="run-20180331.xsd#CommitmentsAndContingenciesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesComponentsOfLeaseExpenseDetails" xlink:href="run-20180331.xsd#CommitmentsAndContingenciesComponentsOfLeaseExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesFutureMinimumLeasePaymentsDetails" xlink:href="run-20180331.xsd#CommitmentsAndContingenciesFutureMinimumLeasePaymentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesOtherInformationRelatedToLeasesDetails" xlink:href="run-20180331.xsd#CommitmentsAndContingenciesOtherInformationRelatedToLeasesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesTables" xlink:href="run-20180331.xsd#CommitmentsAndContingenciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedBalanceSheetsParenthetical" xlink:href="run-20180331.xsd#ConsolidatedBalanceSheetsParenthetical" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedBalanceSheetsUnaudited" xlink:href="run-20180331.xsd#ConsolidatedBalanceSheetsUnaudited" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfCashFlowsUnaudited" xlink:href="run-20180331.xsd#ConsolidatedStatementsOfCashFlowsUnaudited" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfComprehensiveIncomeUnaudited" xlink:href="run-20180331.xsd#ConsolidatedStatementsOfComprehensiveIncomeUnaudited" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfOperationsUnaudited" xlink:href="run-20180331.xsd#ConsolidatedStatementsOfOperationsUnaudited" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Derivatives" xlink:href="run-20180331.xsd#Derivatives" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesAdditionalInformationDetails" xlink:href="run-20180331.xsd#DerivativesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesSummaryOfDerivativeInstrumentsDetails" xlink:href="run-20180331.xsd#DerivativesSummaryOfDerivativeInstrumentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesTables" xlink:href="run-20180331.xsd#DerivativesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DocumentAndEntityInformation" xlink:href="run-20180331.xsd#DocumentAndEntityInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/EarningsPerShare" xlink:href="run-20180331.xsd#EarningsPerShare" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/EarningsPerShareComputationOfBasicAndDilutedNetIncomePerShareDetails" xlink:href="run-20180331.xsd#EarningsPerShareComputationOfBasicAndDilutedNetIncomePerShareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/EarningsPerShareScheduleOfSharesExcludedFromComputationOfDilutedNetIncomePerShareDetails" xlink:href="run-20180331.xsd#EarningsPerShareScheduleOfSharesExcludedFromComputationOfDilutedNetIncomePerShareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/EarningsPerShareTables" xlink:href="run-20180331.xsd#EarningsPerShareTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurement" xlink:href="run-20180331.xsd#FairValueMeasurement" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurementScheduleOfCarryingValuesAndFairValuesOfDebtInstrumentsDetails" xlink:href="run-20180331.xsd#FairValueMeasurementScheduleOfCarryingValuesAndFairValuesOfDebtInstrumentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurementScheduleOfFairValueFinancialInstrumentsMeasuredOnRecurringBasisDetails" xlink:href="run-20180331.xsd#FairValueMeasurementScheduleOfFairValueFinancialInstrumentsMeasuredOnRecurringBasisDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurementTables" xlink:href="run-20180331.xsd#FairValueMeasurementTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxes" xlink:href="run-20180331.xsd#IncomeTaxes" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesAdditionalInformationDetails" xlink:href="run-20180331.xsd#IncomeTaxesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Indebtedness" xlink:href="run-20180331.xsd#Indebtedness" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessAdditionalInformationDetails" xlink:href="run-20180331.xsd#IndebtednessAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessScheduleOfDebtDetails" xlink:href="run-20180331.xsd#IndebtednessScheduleOfDebtDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessTables" xlink:href="run-20180331.xsd#IndebtednessTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Inventories" xlink:href="run-20180331.xsd#Inventories" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/InventoriesScheduleOfInventoriesDetails" xlink:href="run-20180331.xsd#InventoriesScheduleOfInventoriesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/InventoriesTables" xlink:href="run-20180331.xsd#InventoriesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Organization" xlink:href="run-20180331.xsd#Organization" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OrganizationAdditionalInformationDetails" xlink:href="run-20180331.xsd#OrganizationAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OtherAssets" xlink:href="run-20180331.xsd#OtherAssets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OtherAssetsDetails" xlink:href="run-20180331.xsd#OtherAssetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OtherAssetsTables" xlink:href="run-20180331.xsd#OtherAssetsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PassThroughFinancingObligations" xlink:href="run-20180331.xsd#PassThroughFinancingObligations" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PassThroughFinancingObligationsAdditionalInformationDetails" xlink:href="run-20180331.xsd#PassThroughFinancingObligationsAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsAndEquity" xlink:href="run-20180331.xsd#RedeemableNoncontrollingInterestsAndEquity" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsAndEquityScheduleOfChangesInRedeemableNoncontrollingInteresttotalStockholdersEquityAndNoncontrollingInterestsDetails" xlink:href="run-20180331.xsd#RedeemableNoncontrollingInterestsAndEquityScheduleOfChangesInRedeemableNoncontrollingInteresttotalStockholdersEquityAndNoncontrollingInterestsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsAndEquityTables" xlink:href="run-20180331.xsd#RedeemableNoncontrollingInterestsAndEquityTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNet" xlink:href="run-20180331.xsd#SolarEnergySystemsNet" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNetAdditionalInformationDetails" xlink:href="run-20180331.xsd#SolarEnergySystemsNetAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNetDetails" xlink:href="run-20180331.xsd#SolarEnergySystemsNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNetTables" xlink:href="run-20180331.xsd#SolarEnergySystemsNetTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensation" xlink:href="run-20180331.xsd#StockBasedCompensation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationAdditionalInformationDetails" xlink:href="run-20180331.xsd#StockBasedCompensationAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfActivityForAllRestrictedStockUnitsRsusDetails" xlink:href="run-20180331.xsd#StockBasedCompensationSummaryOfActivityForAllRestrictedStockUnitsRsusDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockBasedCompensationExpenseAdditionalDetailsDetails" xlink:href="run-20180331.xsd#StockBasedCompensationSummaryOfStockBasedCompensationExpenseAdditionalDetailsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockBasedCompensationExpenseDetails" xlink:href="run-20180331.xsd#StockBasedCompensationSummaryOfStockBasedCompensationExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockOptionActivityDetails" xlink:href="run-20180331.xsd#StockBasedCompensationSummaryOfStockOptionActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationTables" xlink:href="run-20180331.xsd#StockBasedCompensationTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPolicies" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesAccountsReceivableDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdditionalInformationDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842BalanceSheetDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842BalanceSheetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842CashFlowsDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842CashFlowsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842StatementOfOperationsDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842StatementOfOperationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesCashAndRestrictedCashDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesCashAndRestrictedCashDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesDeferredRevenueDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesDeferredRevenueDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesScheduleOfRevenuesFromExternalCustomersDetails" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesScheduleOfRevenuesFromExternalCustomersDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesTables" xlink:href="run-20180331.xsd#SummaryOfSignificantAccountingPoliciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/VieArrangements" xlink:href="run-20180331.xsd#VieArrangements" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/VieArrangementsCarryingAmountsAndClassificationOfViesAssetsAndLiabilitiesIncludedInConsolidatedBalanceSheetsDetails" xlink:href="run-20180331.xsd#VieArrangementsCarryingAmountsAndClassificationOfViesAssetsAndLiabilitiesIncludedInConsolidatedBalanceSheetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/VieArrangementsTables" xlink:href="run-20180331.xsd#VieArrangementsTables" 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.sunrun.com/role/AccruedExpensesAndOtherLiabilities" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilitiesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilitiesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CommitmentsAndContingencies" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CommitmentsAndContingenciesAdditionalInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherCommitmentsLineItems" xlink:label="loc_us-gaap_OtherCommitmentsLineItems_2A09073841C7619FB16541FF17AEBFAC" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherCommitmentsTable" xlink:label="loc_us-gaap_OtherCommitmentsTable_8BB3D7F8CC552B947AA341FF17ADD3D7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_2A09073841C7619FB16541FF17AEBFAC" xlink:to="loc_us-gaap_OtherCommitmentsTable_8BB3D7F8CC552B947AA341FF17ADD3D7" 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_CreditFacilityAxis" xlink:label="loc_us-gaap_CreditFacilityAxis_E454AF8CC8CDF05E069841FF17ADB6F1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_8BB3D7F8CC552B947AA341FF17ADD3D7" xlink:to="loc_us-gaap_CreditFacilityAxis_E454AF8CC8CDF05E069841FF17ADB6F1" 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_CA6C978480806ED5477D41FF17AD9842_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_E454AF8CC8CDF05E069841FF17ADB6F1" xlink:to="loc_us-gaap_CreditFacilityDomain_CA6C978480806ED5477D41FF17AD9842_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_CA6C978480806ED5477D41FF17AD9842" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_E454AF8CC8CDF05E069841FF17ADB6F1" xlink:to="loc_us-gaap_CreditFacilityDomain_CA6C978480806ED5477D41FF17AD9842" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LetterOfCreditMember" xlink:label="loc_us-gaap_LetterOfCreditMember_1591B7574C7F5FF74FD941FF17AE81A6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_CA6C978480806ED5477D41FF17AD9842" xlink:to="loc_us-gaap_LetterOfCreditMember_1591B7574C7F5FF74FD941FF17AE81A6" 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_F420C6662838917D78D141FF17AE4DE7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_8BB3D7F8CC552B947AA341FF17ADD3D7" xlink:to="loc_us-gaap_RangeAxis_F420C6662838917D78D141FF17AE4DE7" 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_1B9BD9C49576CB89F2A741FF17AE1A1C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_F420C6662838917D78D141FF17AE4DE7" xlink:to="loc_us-gaap_RangeMember_1B9BD9C49576CB89F2A741FF17AE1A1C_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_1B9BD9C49576CB89F2A741FF17AE1A1C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_F420C6662838917D78D141FF17AE4DE7" xlink:to="loc_us-gaap_RangeMember_1B9BD9C49576CB89F2A741FF17AE1A1C" 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_64F1C7DDC9552F1D5D6F41FF17AECA5E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_1B9BD9C49576CB89F2A741FF17AE1A1C" xlink:to="loc_us-gaap_MinimumMember_64F1C7DDC9552F1D5D6F41FF17AECA5E" 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_02CD901ABA55598CA08441FF17AE87A4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_1B9BD9C49576CB89F2A741FF17AE1A1C" xlink:to="loc_us-gaap_MaximumMember_02CD901ABA55598CA08441FF17AE87A4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LettersOfCreditOutstandingAmount" xlink:label="loc_us-gaap_LettersOfCreditOutstandingAmount_7D00F14488222F79B90C41FF17AE565E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_2A09073841C7619FB16541FF17AEBFAC" xlink:to="loc_us-gaap_LettersOfCreditOutstandingAmount_7D00F14488222F79B90C41FF17AE565E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityUnusedCapacityCommitmentFeePercentage" xlink:label="loc_us-gaap_LineOfCreditFacilityUnusedCapacityCommitmentFeePercentage_744F4E62F2416336B9B341FF17AE9EFD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_2A09073841C7619FB16541FF17AEBFAC" xlink:to="loc_us-gaap_LineOfCreditFacilityUnusedCapacityCommitmentFeePercentage_744F4E62F2416336B9B341FF17AE9EFD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LongTermPurchaseCommitmentAmount" xlink:label="loc_us-gaap_LongTermPurchaseCommitmentAmount_6CE022A81188CE5A9D6241FF17AE1BE6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_2A09073841C7619FB16541FF17AEBFAC" xlink:to="loc_us-gaap_LongTermPurchaseCommitmentAmount_6CE022A81188CE5A9D6241FF17AE1BE6" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CommitmentsAndContingenciesComponentsOfLeaseExpenseDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CommitmentsAndContingenciesFutureMinimumLeasePaymentsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CommitmentsAndContingenciesOtherInformationRelatedToLeasesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CommitmentsAndContingenciesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.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_E78B225A7515E93F2CF341FF16A72EC0" 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_47308F2DDD42AC8756E941FF16A6483A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_StatementTable_47308F2DDD42AC8756E941FF16A6483A" 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_VariableInterestEntitiesByClassificationOfEntityAxis" xlink:label="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_BE8182C6ECFC49778AA041FF16A67549" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_47308F2DDD42AC8756E941FF16A6483A" xlink:to="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_BE8182C6ECFC49778AA041FF16A67549" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassificationOfVariableInterestEntityDomain" xlink:label="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_EDFFB257887A7F95B88541FF16A77866_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_BE8182C6ECFC49778AA041FF16A67549" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_EDFFB257887A7F95B88541FF16A77866_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassificationOfVariableInterestEntityDomain" xlink:label="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_EDFFB257887A7F95B88541FF16A77866" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_BE8182C6ECFC49778AA041FF16A67549" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_EDFFB257887A7F95B88541FF16A77866" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableInterestEntityPrimaryBeneficiaryMember" xlink:label="loc_us-gaap_VariableInterestEntityPrimaryBeneficiaryMember_831856538DD357781E1941FF16A76AFB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_EDFFB257887A7F95B88541FF16A77866" xlink:to="loc_us-gaap_VariableInterestEntityPrimaryBeneficiaryMember_831856538DD357781E1941FF16A76AFB" 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_63F24AC512082003465D41FF16A7EB9B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_63F24AC512082003465D41FF16A7EB9B" 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_491B4E66F71491FD158D41FF16AC6C91" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_PreferredStockParOrStatedValuePerShare_491B4E66F71491FD158D41FF16AC6C91" 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_222190FBAA919BA963BD41FF16ACFD82" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_PreferredStockSharesAuthorized_222190FBAA919BA963BD41FF16ACFD82" 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_01E3F6FB131BEF7D755F41FF16AD38A8" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_PreferredStockSharesIssued_01E3F6FB131BEF7D755F41FF16AD38A8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockSharesOutstanding" xlink:label="loc_us-gaap_PreferredStockSharesOutstanding_02F044E9A453F95B0A8E41FF16AD3A65" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_PreferredStockSharesOutstanding_02F044E9A453F95B0A8E41FF16AD3A65" 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_F00E14384677D3B846F941FF16AD8DF4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_CommonStockParOrStatedValuePerShare_F00E14384677D3B846F941FF16AD8DF4" 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_BFAF6E57D7B193C80EEA41FF16ADB76A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_CommonStockSharesAuthorized_BFAF6E57D7B193C80EEA41FF16ADB76A" 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_44DC1853C2393F94C37141FF16ADEFE2" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_CommonStockSharesIssued_44DC1853C2393F94C37141FF16ADEFE2" 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_7F34B14348CEE31649CC41FF16AD6042" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_7F34B14348CEE31649CC41FF16AD6042" 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_B3DD0F6D24C6BE51D8DA41FF16AD9A0F" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_Assets_B3DD0F6D24C6BE51D8DA41FF16AD9A0F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_D85C3B18C3D95D2FF34341FF16AD0C15" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_D85C3B18C3D95D2FF34341FF16AD0C15" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Cash" xlink:label="loc_us-gaap_Cash_A1B92098FEE891A4084741FF16ADE3D0" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_Cash_A1B92098FEE891A4084741FF16ADE3D0" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RestrictedCashAtCarryingValue" xlink:label="loc_run_RestrictedCashAtCarryingValue_BDA8BA1274642552F33B41FF16AED93B" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_run_RestrictedCashAtCarryingValue_BDA8BA1274642552F33B41FF16AED93B" 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_6643AA79F5623EC7189E41FF16AE7AF5" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_6643AA79F5623EC7189E41FF16AE7AF5" 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_9291A92773A2755EE88E41FF16AEEE3F" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_9291A92773A2755EE88E41FF16AEEE3F" 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_7A7AC43F4578625E014241FF16AEEADC" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_7A7AC43F4578625E014241FF16AEEADC" 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_D473D8683E1362959BC641FF16AED517" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_Liabilities_D473D8683E1362959BC641FF16AED517" 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_8F430F01EF1E558EDEA141FF16AEFDCE" xlink:type="locator" />
    <link:definitionArc order="18" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_AccountsPayableCurrent_8F430F01EF1E558EDEA141FF16AEFDCE" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests" xlink:label="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_9B2EBFE9157D76639ADF41FF16AE1D6F" xlink:type="locator" />
    <link:definitionArc order="19" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_9B2EBFE9157D76639ADF41FF16AE1D6F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccruedLiabilitiesAndOtherLiabilities" xlink:label="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_DC6BCC1077A55FC3AD7241FF16AE914C" xlink:type="locator" />
    <link:definitionArc order="20" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_DC6BCC1077A55FC3AD7241FF16AE914C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenue" xlink:label="loc_us-gaap_DeferredRevenue_D3592AC91FF594A496DF41FF16AE5D67" xlink:type="locator" />
    <link:definitionArc order="21" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_DeferredRevenue_D3592AC91FF594A496DF41FF16AE5D67" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredGrants" xlink:label="loc_run_DeferredGrants_8198E93AADA75F7B2EAD41FF16AE05BE" xlink:type="locator" />
    <link:definitionArc order="22" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_run_DeferredGrants_8198E93AADA75F7B2EAD41FF16AE05BE" 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_4D28D772CD8B6E50834D41FF16AF03FE" xlink:type="locator" />
    <link:definitionArc order="23" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_E78B225A7515E93F2CF341FF16A72EC0" xlink:to="loc_us-gaap_LongTermDebt_4D28D772CD8B6E50834D41FF16AF03FE" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedBalanceSheetsUnaudited" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfCashFlowsUnaudited" 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_EB4FC20E6B59A86E465B461EA97B2C9A" 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_7884DEB713248A18E33B461EA979D9B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_StatementTable_7884DEB713248A18E33B461EA979D9B8" 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_7C82CA96FF62F37D8AB1461EA97A2524" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_7884DEB713248A18E33B461EA979D9B8" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_7C82CA96FF62F37D8AB1461EA97A2524" 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_95EC7A7D992CDDD5A489461EA97AC4D4_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_7C82CA96FF62F37D8AB1461EA97A2524" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_95EC7A7D992CDDD5A489461EA97AC4D4_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_95EC7A7D992CDDD5A489461EA97AC4D4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_7C82CA96FF62F37D8AB1461EA97A2524" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_95EC7A7D992CDDD5A489461EA97AC4D4" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RecourseDebtMember" xlink:label="loc_run_RecourseDebtMember_25EE1144EADB6A4EA554461EA97A93C5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_95EC7A7D992CDDD5A489461EA97AC4D4" xlink:to="loc_run_RecourseDebtMember_25EE1144EADB6A4EA554461EA97A93C5" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_NonRecourseDebtMember" xlink:label="loc_run_NonRecourseDebtMember_8511902EE2179C6B8E38461EA97B93E8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_95EC7A7D992CDDD5A489461EA97AC4D4" xlink:to="loc_run_NonRecourseDebtMember_8511902EE2179C6B8E38461EA97B93E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperationsAbstract" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperationsAbstract_24B413B5964EF4553CF6461EA97BAFDC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperationsAbstract_24B413B5964EF4553CF6461EA97BAFDC" 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_3CC3E0C1758838CF5FFB461EA97DB139" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperationsAbstract_24B413B5964EF4553CF6461EA97BAFDC" xlink:to="loc_us-gaap_ProfitLoss_3CC3E0C1758838CF5FFB461EA97DB139" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract" xlink:label="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperationsAbstract_24B413B5964EF4553CF6461EA97BAFDC" xlink:to="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DepreciationAndAmortization" xlink:label="loc_us-gaap_DepreciationAndAmortization_B8FA2B5D275F2150160B461EA97D5377" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_us-gaap_DepreciationAndAmortization_B8FA2B5D275F2150160B461EA97D5377" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredIncomeTaxExpenseBenefit" xlink:label="loc_us-gaap_DeferredIncomeTaxExpenseBenefit_FBC0645225AF208C35D8461EA97D6A7A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_us-gaap_DeferredIncomeTaxExpenseBenefit_FBC0645225AF208C35D8461EA97D6A7A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensation" xlink:label="loc_us-gaap_ShareBasedCompensation_D0FEE4E32A5290E6BCFE461EA97D385D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_us-gaap_ShareBasedCompensation_D0FEE4E32A5290E6BCFE461EA97D385D" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestOnLeaseFinancing" xlink:label="loc_run_InterestOnLeaseFinancing_7F6C3E40B25A4B1A524B461EA97DA1F4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_run_InterestOnLeaseFinancing_7F6C3E40B25A4B1A524B461EA97DA1F4" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ReductionInLeasePassThroughFinancingObligations" xlink:label="loc_run_ReductionInLeasePassThroughFinancingObligations_7A9268F8BF00CFDEF3E7461EA97DE2B6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_run_ReductionInLeasePassThroughFinancingObligations_7A9268F8BF00CFDEF3E7461EA97DE2B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNoncashExpense" xlink:label="loc_us-gaap_OtherNoncashExpense_2F4BB3CA1A87A20A65C8461EA97D65E8" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_us-gaap_OtherNoncashExpense_2F4BB3CA1A87A20A65C8461EA97D65E8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInOperatingCapitalAbstract" xlink:label="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E8C7F91FAEEE786F49E7461EA97DBD9E" xlink:to="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInAccountsReceivable" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_05A4A520B4C17CAD2738461EA97D1DCF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_05A4A520B4C17CAD2738461EA97D1DCF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInInventories" xlink:label="loc_us-gaap_IncreaseDecreaseInInventories_276AB0CC96DDDEC4B14C461EA97E38E2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:to="loc_us-gaap_IncreaseDecreaseInInventories_276AB0CC96DDDEC4B14C461EA97E38E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets" xlink:label="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_AFFCF907B9EE43F7DFCF461EA97E573C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:to="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_AFFCF907B9EE43F7DFCF461EA97E573C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInAccountsPayable" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsPayable_1AA761DAEFC6091D5AFD461EA97EE72F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsPayable_1AA761DAEFC6091D5AFD461EA97EE72F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInAccruedLiabilitiesAndOtherOperatingLiabilities" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedLiabilitiesAndOtherOperatingLiabilities_BFBBF70C0B7B197C09F6461EA97EAC7B" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedLiabilitiesAndOtherOperatingLiabilities_BFBBF70C0B7B197C09F6461EA97EAC7B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInDeferredRevenue" xlink:label="loc_us-gaap_IncreaseDecreaseInDeferredRevenue_38A827412DB41E33CD2F461EA97E379F" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_007D9F61C5E9FDA7D5BE461EA97DCCB8" xlink:to="loc_us-gaap_IncreaseDecreaseInDeferredRevenue_38A827412DB41E33CD2F461EA97E379F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations_8E253C2F125014221447461EA97E7AEB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperationsAbstract_24B413B5964EF4553CF6461EA97BAFDC" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations_8E253C2F125014221447461EA97E7AEB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperationsAbstract" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperationsAbstract_6C2EF8A38A8998648C69461EA97E3375" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperationsAbstract_6C2EF8A38A8998648C69461EA97E3375" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_PaymentsForCostOfSolarEnergySystemsToBeLeased" xlink:label="loc_run_PaymentsForCostOfSolarEnergySystemsToBeLeased_F7D65BADF822DE1CA656461EA97E96B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperationsAbstract_6C2EF8A38A8998648C69461EA97E3375" xlink:to="loc_run_PaymentsForCostOfSolarEnergySystemsToBeLeased_F7D65BADF822DE1CA656461EA97E96B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsToAcquirePropertyPlantAndEquipment" xlink:label="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_5F89916200F1EED473B0461EA97E4776" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperationsAbstract_6C2EF8A38A8998648C69461EA97E3375" xlink:to="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_5F89916200F1EED473B0461EA97E4776" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations_A56030C5CDBE72B7308A461EA97EA49F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperationsAbstract_6C2EF8A38A8998648C69461EA97E3375" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations_A56030C5CDBE72B7308A461EA97EA49F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ProceedsFromStateTaxCreditsNetOfRecapture" xlink:label="loc_run_ProceedsFromStateTaxCreditsNetOfRecapture_3DF3063F4D2F15033A4C461EA97E4154" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_run_ProceedsFromStateTaxCreditsNetOfRecapture_3DF3063F4D2F15033A4C461EA97E4154" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProceedsFromIssuanceOfDebt" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfDebt_B545E0181979273AF965461EA97FB5AB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfDebt_B545E0181979273AF965461EA97FB5AB" 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_71F9011052F7A505A070461EA97F79CE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_RepaymentsOfDebt_71F9011052F7A505A070461EA97F79CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsOfDebtIssuanceCosts" xlink:label="loc_us-gaap_PaymentsOfDebtIssuanceCosts_EDE2F4F302098D62E324461EA97F0219" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_PaymentsOfDebtIssuanceCosts_EDE2F4F302098D62E324461EA97F0219" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ProceedsFromLeasePassThroughFinancingObligations" xlink:label="loc_run_ProceedsFromLeasePassThroughFinancingObligations_7CC82449C6F280DF0052461EA97FAD84" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_run_ProceedsFromLeasePassThroughFinancingObligations_7CC82449C6F280DF0052461EA97FAD84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProceedsFromMinorityShareholders" xlink:label="loc_us-gaap_ProceedsFromMinorityShareholders_CF6615AC1D92D51BE4E0461EA97FBE79" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_ProceedsFromMinorityShareholders_CF6615AC1D92D51BE4E0461EA97FBE79" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsToMinorityShareholders" xlink:label="loc_us-gaap_PaymentsToMinorityShareholders_1840C886ABFA3D2B418E461EA97FA372" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_PaymentsToMinorityShareholders_1840C886ABFA3D2B418E461EA97FA372" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ProceedsPaymentsFromStockOptionsExercisedAndIssuanceOfSharesInConnectionWithEmployeeStockPurchasePlan" xlink:label="loc_run_ProceedsPaymentsFromStockOptionsExercisedAndIssuanceOfSharesInConnectionWithEmployeeStockPurchasePlan_63A94A73651B528C97AD461EA97F0DCC" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_run_ProceedsPaymentsFromStockOptionsExercisedAndIssuanceOfSharesInConnectionWithEmployeeStockPurchasePlan_63A94A73651B528C97AD461EA97F0DCC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RepaymentsOfLongTermCapitalLeaseObligations" xlink:label="loc_us-gaap_RepaymentsOfLongTermCapitalLeaseObligations_60416999F83576C40815461EA97F05CE" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_RepaymentsOfLongTermCapitalLeaseObligations_60416999F83576C40815461EA97F05CE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations_6418F6D9BC2BF3EB36C7461EA97FDA5B" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperationsAbstract_91E93B4534080AABB8A9461EA97ED6F0" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations_6418F6D9BC2BF3EB36C7461EA97FDA5B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_8C6FB8683F6AA445A9E5461EA97F353C" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_8C6FB8683F6AA445A9E5461EA97F353C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_A6A794025B9BCA70E5F0461EA97FFA28" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_A6A794025B9BCA70E5F0461EA97FFA28" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SupplementalCashFlowInformationAbstract" xlink:label="loc_us-gaap_SupplementalCashFlowInformationAbstract_EA70A908318D16297E18461EA97FB78E" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_SupplementalCashFlowInformationAbstract_EA70A908318D16297E18461EA97FB78E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestPaid" xlink:label="loc_us-gaap_InterestPaid_5FA2634DCB77330C8DB2461EA97F7908" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SupplementalCashFlowInformationAbstract_EA70A908318D16297E18461EA97FB78E" xlink:to="loc_us-gaap_InterestPaid_5FA2634DCB77330C8DB2461EA97F7908" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxesPaid" xlink:label="loc_us-gaap_IncomeTaxesPaid_F184036FD56395088A65461EA97F5E5D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SupplementalCashFlowInformationAbstract_EA70A908318D16297E18461EA97FB78E" xlink:to="loc_us-gaap_IncomeTaxesPaid_F184036FD56395088A65461EA97F5E5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncashInvestingAndFinancingItemsAbstract" xlink:label="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_2E6E0319812B45481F16461EA97F669E" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_EB4FC20E6B59A86E465B461EA97B2C9A" xlink:to="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_2E6E0319812B45481F16461EA97F669E" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_PurchasesOfSolarEnergySystemsAndPropertyAndEquipmentIncludedInAccountsPayableAndAccruedExpenses" xlink:label="loc_run_PurchasesOfSolarEnergySystemsAndPropertyAndEquipmentIncludedInAccountsPayableAndAccruedExpenses_52168F0F9588BA2D0409461EA97FAD31" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_2E6E0319812B45481F16461EA97F669E" xlink:to="loc_run_PurchasesOfSolarEnergySystemsAndPropertyAndEquipmentIncludedInAccountsPayableAndAccruedExpenses_52168F0F9588BA2D0409461EA97FAD31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NotesAssumed1" xlink:label="loc_us-gaap_NotesAssumed1_48441B97A71AD5B8DE9A461EA980D2A1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_2E6E0319812B45481F16461EA97F669E" xlink:to="loc_us-gaap_NotesAssumed1_48441B97A71AD5B8DE9A461EA980D2A1" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_AccruedDistributionsToNoncontrollingInterestsAndRedeemableNoncontrollingInterests" xlink:label="loc_run_AccruedDistributionsToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_7B0C1F191093A21C681E461EA9802A05" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_2E6E0319812B45481F16461EA97F669E" xlink:to="loc_run_AccruedDistributionsToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_7B0C1F191093A21C681E461EA9802A05" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RightOfUseAssetObtainedInExchangeForFinanceLeaseLiability" xlink:label="loc_us-gaap_RightOfUseAssetObtainedInExchangeForFinanceLeaseLiability_20AC972ECD6111B42422461EA980937C" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_2E6E0319812B45481F16461EA97F669E" xlink:to="loc_us-gaap_RightOfUseAssetObtainedInExchangeForFinanceLeaseLiability_20AC972ECD6111B42422461EA980937C" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfComprehensiveIncomeUnaudited" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfOperationsUnaudited" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/Derivatives" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DerivativesAdditionalInformationDetails" 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_67A69A04D761D8EE032041FF1802A860" 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_F334BD83168F2B862BBC41FF1802A5A6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_F334BD83168F2B862BBC41FF1802A5A6" 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_7843BD0191A51CCFF62441FF180282AB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_F334BD83168F2B862BBC41FF1802A5A6" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_7843BD0191A51CCFF62441FF180282AB" 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_F82A524E89079B62CDF741FF18022B3B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_7843BD0191A51CCFF62441FF180282AB" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_F82A524E89079B62CDF741FF18022B3B_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_F82A524E89079B62CDF741FF18022B3B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_7843BD0191A51CCFF62441FF180282AB" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_F82A524E89079B62CDF741FF18022B3B" 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_10150E65B54663EEC47241FF18026465" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_F82A524E89079B62CDF741FF18022B3B" xlink:to="loc_us-gaap_InterestRateSwapMember_10150E65B54663EEC47241FF18026465" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodNetOfTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodNetOfTax_6CF74A41B8681F46D8A341FF18023B76" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodNetOfTax_6CF74A41B8681F46D8A341FF18023B76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodTax_EA7EFA213C856410837241FF180240AD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_OtherComprehensiveIncomeUnrealizedGainLossOnDerivativesArisingDuringPeriodTax_EA7EFA213C856410837241FF180240AD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIOnDerivativesNetOfTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIOnDerivativesNetOfTax_64180031473C4D692CA541FF1803E072" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIOnDerivativesNetOfTax_64180031473C4D692CA541FF1803E072" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIOnDerivativesTax" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIOnDerivativesTax_30F5AEE51CE424AF4E9341FF18030A8E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIOnDerivativesTax_30F5AEE51CE424AF4E9341FF18030A8E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestRateCashFlowHedgeGainLossToBeReclassifiedDuringNext12MonthsNet" xlink:label="loc_us-gaap_InterestRateCashFlowHedgeGainLossToBeReclassifiedDuringNext12MonthsNet_F45AB01BCCDD8DCAEE7A41FF180345E2" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_InterestRateCashFlowHedgeGainLossToBeReclassifiedDuringNext12MonthsNet_F45AB01BCCDD8DCAEE7A41FF180345E2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeAssetsNoncurrent" xlink:label="loc_us-gaap_DerivativeAssetsNoncurrent_8CF8478699DEFA456B6141FF1803969E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_DerivativeAssetsNoncurrent_8CF8478699DEFA456B6141FF1803969E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeLiabilitiesNoncurrent" xlink:label="loc_us-gaap_DerivativeLiabilitiesNoncurrent_1ED2F0EAE25F892BFE0F41FF18039265" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_67A69A04D761D8EE032041FF1802A860" xlink:to="loc_us-gaap_DerivativeLiabilitiesNoncurrent_1ED2F0EAE25F892BFE0F41FF18039265" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DerivativesSummaryOfDerivativeInstrumentsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems" xlink:label="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable" xlink:label="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_63AFE470E88CA203060741FF19040909" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:to="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_63AFE470E88CA203060741FF19040909" 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_9E47CEA4C3F07785CA0E41FF1904F14D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_63AFE470E88CA203060741FF19040909" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_9E47CEA4C3F07785CA0E41FF1904F14D" 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_A8FC3C17D92DA28C90EA41FF1904F7B0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_9E47CEA4C3F07785CA0E41FF1904F14D" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A8FC3C17D92DA28C90EA41FF1904F7B0_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_A8FC3C17D92DA28C90EA41FF1904F7B0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_9E47CEA4C3F07785CA0E41FF1904F14D" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_A8FC3C17D92DA28C90EA41FF1904F7B0" 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_04B77CFC584AF6DC923741FF19048E44" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_A8FC3C17D92DA28C90EA41FF1904F7B0" xlink:to="loc_us-gaap_InterestRateSwapMember_04B77CFC584AF6DC923741FF19048E44" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditDerivativesByContractTypeAxis" xlink:label="loc_us-gaap_CreditDerivativesByContractTypeAxis_A30FAC3CE37EED2DD94F41FF19047E88" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_63AFE470E88CA203060741FF19040909" xlink:to="loc_us-gaap_CreditDerivativesByContractTypeAxis_A30FAC3CE37EED2DD94F41FF19047E88" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditDerivativesContractTypeDomain" xlink:label="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditDerivativesByContractTypeAxis_A30FAC3CE37EED2DD94F41FF19047E88" xlink:to="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CreditDerivativesContractTypeDomain" xlink:label="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditDerivativesByContractTypeAxis_A30FAC3CE37EED2DD94F41FF19047E88" xlink:to="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractOneMember" xlink:label="loc_run_InterestRateSwapContractOneMember_31940B1C31BA028DCA4A41FF19041584" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractOneMember_31940B1C31BA028DCA4A41FF19041584" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractTwoMember" xlink:label="loc_run_InterestRateSwapContractTwoMember_D1910868F447D0A6C25F41FF19043AFF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractTwoMember_D1910868F447D0A6C25F41FF19043AFF" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractThreeMember" xlink:label="loc_run_InterestRateSwapContractThreeMember_D6CA8DE8449F8266E57C41FF1904436B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractThreeMember_D6CA8DE8449F8266E57C41FF1904436B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractFourMember" xlink:label="loc_run_InterestRateSwapContractFourMember_D53EC481901EC02D45F141FF19051480" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractFourMember_D53EC481901EC02D45F141FF19051480" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractFiveMember" xlink:label="loc_run_InterestRateSwapContractFiveMember_1DFD0A76BFAFBC54482041FF190597C0" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractFiveMember_1DFD0A76BFAFBC54482041FF190597C0" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractSixMember" xlink:label="loc_run_InterestRateSwapContractSixMember_2BC2A5C8E61CD6E59B1141FF1905660B" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractSixMember_2BC2A5C8E61CD6E59B1141FF1905660B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractSevenMember" xlink:label="loc_run_InterestRateSwapContractSevenMember_5ACCC852711C8DBE88C641FF19055321" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractSevenMember_5ACCC852711C8DBE88C641FF19055321" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractEightMember" xlink:label="loc_run_InterestRateSwapContractEightMember_75ACE0B20B4281AB9A7141FF1905DC37" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractEightMember_75ACE0B20B4281AB9A7141FF1905DC37" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestRateSwapContractNineMember" xlink:label="loc_run_InterestRateSwapContractNineMember_5E4E55A95544162EEC0C41FF190598CB" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_3BAFD02AD7854A38869E41FF1904B167" xlink:to="loc_run_InterestRateSwapContractNineMember_5E4E55A95544162EEC0C41FF190598CB" 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_6763FCF126D73465EF8941FF190512CB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_63AFE470E88CA203060741FF19040909" xlink:to="loc_us-gaap_RangeAxis_6763FCF126D73465EF8941FF190512CB" 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_C89E37830EDCA979F04141FF1905C536_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_6763FCF126D73465EF8941FF190512CB" xlink:to="loc_us-gaap_RangeMember_C89E37830EDCA979F04141FF1905C536_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_C89E37830EDCA979F04141FF1905C536" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_6763FCF126D73465EF8941FF190512CB" xlink:to="loc_us-gaap_RangeMember_C89E37830EDCA979F04141FF1905C536" 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_C580E91ABB1A4407CA5941FF190527E6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_C89E37830EDCA979F04141FF1905C536" xlink:to="loc_us-gaap_MinimumMember_C580E91ABB1A4407CA5941FF190527E6" 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_B7BFDB7D15DD00E54EDA41FF19050007" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_C89E37830EDCA979F04141FF1905C536" xlink:to="loc_us-gaap_MaximumMember_B7BFDB7D15DD00E54EDA41FF19050007" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeNumberOfInstrumentsHeld" xlink:label="loc_us-gaap_DerivativeNumberOfInstrumentsHeld_D7D85BD4CF8D98A5369A41FF19065FFE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:to="loc_us-gaap_DerivativeNumberOfInstrumentsHeld_D7D85BD4CF8D98A5369A41FF19065FFE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PercentageOfDebtHedgedByInterestRateDerivatives" xlink:label="loc_us-gaap_PercentageOfDebtHedgedByInterestRateDerivatives_B1E76823995375CA711D41FF1906F255" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:to="loc_us-gaap_PercentageOfDebtHedgedByInterestRateDerivatives_B1E76823995375CA711D41FF1906F255" 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_056B9F227992B8B0A0B641FF194939EB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:to="loc_invest_DerivativeNotionalAmount_056B9F227992B8B0A0B641FF194939EB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeFairValueOfDerivativeAsset" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_147D7C3F71E91BFDF67C41FF194958E0" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_147D7C3F71E91BFDF67C41FF194958E0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DerivativeFairValueOfDerivativeLiability" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_762FD0A26850CA2E027D41FF1949BD9D" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_16E9DD57FBE73694EF5F41FF1906F199" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_762FD0A26850CA2E027D41FF1949BD9D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DerivativesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DocumentAndEntityInformation" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/EarningsPerShare" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/EarningsPerShareComputationOfBasicAndDilutedNetIncomePerShareDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/EarningsPerShareScheduleOfSharesExcludedFromComputationOfDilutedNetIncomePerShareDetails" 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_AFDF22C6C8A97CF1EB0741FF163CD4DD" 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_8E6B63E9DB705B43315141FF163B3427" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_AFDF22C6C8A97CF1EB0741FF163CD4DD" xlink:to="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_8E6B63E9DB705B43315141FF163B3427" 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_7F1E0883DCEECEF1679841FF163B5D76" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_8E6B63E9DB705B43315141FF163B3427" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_7F1E0883DCEECEF1679841FF163B5D76" 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_A5812A4EC42E981542A241FF163B3D34_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_7F1E0883DCEECEF1679841FF163B5D76" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_A5812A4EC42E981542A241FF163B3D34_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_A5812A4EC42E981542A241FF163B3D34" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_7F1E0883DCEECEF1679841FF163B5D76" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_A5812A4EC42E981542A241FF163B3D34" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WarrantMember" xlink:label="loc_us-gaap_WarrantMember_8D90C62CCAC4C57FBBE441FF163B79BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_A5812A4EC42E981542A241FF163B3D34" xlink:to="loc_us-gaap_WarrantMember_8D90C62CCAC4C57FBBE441FF163B79BC" 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_E95413841C8C089E16E641FF163B316B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_A5812A4EC42E981542A241FF163B3D34" xlink:to="loc_us-gaap_EmployeeStockOptionMember_E95413841C8C089E16E641FF163B316B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestrictedStockUnitsRSUMember" xlink:label="loc_us-gaap_RestrictedStockUnitsRSUMember_A6B2C0FCE54828CC1B1641FF163CE5FA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_A5812A4EC42E981542A241FF163B3D34" xlink:to="loc_us-gaap_RestrictedStockUnitsRSUMember_A6B2C0FCE54828CC1B1641FF163CE5FA" 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_B430AA8D460A1506462A41FF163CB8E0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_AFDF22C6C8A97CF1EB0741FF163CD4DD" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_B430AA8D460A1506462A41FF163CB8E0" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/EarningsPerShareTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/FairValueMeasurement" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/FairValueMeasurementScheduleOfCarryingValuesAndFairValuesOfDebtInstrumentsDetails" 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_E37F042CE4BCADAD851C462F349F766F" 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_7A8C47F1532745042490462F349E3706" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_E37F042CE4BCADAD851C462F349F766F" xlink:to="loc_us-gaap_FairValueByBalanceSheetGroupingTable_7A8C47F1532745042490462F349E3706" 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_E6FAA70425E7DF2CCF44462F349E376E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_7A8C47F1532745042490462F349E3706" xlink:to="loc_us-gaap_DebtInstrumentAxis_E6FAA70425E7DF2CCF44462F349E376E" 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_815314EE0C94B8C553D8462F349E5B5C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_E6FAA70425E7DF2CCF44462F349E376E" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C_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_815314EE0C94B8C553D8462F349E5B5C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_E6FAA70425E7DF2CCF44462F349E376E" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankLineOfCreditMember" xlink:label="loc_run_BankLineOfCreditMember_2855A6932913B222FE48462F349EE045" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C" xlink:to="loc_run_BankLineOfCreditMember_2855A6932913B222FE48462F349EE045" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SeniorDebtMember" xlink:label="loc_run_SeniorDebtMember_C999B2C823BF940E299D46319BCB87B0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C" xlink:to="loc_run_SeniorDebtMember_C999B2C823BF940E299D46319BCB87B0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubordinatedDebtMember" xlink:label="loc_us-gaap_SubordinatedDebtMember_ACA0668A91CD50204F5A4631CD090EB4" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C" xlink:to="loc_us-gaap_SubordinatedDebtMember_ACA0668A91CD50204F5A4631CD090EB4" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SecuritizationDebtMember" xlink:label="loc_run_SecuritizationDebtMember_CCEB3D3153F6201CFF7346329652E8C9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C" xlink:to="loc_run_SecuritizationDebtMember_CCEB3D3153F6201CFF7346329652E8C9" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SRECLoansMember" xlink:label="loc_run_SRECLoansMember_7AE3E775F2F2F1AF8554463020F24BBD" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_815314EE0C94B8C553D8462F349E5B5C" xlink:to="loc_run_SRECLoansMember_7AE3E775F2F2F1AF8554463020F24BBD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByMeasurementBasisAxis" xlink:label="loc_us-gaap_FairValueByMeasurementBasisAxis_05460EA1EEA9F54EB1B8462F349EA57D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_7A8C47F1532745042490462F349E3706" xlink:to="loc_us-gaap_FairValueByMeasurementBasisAxis_05460EA1EEA9F54EB1B8462F349EA57D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PortionAtFairValueFairValueDisclosureMember" xlink:label="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_F67BE10B0645D95B86F0462F349EFECE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementBasisAxis_05460EA1EEA9F54EB1B8462F349EA57D" xlink:to="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_F67BE10B0645D95B86F0462F349EFECE_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueDisclosureItemAmountsDomain" xlink:label="loc_us-gaap_FairValueDisclosureItemAmountsDomain_83D78DCCE84D47E2768C462F349EF139" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementBasisAxis_05460EA1EEA9F54EB1B8462F349EA57D" xlink:to="loc_us-gaap_FairValueDisclosureItemAmountsDomain_83D78DCCE84D47E2768C462F349EF139" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PortionAtFairValueFairValueDisclosureMember" xlink:label="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_F67BE10B0645D95B86F0462F349EFECE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueDisclosureItemAmountsDomain_83D78DCCE84D47E2768C462F349EF139" xlink:to="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_F67BE10B0645D95B86F0462F349EFECE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CarryingReportedAmountFairValueDisclosureMember" xlink:label="loc_us-gaap_CarryingReportedAmountFairValueDisclosureMember_A39F567D92927D0A8FEB462F349ECA31" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_F67BE10B0645D95B86F0462F349EFECE" xlink:to="loc_us-gaap_CarryingReportedAmountFairValueDisclosureMember_A39F567D92927D0A8FEB462F349ECA31" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EstimateOfFairValueFairValueDisclosureMember" xlink:label="loc_us-gaap_EstimateOfFairValueFairValueDisclosureMember_661372B4B479C8D47AF6462F349EA1D5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_F67BE10B0645D95B86F0462F349EFECE" xlink:to="loc_us-gaap_EstimateOfFairValueFairValueDisclosureMember_661372B4B479C8D47AF6462F349EA1D5" 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_E74774B3D7EEB1455353462F349F4463" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_E37F042CE4BCADAD851C462F349F766F" xlink:to="loc_us-gaap_LongTermDebtFairValue_E74774B3D7EEB1455353462F349F4463" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/FairValueMeasurementScheduleOfFairValueFinancialInstrumentsMeasuredOnRecurringBasisDetails" 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_64D805606623E253E33241FF182AD601" 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_C31DBD0E17E04B054C0841FF18232774" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_64D805606623E253E33241FF182AD601" xlink:to="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_C31DBD0E17E04B054C0841FF18232774" 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_FinancialInstrumentAxis" xlink:label="loc_us-gaap_FinancialInstrumentAxis_703FA9FFC3925F1F99D641FF18235C9A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_C31DBD0E17E04B054C0841FF18232774" xlink:to="loc_us-gaap_FinancialInstrumentAxis_703FA9FFC3925F1F99D641FF18235C9A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain" xlink:label="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_4766FCA74696030E74B841FF1823A760_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FinancialInstrumentAxis_703FA9FFC3925F1F99D641FF18235C9A" xlink:to="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_4766FCA74696030E74B841FF1823A760_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain" xlink:label="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_4766FCA74696030E74B841FF1823A760" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FinancialInstrumentAxis_703FA9FFC3925F1F99D641FF18235C9A" xlink:to="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_4766FCA74696030E74B841FF1823A760" 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_BC19AFFEB0D32E1D982541FF18249FCE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_4766FCA74696030E74B841FF1823A760" xlink:to="loc_us-gaap_InterestRateSwapMember_BC19AFFEB0D32E1D982541FF18249FCE" 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_A493F6840EDD2F2344B641FF1824A801" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_C31DBD0E17E04B054C0841FF18232774" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A493F6840EDD2F2344B641FF1824A801" 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_753AED2D567FB5F2AFE041FF1824B76F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A493F6840EDD2F2344B641FF1824A801" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_753AED2D567FB5F2AFE041FF1824B76F_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_753AED2D567FB5F2AFE041FF1824B76F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_A493F6840EDD2F2344B641FF1824A801" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_753AED2D567FB5F2AFE041FF1824B76F" 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_A50BA67C700A459AF44C41FF1829CFE5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_753AED2D567FB5F2AFE041FF1824B76F" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_A50BA67C700A459AF44C41FF1829CFE5" 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_323BEE6954ABE667C93441FF1829D4BE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_753AED2D567FB5F2AFE041FF1824B76F" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_323BEE6954ABE667C93441FF1829D4BE" 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_058F9226576743994A8D41FF18297B10" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_753AED2D567FB5F2AFE041FF1824B76F" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_058F9226576743994A8D41FF18297B10" 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_BB948434389C8221240C41FF182A76F2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_64D805606623E253E33241FF182AD601" xlink:to="loc_us-gaap_DerivativeAssets_BB948434389C8221240C41FF182A76F2" 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_1CE78277A3B0D94C5F8441FF182A56A5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_64D805606623E253E33241FF182AD601" xlink:to="loc_us-gaap_DerivativeLiabilities_1CE78277A3B0D94C5F8441FF182A56A5" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/FairValueMeasurementTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxes" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesAdditionalInformationDetails" 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_88F91EAF3107A52A007A41FF17040C56" 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_585DAD464D28C44CA62041FF1703EE0B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_us-gaap_IncomeTaxContingencyTable_585DAD464D28C44CA62041FF1703EE0B" 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_IncomeTaxAuthorityNameAxis" xlink:label="loc_us-gaap_IncomeTaxAuthorityNameAxis_2209AE0F52ECB1FE904541FF17031FE0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_585DAD464D28C44CA62041FF1703EE0B" xlink:to="loc_us-gaap_IncomeTaxAuthorityNameAxis_2209AE0F52ECB1FE904541FF17031FE0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxAuthorityNameDomain" xlink:label="loc_us-gaap_IncomeTaxAuthorityNameDomain_1BEC110C9143C8706CF741FF170423A9_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameAxis_2209AE0F52ECB1FE904541FF17031FE0" xlink:to="loc_us-gaap_IncomeTaxAuthorityNameDomain_1BEC110C9143C8706CF741FF170423A9_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxAuthorityNameDomain" xlink:label="loc_us-gaap_IncomeTaxAuthorityNameDomain_1BEC110C9143C8706CF741FF170423A9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameAxis_2209AE0F52ECB1FE904541FF17031FE0" xlink:to="loc_us-gaap_IncomeTaxAuthorityNameDomain_1BEC110C9143C8706CF741FF170423A9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InternalRevenueServiceIRSMember" xlink:label="loc_us-gaap_InternalRevenueServiceIRSMember_225096DEF7F1813B480041FF1704C49A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameDomain_1BEC110C9143C8706CF741FF170423A9" xlink:to="loc_us-gaap_InternalRevenueServiceIRSMember_225096DEF7F1813B480041FF1704C49A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxAuthorityAxis" xlink:label="loc_us-gaap_IncomeTaxAuthorityAxis_6EBE7D20C062278B7CFC41FF1704F74C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_585DAD464D28C44CA62041FF1703EE0B" xlink:to="loc_us-gaap_IncomeTaxAuthorityAxis_6EBE7D20C062278B7CFC41FF1704F74C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxAuthorityDomain" xlink:label="loc_us-gaap_IncomeTaxAuthorityDomain_7CCEC45C5533A8E3924341FF17043413_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeTaxAuthorityAxis_6EBE7D20C062278B7CFC41FF1704F74C" xlink:to="loc_us-gaap_IncomeTaxAuthorityDomain_7CCEC45C5533A8E3924341FF17043413_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeTaxAuthorityDomain" xlink:label="loc_us-gaap_IncomeTaxAuthorityDomain_7CCEC45C5533A8E3924341FF17043413" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeTaxAuthorityAxis_6EBE7D20C062278B7CFC41FF1704F74C" xlink:to="loc_us-gaap_IncomeTaxAuthorityDomain_7CCEC45C5533A8E3924341FF17043413" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StateAndLocalJurisdictionMember" xlink:label="loc_us-gaap_StateAndLocalJurisdictionMember_4B7B4F767552858548F041FF1704E71A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityDomain_7CCEC45C5533A8E3924341FF17043413" xlink:to="loc_us-gaap_StateAndLocalJurisdictionMember_4B7B4F767552858548F041FF1704E71A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EffectiveIncomeTaxRateContinuingOperations" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_1FD0D8212E315DD162DC41FF17044D91" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_1FD0D8212E315DD162DC41FF17044D91" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecognizedTaxBenefits" xlink:label="loc_us-gaap_UnrecognizedTaxBenefits_E7DD79643025F6869AA741FF17059F30" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_us-gaap_UnrecognizedTaxBenefits_E7DD79643025F6869AA741FF17059F30" 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_273EE7F0BED91D08638F41FF17054527" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_273EE7F0BED91D08638F41FF17054527" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsReductionsResultingFromLapseOfApplicableStatuteOfLimitations" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsReductionsResultingFromLapseOfApplicableStatuteOfLimitations_0680ADF7F7E1C1B030F141FF17052BE5" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsReductionsResultingFromLapseOfApplicableStatuteOfLimitations_0680ADF7F7E1C1B030F141FF17052BE5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingLossCarryforwards" xlink:label="loc_us-gaap_OperatingLossCarryforwards_93C0E5487571FBDDA30041FF17058897" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_us-gaap_OperatingLossCarryforwards_93C0E5487571FBDDA30041FF17058897" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_OperatingLossCarryforwardsExpirationYear" xlink:label="loc_run_OperatingLossCarryforwardsExpirationYear_ACC1D7CC19A56BF6654C41FF17052F3A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_88F91EAF3107A52A007A41FF17040C56" xlink:to="loc_run_OperatingLossCarryforwardsExpirationYear_ACC1D7CC19A56BF6654C41FF17052F3A" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/Indebtedness" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IndebtednessAdditionalInformationDetails" 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_FF724B41C9841BC0D3A2462F3403623E" 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_82992B426DD1912C4B81462F34002A21" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" 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_SubsequentEventTypeAxis" xlink:label="loc_us-gaap_SubsequentEventTypeAxis_667C751584BA829495C6462F3400F38A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_SubsequentEventTypeAxis_667C751584BA829495C6462F3400F38A" 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_4C193BFA279E4EEF0C8D462F3400C811_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_SubsequentEventTypeAxis_667C751584BA829495C6462F3400F38A" xlink:to="loc_us-gaap_SubsequentEventTypeDomain_4C193BFA279E4EEF0C8D462F3400C811_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_4C193BFA279E4EEF0C8D462F3400C811" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_SubsequentEventTypeAxis_667C751584BA829495C6462F3400F38A" xlink:to="loc_us-gaap_SubsequentEventTypeDomain_4C193BFA279E4EEF0C8D462F3400C811" 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_3A0EDF44187206460498462F3400ABEB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SubsequentEventTypeDomain_4C193BFA279E4EEF0C8D462F3400C811" xlink:to="loc_us-gaap_SubsequentEventMember_3A0EDF44187206460498462F3400ABEB" 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_8336AF971A21F942701B462F34000162" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_8336AF971A21F942701B462F34000162" 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_D4C15038F208E6BCDB7C462F3400B66F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_8336AF971A21F942701B462F34000162" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_D4C15038F208E6BCDB7C462F3400B66F_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_D4C15038F208E6BCDB7C462F3400B66F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_8336AF971A21F942701B462F34000162" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_D4C15038F208E6BCDB7C462F3400B66F" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ContractedSolarRenewableEnergyCreditsMember" xlink:label="loc_run_ContractedSolarRenewableEnergyCreditsMember_951CEDA32CF0CA64188E462F34003704" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_D4C15038F208E6BCDB7C462F3400B66F" xlink:to="loc_run_ContractedSolarRenewableEnergyCreditsMember_951CEDA32CF0CA64188E462F34003704" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_UncontractedSolarRenewableEnergyCreditsMember" xlink:label="loc_run_UncontractedSolarRenewableEnergyCreditsMember_C0CC08C6427F09B291E8462F3400E298" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_D4C15038F208E6BCDB7C462F3400B66F" xlink:to="loc_run_UncontractedSolarRenewableEnergyCreditsMember_C0CC08C6427F09B291E8462F3400E298" 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_BB18A3D166C0F96C75F3462F3400306B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_DebtInstrumentAxis_BB18A3D166C0F96C75F3462F3400306B" 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_FFB4D72FFC63A2166414462F34009275_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_BB18A3D166C0F96C75F3462F3400306B" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275_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_FFB4D72FFC63A2166414462F34009275" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_BB18A3D166C0F96C75F3462F3400306B" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankLineOfCreditMember" xlink:label="loc_run_BankLineOfCreditMember_5DFB2AEB3C4201F893AE462F3400C860" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_BankLineOfCreditMember_5DFB2AEB3C4201F893AE462F3400C860" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanDueinOctober2024Member" xlink:label="loc_run_TermLoanDueinOctober2024Member_D7C54FD033E351E294FE462F3400D820" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_TermLoanDueinOctober2024Member_D7C54FD033E351E294FE462F3400D820" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanDueinApril2024Member" xlink:label="loc_run_TermLoanDueinApril2024Member_AD7CEB5AD817EB722300462F3400B0AE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_TermLoanDueinApril2024Member_AD7CEB5AD817EB722300462F3400B0AE" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanBMember" xlink:label="loc_run_TermLoanBMember_5D26944F7CCD597F43C5462F34011C20" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_TermLoanBMember_5D26944F7CCD597F43C5462F34011C20" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanBClassAMember" xlink:label="loc_run_TermLoanBClassAMember_56E025029842974FFA9D462F3401C0D6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_TermLoanBMember_5D26944F7CCD597F43C5462F34011C20" xlink:to="loc_run_TermLoanBClassAMember_56E025029842974FFA9D462F3401C0D6" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanBClassBMember" xlink:label="loc_run_TermLoanBClassBMember_C8C11CAACA55D9CF4913462F3401B299" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_TermLoanBMember_5D26944F7CCD597F43C5462F34011C20" xlink:to="loc_run_TermLoanBClassBMember_C8C11CAACA55D9CF4913462F3401B299" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanMember" xlink:label="loc_run_TermLoanMember_E5700D72E3FFB5CFA048462F3401B02B" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_TermLoanMember_E5700D72E3FFB5CFA048462F3401B02B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanAMember" xlink:label="loc_run_TermLoanAMember_88B65FEDD887FBCC2AC1462F3401A241" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_TermLoanAMember_88B65FEDD887FBCC2AC1462F3401A241" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SeniorDebtMember" xlink:label="loc_run_SeniorDebtMember_BD07925A26F1CDBE8295462F3401927A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_SeniorDebtMember_BD07925A26F1CDBE8295462F3401927A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubordinatedDebtMember" xlink:label="loc_us-gaap_SubordinatedDebtMember_42028418903EF14BB629462F34017D5B" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_us-gaap_SubordinatedDebtMember_42028418903EF14BB629462F34017D5B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankLoanDueSeptember2020Member" xlink:label="loc_run_BankLoanDueSeptember2020Member_599A7CBA5328DA992DDA462F3401E4B6" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_BankLoanDueSeptember2020Member_599A7CBA5328DA992DDA462F3401E4B6" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankTermLoanDueAprilTwentyTwentyTwoMember" xlink:label="loc_run_BankTermLoanDueAprilTwentyTwentyTwoMember_37FD71EE0740F4651815462F34011555" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_BankTermLoanDueAprilTwentyTwentyTwoMember_37FD71EE0740F4651815462F34011555" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheOneMember" xlink:label="loc_run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheOneMember_9299AD0176D7621B56AC462F34014B68" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheOneMember_9299AD0176D7621B56AC462F34014B68" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheTwoMember" xlink:label="loc_run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheTwoMember_777FF2CE3D6A5846BE8C462F3401AC0C" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheTwoMember_777FF2CE3D6A5846BE8C462F3401AC0C" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SecuritizationDebtMember" xlink:label="loc_run_SecuritizationDebtMember_25257C60B09E087F9DFE463636E06DE1" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_SecuritizationDebtMember_25257C60B09E087F9DFE463636E06DE1" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SRECLoansMember" xlink:label="loc_run_SRECLoansMember_7E1FB6C3D56ED9BC9358462F3401113D" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_FFB4D72FFC63A2166414462F34009275" xlink:to="loc_run_SRECLoansMember_7E1FB6C3D56ED9BC9358462F3401113D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityAxis" xlink:label="loc_us-gaap_LineOfCreditFacilityAxis_36555551362BBAF5D947462F340166E4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_LineOfCreditFacilityAxis_36555551362BBAF5D947462F340166E4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityLenderDomain" xlink:label="loc_us-gaap_LineOfCreditFacilityLenderDomain_7F96FC2C67BE47F7580C462F3401B41D_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LineOfCreditFacilityAxis_36555551362BBAF5D947462F340166E4" xlink:to="loc_us-gaap_LineOfCreditFacilityLenderDomain_7F96FC2C67BE47F7580C462F3401B41D_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LineOfCreditFacilityLenderDomain" xlink:label="loc_us-gaap_LineOfCreditFacilityLenderDomain_7F96FC2C67BE47F7580C462F3401B41D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LineOfCreditFacilityAxis_36555551362BBAF5D947462F340166E4" xlink:to="loc_us-gaap_LineOfCreditFacilityLenderDomain_7F96FC2C67BE47F7580C462F3401B41D" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_AggregationFacilityMarch2023Member" xlink:label="loc_run_AggregationFacilityMarch2023Member_74FF30EE875833957BB7462F340136E2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLenderDomain_7F96FC2C67BE47F7580C462F3401B41D" xlink:to="loc_run_AggregationFacilityMarch2023Member_74FF30EE875833957BB7462F340136E2" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_AggregationFacilityDecember2021Member" xlink:label="loc_run_AggregationFacilityDecember2021Member_DD597CAFC6BA179BB805462F3401CD7B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLenderDomain_7F96FC2C67BE47F7580C462F3401B41D" xlink:to="loc_run_AggregationFacilityDecember2021Member_DD597CAFC6BA179BB805462F3401CD7B" 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_FED246189D156EBD14EB462F34019AFA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_RangeAxis_FED246189D156EBD14EB462F34019AFA" 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_DEC3CBDBB25007B437A3462F34017D95_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_FED246189D156EBD14EB462F34019AFA" xlink:to="loc_us-gaap_RangeMember_DEC3CBDBB25007B437A3462F34017D95_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_DEC3CBDBB25007B437A3462F34017D95" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_FED246189D156EBD14EB462F34019AFA" xlink:to="loc_us-gaap_RangeMember_DEC3CBDBB25007B437A3462F34017D95" 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_B9E7D0395EF066044012462F34019A7A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_DEC3CBDBB25007B437A3462F34017D95" xlink:to="loc_us-gaap_MinimumMember_B9E7D0395EF066044012462F34019A7A" 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_9517D28D14BBC99374CE462F3401868B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_DEC3CBDBB25007B437A3462F34017D95" xlink:to="loc_us-gaap_MaximumMember_9517D28D14BBC99374CE462F3401868B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableRateAxis" xlink:label="loc_us-gaap_VariableRateAxis_EDFB98FBE5DC663F943F462F3402443C" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_VariableRateAxis_EDFB98FBE5DC663F943F462F3402443C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableRateDomain" xlink:label="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableRateAxis_EDFB98FBE5DC663F943F462F3402443C" xlink:to="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableRateDomain" xlink:label="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableRateAxis_EDFB98FBE5DC663F943F462F3402443C" xlink:to="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LondonInterbankOfferedRateLIBORMember" xlink:label="loc_us-gaap_LondonInterbankOfferedRateLIBORMember_0D04698C1C32B68CE9ED462F34020870" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB" xlink:to="loc_us-gaap_LondonInterbankOfferedRateLIBORMember_0D04698C1C32B68CE9ED462F34020870" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BaseRateMember" xlink:label="loc_us-gaap_BaseRateMember_BD933793F40C75AC8CE7462F3402F99B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB" xlink:to="loc_us-gaap_BaseRateMember_BD933793F40C75AC8CE7462F3402F99B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FederalFundsEffectiveSwapRateMember" xlink:label="loc_us-gaap_FederalFundsEffectiveSwapRateMember_57696406FC4AE05EB942462F34027691" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB" xlink:to="loc_us-gaap_FederalFundsEffectiveSwapRateMember_57696406FC4AE05EB942462F34027691" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_LiborFloorRateMember" xlink:label="loc_run_LiborFloorRateMember_600E617B45FAABC011B2462F34020BAC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_5416E2E714D548526120462F3402A2AB" xlink:to="loc_run_LiborFloorRateMember_600E617B45FAABC011B2462F34020BAC" 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_AC98D624D84453CC03C9462F3402C10F" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_CreditFacilityAxis_AC98D624D84453CC03C9462F3402C10F" 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_A3F44BFF59CCF9CB615E462F3402E11B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_AC98D624D84453CC03C9462F3402C10F" xlink:to="loc_us-gaap_CreditFacilityDomain_A3F44BFF59CCF9CB615E462F3402E11B_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_A3F44BFF59CCF9CB615E462F3402E11B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_AC98D624D84453CC03C9462F3402C10F" xlink:to="loc_us-gaap_CreditFacilityDomain_A3F44BFF59CCF9CB615E462F3402E11B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SeniorSecuredRevolvingLetterOfCreditFacilityMember" xlink:label="loc_run_SeniorSecuredRevolvingLetterOfCreditFacilityMember_69CF40AA632044F994AD462F3402CC7B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_A3F44BFF59CCF9CB615E462F3402E11B" xlink:to="loc_run_SeniorSecuredRevolvingLetterOfCreditFacilityMember_69CF40AA632044F994AD462F3402CC7B" 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_14D605041C7CE7A1267E462F3402C283" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_A3F44BFF59CCF9CB615E462F3402E11B" xlink:to="loc_us-gaap_LineOfCreditMember_14D605041C7CE7A1267E462F3402C283" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanMember" xlink:label="loc_run_TermLoanMember_71D06EE7B4D97B28A808462F3402E73C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_A3F44BFF59CCF9CB615E462F3402E11B" xlink:to="loc_run_TermLoanMember_71D06EE7B4D97B28A808462F3402E73C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LetterOfCreditMember" xlink:label="loc_us-gaap_LetterOfCreditMember_64A4C9A8B1A727474649462F340235ED" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_A3F44BFF59CCF9CB615E462F3402E11B" xlink:to="loc_us-gaap_LetterOfCreditMember_64A4C9A8B1A727474649462F340235ED" 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_B7D0EE645953855A9EDA462F3402C54D" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_82992B426DD1912C4B81462F34002A21" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_B7D0EE645953855A9EDA462F3402C54D" 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_5D4E2671F32C272ECA86462F3402E0F2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_B7D0EE645953855A9EDA462F3402C54D" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_5D4E2671F32C272ECA86462F3402E0F2_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_5D4E2671F32C272ECA86462F3402E0F2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_B7D0EE645953855A9EDA462F3402C54D" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_5D4E2671F32C272ECA86462F3402E0F2" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RecourseDebtMember" xlink:label="loc_run_RecourseDebtMember_095DE8B231F69A638D87462F3402A6FE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_5D4E2671F32C272ECA86462F3402E0F2" xlink:to="loc_run_RecourseDebtMember_095DE8B231F69A638D87462F3402A6FE" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_NonRecourseDebtMember" xlink:label="loc_run_NonRecourseDebtMember_262FA12286E7D1664D4A462F340280FB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_5D4E2671F32C272ECA86462F3402E0F2" xlink:to="loc_run_NonRecourseDebtMember_262FA12286E7D1664D4A462F340280FB" 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_3023255159D1304A7C9E462F3403F90F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_3023255159D1304A7C9E462F3403F90F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentBasisSpreadOnVariableRate1" xlink:label="loc_us-gaap_DebtInstrumentBasisSpreadOnVariableRate1_427136AC2C383AA8B247462F34031F91" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_DebtInstrumentBasisSpreadOnVariableRate1_427136AC2C383AA8B247462F34031F91" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_MinimumUnencumberedLiquidAssets" xlink:label="loc_run_MinimumUnencumberedLiquidAssets_8498AD63F8925DC7FFCD462F3403D89F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_MinimumUnencumberedLiquidAssets_8498AD63F8925DC7FFCD462F3403D89F" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InterestCoverageRatio" xlink:label="loc_run_InterestCoverageRatio_E9A5259C88EAFF4487BB462F340388EE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_InterestCoverageRatio_E9A5259C88EAFF4487BB462F340388EE" 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_064C946C69EC0547F748462F3403A43B" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_LongTermDebt_064C946C69EC0547F748462F3403A43B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DebtInstrumentBasisSpreadonVariableRateFederalFundsRate" xlink:label="loc_run_DebtInstrumentBasisSpreadonVariableRateFederalFundsRate_6DC62631C127F63992ED462F340349B1" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_DebtInstrumentBasisSpreadonVariableRateFederalFundsRate_6DC62631C127F63992ED462F340349B1" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RevolvingLineOfCreditFacilityAvailablePeriodIncrease" xlink:label="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodIncrease_3EE5EE0C1EF728C1CD40462F3403AF82" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodIncrease_3EE5EE0C1EF728C1CD40462F3403AF82" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DebtInstrumentBasisSpreadOnVariableRatePeriodicIncrease" xlink:label="loc_run_DebtInstrumentBasisSpreadOnVariableRatePeriodicIncrease_1C1EC32608E05538B386462F34039FC1" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_DebtInstrumentBasisSpreadOnVariableRatePeriodicIncrease_1C1EC32608E05538B386462F34039FC1" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RevolvingLineOfCreditFacilityAvailablePeriodPeriodIncrease" xlink:label="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodPeriodIncrease_B12FA607761B627CC6ED462F340359DE" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodPeriodIncrease_B12FA607761B627CC6ED462F340359DE" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_TermLoanPrepaymentPenaltyPercent" xlink:label="loc_run_TermLoanPrepaymentPenaltyPercent_9748ABCBDB014A518353462F3403ECB6" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_run_TermLoanPrepaymentPenaltyPercent_9748ABCBDB014A518353462F3403ECB6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Cash" xlink:label="loc_us-gaap_Cash_E83B97C3278E587D9B45462F34037F70" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_Cash_E83B97C3278E587D9B45462F34037F70" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TransfersAccountedForAsSecuredBorrowingsAssetsCarryingAmount" xlink:label="loc_us-gaap_TransfersAccountedForAsSecuredBorrowingsAssetsCarryingAmount_759D15EDEE9B167D24BC462F3403EB6D" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_TransfersAccountedForAsSecuredBorrowingsAssetsCarryingAmount_759D15EDEE9B167D24BC462F3403EB6D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtWeightedAverageInterestRate" xlink:label="loc_us-gaap_DebtWeightedAverageInterestRate_EF7D46806FD81980BE13462F3403D378" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_FF724B41C9841BC0D3A2462F3403623E" xlink:to="loc_us-gaap_DebtWeightedAverageInterestRate_EF7D46806FD81980BE13462F3403D378" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IndebtednessScheduleOfDebtDetails" 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_A566348977F91983BF80462F340B3494" 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_124C3FC5242A4A3E6272462F34096A48" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_DebtInstrumentTable_124C3FC5242A4A3E6272462F34096A48" 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_652CD00B47779E8034DD462F340A7C0B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_124C3FC5242A4A3E6272462F34096A48" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_652CD00B47779E8034DD462F340A7C0B" 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_03C2752F1D94501432FA462F340ABB46_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_652CD00B47779E8034DD462F340A7C0B" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_03C2752F1D94501432FA462F340ABB46_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_03C2752F1D94501432FA462F340ABB46" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_652CD00B47779E8034DD462F340A7C0B" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_03C2752F1D94501432FA462F340ABB46" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RecourseDebtMember" xlink:label="loc_run_RecourseDebtMember_9639D7541B6830771C8D462F340AB978" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_03C2752F1D94501432FA462F340ABB46" xlink:to="loc_run_RecourseDebtMember_9639D7541B6830771C8D462F340AB978" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_NonRecourseDebtMember" xlink:label="loc_run_NonRecourseDebtMember_C9B0F98F8246A454A39B462F340AAF49" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_03C2752F1D94501432FA462F340ABB46" xlink:to="loc_run_NonRecourseDebtMember_C9B0F98F8246A454A39B462F340AAF49" 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_D45BFE289C41351C4C13462F340A3FD8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_124C3FC5242A4A3E6272462F34096A48" xlink:to="loc_us-gaap_DebtInstrumentAxis_D45BFE289C41351C4C13462F340A3FD8" 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_0F3F1F2945C9EFDDC1E9462F340AF944_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_D45BFE289C41351C4C13462F340A3FD8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944_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_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_D45BFE289C41351C4C13462F340A3FD8" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_BankLineOfCreditMember" xlink:label="loc_run_BankLineOfCreditMember_0D9E080B74A4F06EBE06462F340A2891" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:to="loc_run_BankLineOfCreditMember_0D9E080B74A4F06EBE06462F340A2891" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SeniorDebtMember" xlink:label="loc_run_SeniorDebtMember_1964ED5DB5C7FC3FAF2C462F340AB86C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:to="loc_run_SeniorDebtMember_1964ED5DB5C7FC3FAF2C462F340AB86C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SubordinatedDebtMember" xlink:label="loc_us-gaap_SubordinatedDebtMember_397E7775A7FA1455CBA7462F340A9B4C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:to="loc_us-gaap_SubordinatedDebtMember_397E7775A7FA1455CBA7462F340A9B4C" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SecuritizationDebtClassAMember" xlink:label="loc_run_SecuritizationDebtClassAMember_31206DF141098AB9B459462F340A3521" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:to="loc_run_SecuritizationDebtClassAMember_31206DF141098AB9B459462F340A3521" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SecuritizationDebtClassBMember" xlink:label="loc_run_SecuritizationDebtClassBMember_7364434CF4D13D0626FF462F340A4F15" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:to="loc_run_SecuritizationDebtClassBMember_7364434CF4D13D0626FF462F340A4F15" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SRECLoansMember" xlink:label="loc_run_SRECLoansMember_E9D8704D2A118DE2775C462F340A38C0" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_0F3F1F2945C9EFDDC1E9462F340AF944" xlink:to="loc_run_SRECLoansMember_E9D8704D2A118DE2775C462F340A38C0" 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_C508BFF8892B752FF6BD462F340A6D6D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_124C3FC5242A4A3E6272462F34096A48" xlink:to="loc_us-gaap_CreditFacilityAxis_C508BFF8892B752FF6BD462F340A6D6D" 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_7B89332EF1DF75249E53462F340A4818_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_C508BFF8892B752FF6BD462F340A6D6D" xlink:to="loc_us-gaap_CreditFacilityDomain_7B89332EF1DF75249E53462F340A4818_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_7B89332EF1DF75249E53462F340A4818" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_C508BFF8892B752FF6BD462F340A6D6D" xlink:to="loc_us-gaap_CreditFacilityDomain_7B89332EF1DF75249E53462F340A4818" 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_606271FD520C688B9E8C462F340AB744" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_7B89332EF1DF75249E53462F340A4818" xlink:to="loc_us-gaap_LineOfCreditMember_606271FD520C688B9E8C462F340AB744" 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_7A7A73F2BC39750738D3462F340AF1A9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_124C3FC5242A4A3E6272462F34096A48" xlink:to="loc_us-gaap_RangeAxis_7A7A73F2BC39750738D3462F340AF1A9" 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_7192295CC4C721AFA621462F340A7219_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_7A7A73F2BC39750738D3462F340AF1A9" xlink:to="loc_us-gaap_RangeMember_7192295CC4C721AFA621462F340A7219_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_7192295CC4C721AFA621462F340A7219" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_7A7A73F2BC39750738D3462F340AF1A9" xlink:to="loc_us-gaap_RangeMember_7192295CC4C721AFA621462F340A7219" 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_C428AD3121B2FF21BF1B462F340B6552" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_7192295CC4C721AFA621462F340A7219" xlink:to="loc_us-gaap_MinimumMember_C428AD3121B2FF21BF1B462F340B6552" 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_A43C9E143E273DDBCBCA462F340B7670" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_7192295CC4C721AFA621462F340A7219" xlink:to="loc_us-gaap_MaximumMember_A43C9E143E273DDBCBCA462F340B7670" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableRateAxis" xlink:label="loc_us-gaap_VariableRateAxis_E34245C5EE4EA3A3C726462F340B4074" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_124C3FC5242A4A3E6272462F34096A48" xlink:to="loc_us-gaap_VariableRateAxis_E34245C5EE4EA3A3C726462F340B4074" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableRateDomain" xlink:label="loc_us-gaap_VariableRateDomain_76A89A172423265B14E3462F340B176B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableRateAxis_E34245C5EE4EA3A3C726462F340B4074" xlink:to="loc_us-gaap_VariableRateDomain_76A89A172423265B14E3462F340B176B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableRateDomain" xlink:label="loc_us-gaap_VariableRateDomain_76A89A172423265B14E3462F340B176B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableRateAxis_E34245C5EE4EA3A3C726462F340B4074" xlink:to="loc_us-gaap_VariableRateDomain_76A89A172423265B14E3462F340B176B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LondonInterbankOfferedRateLIBORMember" xlink:label="loc_us-gaap_LondonInterbankOfferedRateLIBORMember_60A9A53BF4A3F000E490462F340BD927" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_76A89A172423265B14E3462F340B176B" xlink:to="loc_us-gaap_LondonInterbankOfferedRateLIBORMember_60A9A53BF4A3F000E490462F340BD927" 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_E198686CFE8622994621462F340B5CBA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_LongTermDebtCurrent_E198686CFE8622994621462F340B5CBA" 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_E590C06585B46D787FBF462F340BE71C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_E590C06585B46D787FBF462F340BE71C" 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_348C815C4176EBB6E895462F340BEF0B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_LongTermDebt_348C815C4176EBB6E895462F340BEF0B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtInstrumentUnusedBorrowingCapacityAmount" xlink:label="loc_us-gaap_DebtInstrumentUnusedBorrowingCapacityAmount_C47573B6773C79C2CD53462F340B55A1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_DebtInstrumentUnusedBorrowingCapacityAmount_C47573B6773C79C2CD53462F340B55A1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DebtWeightedAverageInterestRate" xlink:label="loc_us-gaap_DebtWeightedAverageInterestRate_B843BD01859F2EBBC650462F340CCAAA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_DebtWeightedAverageInterestRate_B843BD01859F2EBBC650462F340CCAAA" 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_547DF08682440EBD77B9462F340CF193" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_A566348977F91983BF80462F340B3494" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_547DF08682440EBD77B9462F340CF193" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IndebtednessTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/Inventories" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/InventoriesScheduleOfInventoriesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/InventoriesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/Organization" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/OrganizationAdditionalInformationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/OtherAssets" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/OtherAssetsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/OtherAssetsTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/PassThroughFinancingObligations" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/PassThroughFinancingObligationsAdditionalInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_89755722A98FE5CF46DB41FF165C8B98" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_B86EA42D90FD2C35196C41FF165B9A2B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_89755722A98FE5CF46DB41FF165C8B98" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_B86EA42D90FD2C35196C41FF165B9A2B" 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_AB833908017037493F4241FF165B22B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_B86EA42D90FD2C35196C41FF165B9A2B" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_AB833908017037493F4241FF165B22B8" 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_D444E24ADDB64A90C82441FF165B1AB6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_AB833908017037493F4241FF165B22B8" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_D444E24ADDB64A90C82441FF165B1AB6_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_D444E24ADDB64A90C82441FF165B1AB6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_AB833908017037493F4241FF165B22B8" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_D444E24ADDB64A90C82441FF165B1AB6" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SolarEnergySystemsUnderLeasePassThroughArrangementsMember" xlink:label="loc_run_SolarEnergySystemsUnderLeasePassThroughArrangementsMember_4234D8D793517B48AB8341FF165C3903" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_D444E24ADDB64A90C82441FF165B1AB6" xlink:to="loc_run_SolarEnergySystemsUnderLeasePassThroughArrangementsMember_4234D8D793517B48AB8341FF165C3903" 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_CA44FA225E1B3EC7848841FF165CE902" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_B86EA42D90FD2C35196C41FF165B9A2B" xlink:to="loc_us-gaap_RangeAxis_CA44FA225E1B3EC7848841FF165CE902" 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_9BCFE9006A941D10F7C041FF165CC2CA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_CA44FA225E1B3EC7848841FF165CE902" xlink:to="loc_us-gaap_RangeMember_9BCFE9006A941D10F7C041FF165CC2CA_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_9BCFE9006A941D10F7C041FF165CC2CA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_CA44FA225E1B3EC7848841FF165CE902" xlink:to="loc_us-gaap_RangeMember_9BCFE9006A941D10F7C041FF165CC2CA" 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_0EFA413C7A3B2C23A38C41FF165C6A6E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_9BCFE9006A941D10F7C041FF165CC2CA" xlink:to="loc_us-gaap_MinimumMember_0EFA413C7A3B2C23A38C41FF165C6A6E" 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_5DA871154657E41D0E3341FF165CA624" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_9BCFE9006A941D10F7C041FF165CC2CA" xlink:to="loc_us-gaap_MaximumMember_5DA871154657E41D0E3341FF165CA624" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract" xlink:label="loc_us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract_1ADD47E09FEDCFD894E541FF165CF682" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_89755722A98FE5CF46DB41FF165C8B98" xlink:to="loc_us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract_1ADD47E09FEDCFD894E541FF165CF682" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross_456ACF86EB71CCA8364741FF165C737B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_89755722A98FE5CF46DB41FF165C8B98" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross_456ACF86EB71CCA8364741FF165C737B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation_F1560D3DAE0D864098BD41FF165D563C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_89755722A98FE5CF46DB41FF165C8B98" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation_F1560D3DAE0D864098BD41FF165D563C" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_PercentageOfDiscountOnExpectedRemainingLeasePayments" xlink:label="loc_run_PercentageOfDiscountOnExpectedRemainingLeasePayments_74BA21C4D69D90CB31AE41FF165DD96A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_89755722A98FE5CF46DB41FF165C8B98" xlink:to="loc_run_PercentageOfDiscountOnExpectedRemainingLeasePayments_74BA21C4D69D90CB31AE41FF165DD96A" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsAndEquity" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsAndEquityScheduleOfChangesInRedeemableNoncontrollingInteresttotalStockholdersEquityAndNoncontrollingInterestsDetails" 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_754E9F9EDD227D0A16DC41FF187BE5EF" 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_3753706E25DED44AAF5841FF187AB112" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_MinorityInterestLineItems_754E9F9EDD227D0A16DC41FF187BE5EF" xlink:to="loc_us-gaap_MinorityInterestTable_3753706E25DED44AAF5841FF187AB112" 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_AF8D476DA43031B4DC9D41FF187A29DE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_MinorityInterestTable_3753706E25DED44AAF5841FF187AB112" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_AF8D476DA43031B4DC9D41FF187A29DE" 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_3C0F2DBEB662BBA8E72641FF187B078B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_AF8D476DA43031B4DC9D41FF187A29DE" xlink:to="loc_us-gaap_EquityComponentDomain_3C0F2DBEB662BBA8E72641FF187B078B_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_3C0F2DBEB662BBA8E72641FF187B078B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_AF8D476DA43031B4DC9D41FF187A29DE" xlink:to="loc_us-gaap_EquityComponentDomain_3C0F2DBEB662BBA8E72641FF187B078B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RedeemableNonControllingInterestsMember" xlink:label="loc_run_RedeemableNonControllingInterestsMember_60A6B9CF04CCF120981C41FF187B9A55" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_3C0F2DBEB662BBA8E72641FF187B078B" xlink:to="loc_run_RedeemableNonControllingInterestsMember_60A6B9CF04CCF120981C41FF187B9A55" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ParentMember" xlink:label="loc_us-gaap_ParentMember_1F961C3BB8250056B05E41FF187BC2B7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_3C0F2DBEB662BBA8E72641FF187B078B" xlink:to="loc_us-gaap_ParentMember_1F961C3BB8250056B05E41FF187BC2B7" 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_650566B87304207C3DFA41FF187BA781" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_3C0F2DBEB662BBA8E72641FF187B078B" xlink:to="loc_us-gaap_NoncontrollingInterestMember_650566B87304207C3DFA41FF187BA781" 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_EC2C55F587359E987B1D41FF187B132F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MinorityInterestLineItems_754E9F9EDD227D0A16DC41FF187BE5EF" xlink:to="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount" xlink:label="loc_us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount_4AF7AAFD11B68392812241FF187B911E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount_4AF7AAFD11B68392812241FF187B911E" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RedeemableNoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance" xlink:label="loc_run_RedeemableNoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance_F6312D736BAA548385FF41FF187B49AD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_run_RedeemableNoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance_F6312D736BAA548385FF41FF187B49AD" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RedeemableNoncontrollingInterestDecreaseFromDistributions" xlink:label="loc_run_RedeemableNoncontrollingInterestDecreaseFromDistributions_34C6A508AC3B4157C76141FF187BDCDD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_run_RedeemableNoncontrollingInterestDecreaseFromDistributions_34C6A508AC3B4157C76141FF187BDCDD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLossAttributableToRedeemableNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossAttributableToRedeemableNoncontrollingInterest_72A21E7C50EEB723657841FF187BDB2F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_NetIncomeLossAttributableToRedeemableNoncontrollingInterest_72A21E7C50EEB723657841FF187BDB2F" 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_83A93F6A8DF88C20F71141FF187C97FE" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_83A93F6A8DF88C20F71141FF187C97FE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodNetOfTax" xlink:label="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodNetOfTax_F2AB3D55DCA7A09FDEE141FF187CBE88" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodNetOfTax_F2AB3D55DCA7A09FDEE141FF187CBE88" 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_F712F5DBCF85CEA6744841FF187CB6EC" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_F712F5DBCF85CEA6744841FF187CB6EC" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RestrictedStockValueShareIssuedNetOfTaxWithholdings" xlink:label="loc_run_RestrictedStockValueShareIssuedNetOfTaxWithholdings_2B5756CA18ED21F69FF341FF187CE75E" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_run_RestrictedStockValueShareIssuedNetOfTaxWithholdings_2B5756CA18ED21F69FF341FF187CE75E" 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_D86C01505642225684AB41FF187C60E9" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue_D86C01505642225684AB41FF187C60E9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance" xlink:label="loc_us-gaap_NoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance_2EE47F37DF7611000ED041FF187C3655" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_NoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance_2EE47F37DF7611000ED041FF187C3655" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MinorityInterestDecreaseFromDistributionsToNoncontrollingInterestHolders" xlink:label="loc_us-gaap_MinorityInterestDecreaseFromDistributionsToNoncontrollingInterestHolders_BF8A1407FAC815591A9B41FF187CAB91" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_MinorityInterestDecreaseFromDistributionsToNoncontrollingInterestHolders_BF8A1407FAC815591A9B41FF187CAB91" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetIncomeLossIncludingPortionAttributableToNonredeemableNoncontrollingInterest" xlink:label="loc_us-gaap_NetIncomeLossIncludingPortionAttributableToNonredeemableNoncontrollingInterest_62B5E023F29E6B7B1EE141FF187CFD32" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_NetIncomeLossIncludingPortionAttributableToNonredeemableNoncontrollingInterest_62B5E023F29E6B7B1EE141FF187CFD32" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_529A638ACF843145139441FF188283B3" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_529A638ACF843145139441FF188283B3" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_NumberofFundsCarryingValueAdjustedtoRedemptionValue" xlink:label="loc_run_NumberofFundsCarryingValueAdjustedtoRedemptionValue_7B12D953682C4B6018F741FF18820BDD" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_MovementInMinorityInterestRollForward_EC2C55F587359E987B1D41FF187B132F" xlink:to="loc_run_NumberofFundsCarryingValueAdjustedtoRedemptionValue_7B12D953682C4B6018F741FF18820BDD" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsAndEquityTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SolarEnergySystemsNet" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SolarEnergySystemsNetAdditionalInformationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SolarEnergySystemsNetDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_9A83FF1D49B1B088DE4941FF171D8F7D" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_3F16D618B3C0D535951141FF171CE016" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_9A83FF1D49B1B088DE4941FF171D8F7D" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_3F16D618B3C0D535951141FF171CE016" 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_67DEB0E5DBA1840C911341FF171CB67B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_3F16D618B3C0D535951141FF171CE016" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_67DEB0E5DBA1840C911341FF171CB67B" 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_BEA69E7C860B49E9FDF441FF171C1298_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_67DEB0E5DBA1840C911341FF171CB67B" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BEA69E7C860B49E9FDF441FF171C1298_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_BEA69E7C860B49E9FDF441FF171C1298" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_67DEB0E5DBA1840C911341FF171CB67B" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BEA69E7C860B49E9FDF441FF171C1298" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EquipmentMember" xlink:label="loc_us-gaap_EquipmentMember_FB9EEEEE61092522614941FF171CA85F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BEA69E7C860B49E9FDF441FF171C1298" xlink:to="loc_us-gaap_EquipmentMember_FB9EEEEE61092522614941FF171CA85F" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_InvertersMember" xlink:label="loc_run_InvertersMember_7FE60DA8C1661849022041FF171DA1DB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BEA69E7C860B49E9FDF441FF171C1298" xlink:to="loc_run_InvertersMember_7FE60DA8C1661849022041FF171DA1DB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross_928C01BEDDA853AEE13941FF171DE12B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_9A83FF1D49B1B088DE4941FF171D8F7D" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross_928C01BEDDA853AEE13941FF171DE12B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation_521E3D57C859E4BC1AC541FF17222475" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_9A83FF1D49B1B088DE4941FF171D8F7D" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation_521E3D57C859E4BC1AC541FF17222475" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConstructionInProgressGross" xlink:label="loc_us-gaap_ConstructionInProgressGross_88068A95BC8897F427C641FF1722DB2F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_9A83FF1D49B1B088DE4941FF171D8F7D" xlink:to="loc_us-gaap_ConstructionInProgressGross_88068A95BC8897F427C641FF1722DB2F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_58B8BDD20D7FADDF77A741FF17226DFE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_9A83FF1D49B1B088DE4941FF171D8F7D" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_58B8BDD20D7FADDF77A741FF17226DFE" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SolarEnergySystemsNetTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensation" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationAdditionalInformationDetails" 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_110DAAE276053394741141FF183AD986" 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_3359E73F04D98DCEA7CC41FF183449BD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_110DAAE276053394741141FF183AD986" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_3359E73F04D98DCEA7CC41FF183449BD" 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_PlanNameAxis" xlink:label="loc_us-gaap_PlanNameAxis_5418620FBFF466134E3941FF1835195C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_3359E73F04D98DCEA7CC41FF183449BD" xlink:to="loc_us-gaap_PlanNameAxis_5418620FBFF466134E3941FF1835195C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PlanNameDomain" xlink:label="loc_us-gaap_PlanNameDomain_79E78716ADA569C48D1C41FF183564B9_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PlanNameAxis_5418620FBFF466134E3941FF1835195C" xlink:to="loc_us-gaap_PlanNameDomain_79E78716ADA569C48D1C41FF183564B9_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PlanNameDomain" xlink:label="loc_us-gaap_PlanNameDomain_79E78716ADA569C48D1C41FF183564B9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PlanNameAxis_5418620FBFF466134E3941FF1835195C" xlink:to="loc_us-gaap_PlanNameDomain_79E78716ADA569C48D1C41FF183564B9" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_EmployeeStockPurchasePlanMember" xlink:label="loc_run_EmployeeStockPurchasePlanMember_69FE5A0B628EBC047D0041FF1835367A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_79E78716ADA569C48D1C41FF183564B9" xlink:to="loc_run_EmployeeStockPurchasePlanMember_69FE5A0B628EBC047D0041FF1835367A" 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_4D09B7A5191C91CB157E41FF183A08B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_110DAAE276053394741141FF183AD986" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_4D09B7A5191C91CB157E41FF183A08B6" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofPurchasePeriods" xlink:label="loc_run_SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofPurchasePeriods_6D586964D9D81E54393A41FF183AD8D0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_110DAAE276053394741141FF183AD986" xlink:to="loc_run_SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofPurchasePeriods_6D586964D9D81E54393A41FF183AD8D0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumEmployeeSubscriptionRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumEmployeeSubscriptionRate_3387CE4A233FEFAAB31641FF183AEC82" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_110DAAE276053394741141FF183AD986" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumEmployeeSubscriptionRate_3387CE4A233FEFAAB31641FF183AEC82" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumDeductibleFairMarketValueOfSharesPerCalendarYear" xlink:label="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumDeductibleFairMarketValueOfSharesPerCalendarYear_4363DC3A8B964E0BEDC641FF183B9E88" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_110DAAE276053394741141FF183AD986" xlink:to="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumDeductibleFairMarketValueOfSharesPerCalendarYear_4363DC3A8B964E0BEDC641FF183B9E88" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumNumberOfSharesPerEmployee" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumNumberOfSharesPerEmployee_E1096B2D695488AD0DE441FF183BFC2C" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_110DAAE276053394741141FF183AD986" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumNumberOfSharesPerEmployee_E1096B2D695488AD0DE441FF183BFC2C" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationSummaryOfActivityForAllRestrictedStockUnitsRsusDetails" 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_7C42FC8724AFDAC6243B41FF164609DC" 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_1F2D27B016882D85106041FF16455DE3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_7C42FC8724AFDAC6243B41FF164609DC" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_1F2D27B016882D85106041FF16455DE3" 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_3808D0A25046F9B9342941FF1645A8B2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_1F2D27B016882D85106041FF16455DE3" xlink:to="loc_us-gaap_AwardTypeAxis_3808D0A25046F9B9342941FF1645A8B2" 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_539E14D35A181A2A2CD241FF1646C55A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_3808D0A25046F9B9342941FF1645A8B2" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_539E14D35A181A2A2CD241FF1646C55A_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_539E14D35A181A2A2CD241FF1646C55A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_3808D0A25046F9B9342941FF1645A8B2" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_539E14D35A181A2A2CD241FF1646C55A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestrictedStockUnitsRSUMember" xlink:label="loc_us-gaap_RestrictedStockUnitsRSUMember_4F23ED18BB03AE815F9B41FF1646EF8B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_539E14D35A181A2A2CD241FF1646C55A" xlink:to="loc_us-gaap_RestrictedStockUnitsRSUMember_4F23ED18BB03AE815F9B41FF1646EF8B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_7C42FC8724AFDAC6243B41FF164609DC" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" 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_94A3722A2C9836A4D56641FF164670CE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_94A3722A2C9836A4D56641FF164670CE" 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_730EA22FFDC6CFF721EA41FF16461A20" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_730EA22FFDC6CFF721EA41FF16461A20" 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_BDA1B742557F1B99160341FF1646834D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_BDA1B742557F1B99160341FF1646834D" 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_F107E0A400492C7E1C7B41FF1646EFE3" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_F107E0A400492C7E1C7B41FF1646EFE3" 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_A01221945D558B8B6E5641FF16475F9A" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_A01221945D558B8B6E5641FF16475F9A" 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_4DBF227501B5DAB9E85F41FF16474822" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_4DBF227501B5DAB9E85F41FF16474822" 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_D1B2B9EABEA11E8E777B41FF1647EDC3" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_D1B2B9EABEA11E8E777B41FF1647EDC3" 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_539B853C7C87341559A441FF16471A9F" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_84FB755D08D925A23D7641FF1646DED0" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_539B853C7C87341559A441FF16471A9F" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockBasedCompensationExpenseAdditionalDetailsDetails" 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_1AA39C13B9850F796BEA4202BC33CCE0" 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_7143CEECBDB7C713F1CA4202BC33E848" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_7143CEECBDB7C713F1CA4202BC33E848" 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_735267D8E879E4C1EF374202BC33A5BC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_7143CEECBDB7C713F1CA4202BC33E848" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_735267D8E879E4C1EF374202BC33A5BC" 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_283E67E785AEA44EF5BB4202BC33340A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_735267D8E879E4C1EF374202BC33A5BC" xlink:to="loc_us-gaap_EquityComponentDomain_283E67E785AEA44EF5BB4202BC33340A_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_283E67E785AEA44EF5BB4202BC33340A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_735267D8E879E4C1EF374202BC33A5BC" xlink:to="loc_us-gaap_EquityComponentDomain_283E67E785AEA44EF5BB4202BC33340A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WarrantMember" xlink:label="loc_us-gaap_WarrantMember_4278E9E63FFA43F63BCC4202BC33C019" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_283E67E785AEA44EF5BB4202BC33340A" xlink:to="loc_us-gaap_WarrantMember_4278E9E63FFA43F63BCC4202BC33C019" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ClassofWarrantorRightTerm" xlink:label="loc_run_ClassofWarrantorRightTerm_21ADFB6D1C095FDE374D4202BC331E21" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_run_ClassofWarrantorRightTerm_21ADFB6D1C095FDE374D4202BC331E21" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfWarrantOrRightNumberOfSecuritiesCalledByWarrantsOrRights" xlink:label="loc_us-gaap_ClassOfWarrantOrRightNumberOfSecuritiesCalledByWarrantsOrRights_B98E56EA55B73B64FBA04202BC34D886" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_us-gaap_ClassOfWarrantOrRightNumberOfSecuritiesCalledByWarrantsOrRights_B98E56EA55B73B64FBA04202BC34D886" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfWarrantOrRightExercisePriceOfWarrantsOrRights1" xlink:label="loc_us-gaap_ClassOfWarrantOrRightExercisePriceOfWarrantsOrRights1_17DD8A4E9F902B55E84A4202BC346FCA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_us-gaap_ClassOfWarrantOrRightExercisePriceOfWarrantsOrRights1_17DD8A4E9F902B55E84A4202BC346FCA" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ClassofWarrantorRightVestingPercentage" xlink:label="loc_run_ClassofWarrantorRightVestingPercentage_4FA023567889CD60D5964202BC34353D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_run_ClassofWarrantorRightVestingPercentage_4FA023567889CD60D5964202BC34353D" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ClassofWarrantorRightMilestoneOne" xlink:label="loc_run_ClassofWarrantorRightMilestoneOne_468EED04A76967301E914202BC34C80D" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_run_ClassofWarrantorRightMilestoneOne_468EED04A76967301E914202BC34C80D" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ClassofWarrantorRightMilestoneOneDollarValue" xlink:label="loc_run_ClassofWarrantorRightMilestoneOneDollarValue_E43801705D59CD738C9E4202BC34C6C9" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_run_ClassofWarrantorRightMilestoneOneDollarValue_E43801705D59CD738C9E4202BC34C6C9" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ClassofWarrantorRightVestingTerm" xlink:label="loc_run_ClassofWarrantorRightVestingTerm_ECCA20C7578CD4117EF54202BC3400C5" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_run_ClassofWarrantorRightVestingTerm_ECCA20C7578CD4117EF54202BC3400C5" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ClassofWarrantorRightMilestoneTwo" xlink:label="loc_run_ClassofWarrantorRightMilestoneTwo_5C683A633349391F3CB44202BC34D24F" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_1AA39C13B9850F796BEA4202BC33CCE0" xlink:to="loc_run_ClassofWarrantorRightMilestoneTwo_5C683A633349391F3CB44202BC34D24F" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockBasedCompensationExpenseDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems_E7EBCB7F21D5EC46024D462F33C00E28" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable" xlink:label="loc_us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable_A61CAED5D68C5344D2EE462F33BF480C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems_E7EBCB7F21D5EC46024D462F33C00E28" xlink:to="loc_us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable_A61CAED5D68C5344D2EE462F33BF480C" 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_3763E08F05E0656F2A48462F33BF0190" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable_A61CAED5D68C5344D2EE462F33BF480C" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_3763E08F05E0656F2A48462F33BF0190" 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_1B0EB318BC4C614CF663462F33BF7734_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_3763E08F05E0656F2A48462F33BF0190" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734_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_1B0EB318BC4C614CF663462F33BF7734" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_3763E08F05E0656F2A48462F33BF0190" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_CostOfOperatingLeasesAndIncentivesMember" xlink:label="loc_run_CostOfOperatingLeasesAndIncentivesMember_8F96D5074E84FFC78CE8462F33BFFE0D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734" xlink:to="loc_run_CostOfOperatingLeasesAndIncentivesMember_8F96D5074E84FFC78CE8462F33BFFE0D" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_CostOfSolarEnergySystemsAndProductSalesMember" xlink:label="loc_run_CostOfSolarEnergySystemsAndProductSalesMember_6E2C604A3E2E6AEE4F11462F33BF336C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734" xlink:to="loc_run_CostOfSolarEnergySystemsAndProductSalesMember_6E2C604A3E2E6AEE4F11462F33BF336C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingAndMarketingExpenseMember" xlink:label="loc_us-gaap_SellingAndMarketingExpenseMember_5BF2A7D62D47967D4EE2462F33BFC4DD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734" xlink:to="loc_us-gaap_SellingAndMarketingExpenseMember_5BF2A7D62D47967D4EE2462F33BFC4DD" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ResearchAndDevelopmentExpenseMember" xlink:label="loc_us-gaap_ResearchAndDevelopmentExpenseMember_A2C777D0119CD8422F0D462F33C0C03F" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734" xlink:to="loc_us-gaap_ResearchAndDevelopmentExpenseMember_A2C777D0119CD8422F0D462F33C0C03F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GeneralAndAdministrativeExpenseMember" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpenseMember_90B7BC8E58F13653FAA0462F33C0A631" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_1B0EB318BC4C614CF663462F33BF7734" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpenseMember_90B7BC8E58F13653FAA0462F33C0A631" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AllocatedShareBasedCompensationExpense" xlink:label="loc_us-gaap_AllocatedShareBasedCompensationExpense_00165C9AF6D08EFB34AF462F33C054DA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems_E7EBCB7F21D5EC46024D462F33C00E28" xlink:to="loc_us-gaap_AllocatedShareBasedCompensationExpense_00165C9AF6D08EFB34AF462F33C054DA" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockOptionActivityDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPolicies" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdditionalInformationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842BalanceSheetDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems" xlink:label="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable" xlink:label="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_399FA60D51C6D8F4A990461EBFA282F1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_399FA60D51C6D8F4A990461EBFA282F1" 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_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_039D730F520EB4B02896461EBFA2A72A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_399FA60D51C6D8F4A990461EBFA282F1" xlink:to="loc_us-gaap_StatementScenarioAxis_039D730F520EB4B02896461EBFA2A72A" 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_A62FB7E286396873C208461EBFA2C44A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_039D730F520EB4B02896461EBFA2A72A" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_A62FB7E286396873C208461EBFA2C44A_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_A62FB7E286396873C208461EBFA2C44A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_039D730F520EB4B02896461EBFA2A72A" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_A62FB7E286396873C208461EBFA2C44A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioPreviouslyReportedMember" xlink:label="loc_us-gaap_ScenarioPreviouslyReportedMember_8C1A29F86F1500D959A2461EBFA2770C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_A62FB7E286396873C208461EBFA2C44A" xlink:to="loc_us-gaap_ScenarioPreviouslyReportedMember_8C1A29F86F1500D959A2461EBFA2770C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestatementAdjustmentMember" xlink:label="loc_us-gaap_RestatementAdjustmentMember_287C6F4D81FDAF39C0CA461EBFA38259" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_A62FB7E286396873C208461EBFA2C44A" xlink:to="loc_us-gaap_RestatementAdjustmentMember_287C6F4D81FDAF39C0CA461EBFA38259" xlink:type="arc" />
    <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_064BB1464AC9BDF6E8B1461EBFA327D4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_399FA60D51C6D8F4A990461EBFA282F1" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_064BB1464AC9BDF6E8B1461EBFA327D4" 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_FC87C757448BBBC3B798461EBFA30114_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_064BB1464AC9BDF6E8B1461EBFA327D4" xlink:to="loc_us-gaap_TypeOfAdoptionMember_FC87C757448BBBC3B798461EBFA30114_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_FC87C757448BBBC3B798461EBFA30114" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_064BB1464AC9BDF6E8B1461EBFA327D4" xlink:to="loc_us-gaap_TypeOfAdoptionMember_FC87C757448BBBC3B798461EBFA30114" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member" xlink:label="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_BF6A35F95A637593049B4629CA616B55" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_FC87C757448BBBC3B798461EBFA30114" xlink:to="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_BF6A35F95A637593049B4629CA616B55" 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_97464031F0ACEDC9E457461EBFA3FF5D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_97464031F0ACEDC9E457461EBFA3FF5D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_B3B92F4266A8F29B5E09461EBFA3DF35" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_B3B92F4266A8F29B5E09461EBFA3DF35" 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_B7A681CBB60AF134A157461EBFA3A632" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_B7A681CBB60AF134A157461EBFA3A632" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccruedLiabilitiesAndOtherLiabilities" xlink:label="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_56A9100CDFA04409000F461EBFA3D4B1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_56A9100CDFA04409000F461EBFA3D4B1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueCurrent" xlink:label="loc_us-gaap_DeferredRevenueCurrent_AAE04245919C0F4411F3461EBFA34CAA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_DeferredRevenueCurrent_AAE04245919C0F4411F3461EBFA34CAA" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredGrantCurrentPortion" xlink:label="loc_run_DeferredGrantCurrentPortion_320A5CDC6C5032B6A66F461EBFA3CBF7" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_run_DeferredGrantCurrentPortion_320A5CDC6C5032B6A66F461EBFA3CBF7" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_LeasePassThroughFinancingObligationCurrentPortion" xlink:label="loc_run_LeasePassThroughFinancingObligationCurrentPortion_6A1CC806C1593CACA630461EBFA35371" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_run_LeasePassThroughFinancingObligationCurrentPortion_6A1CC806C1593CACA630461EBFA35371" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueNoncurrent" xlink:label="loc_us-gaap_DeferredRevenueNoncurrent_84A9C12393362EBA07C3461EBFA36C0A" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_DeferredRevenueNoncurrent_84A9C12393362EBA07C3461EBFA36C0A" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredGrantIncomeNoncurrent" xlink:label="loc_run_DeferredGrantIncomeNoncurrent_7A8A5FE4C1A2D305453C461EBFA38E93" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_run_DeferredGrantIncomeNoncurrent_7A8A5FE4C1A2D305453C461EBFA38E93" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_LeasePassThroughFinancingObligationNetOfCurrentPortion" xlink:label="loc_run_LeasePassThroughFinancingObligationNetOfCurrentPortion_B7845BBFB1A6CD3020C7461EBFA3FE74" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_run_LeasePassThroughFinancingObligationNetOfCurrentPortion_B7845BBFB1A6CD3020C7461EBFA3FE74" 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_EC609149F979458F3A51461EBFA3440F" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_EC609149F979458F3A51461EBFA3440F" 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_4F234651DF324CF4D474461EBFA3FA96" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_DeferredTaxLiabilitiesNoncurrent_4F234651DF324CF4D474461EBFA3FA96" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount" xlink:label="loc_us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount_3C25A8F0C716D69322C8461EBFA3D97B" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount_3C25A8F0C716D69322C8461EBFA3D97B" 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_4A1CB01BD0C8A81CBA74461EBFA3BEEE" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_AdditionalPaidInCapital_4A1CB01BD0C8A81CBA74461EBFA3BEEE" 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_4CEF22C85749967C1DE0461EBFA32266" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_4CEF22C85749967C1DE0461EBFA32266" 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_6848AC112B9E106144F4461EBFA4F4BB" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_2CF751C003596D883613461EBFA36206" xlink:to="loc_us-gaap_MinorityInterest_6848AC112B9E106144F4461EBFA4F4BB" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842CashFlowsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems" xlink:label="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable" xlink:label="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_9383649FF659E5E37DF4461EBF98F9AA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_9383649FF659E5E37DF4461EBF98F9AA" 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_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_83FCB6085E610359EFE5461EBF984307" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_9383649FF659E5E37DF4461EBF98F9AA" xlink:to="loc_us-gaap_StatementScenarioAxis_83FCB6085E610359EFE5461EBF984307" 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_889A7CB0C42DCA0304E8461EBF98E492_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_83FCB6085E610359EFE5461EBF984307" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_889A7CB0C42DCA0304E8461EBF98E492_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_889A7CB0C42DCA0304E8461EBF98E492" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_83FCB6085E610359EFE5461EBF984307" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_889A7CB0C42DCA0304E8461EBF98E492" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioPreviouslyReportedMember" xlink:label="loc_us-gaap_ScenarioPreviouslyReportedMember_5CD4D3B8D2792607EE23461EBF986E95" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_889A7CB0C42DCA0304E8461EBF98E492" xlink:to="loc_us-gaap_ScenarioPreviouslyReportedMember_5CD4D3B8D2792607EE23461EBF986E95" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestatementAdjustmentMember" xlink:label="loc_us-gaap_RestatementAdjustmentMember_2CC222708C74881FFDFA461EBF98E037" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_889A7CB0C42DCA0304E8461EBF98E492" xlink:to="loc_us-gaap_RestatementAdjustmentMember_2CC222708C74881FFDFA461EBF98E037" xlink:type="arc" />
    <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_19873F89B1A456CDF686461EBF98D2C6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_9383649FF659E5E37DF4461EBF98F9AA" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_19873F89B1A456CDF686461EBF98D2C6" 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_C891003A740807A9DAF8461EBF980C2B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_19873F89B1A456CDF686461EBF98D2C6" xlink:to="loc_us-gaap_TypeOfAdoptionMember_C891003A740807A9DAF8461EBF980C2B_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_C891003A740807A9DAF8461EBF980C2B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_19873F89B1A456CDF686461EBF98D2C6" xlink:to="loc_us-gaap_TypeOfAdoptionMember_C891003A740807A9DAF8461EBF980C2B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_AccountingStandardsUpdate201409AccountingStandardsUpdate201602AccountingStandardsUpdate201618Member" xlink:label="loc_run_AccountingStandardsUpdate201409AccountingStandardsUpdate201602AccountingStandardsUpdate201618Member_213BC0E7FD3F4E429CC7462C54C21B95" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_C891003A740807A9DAF8461EBF980C2B" xlink:to="loc_run_AccountingStandardsUpdate201409AccountingStandardsUpdate201602AccountingStandardsUpdate201618Member_213BC0E7FD3F4E429CC7462C54C21B95" 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_8B4F26053B57F8A869FA461EBF99E8A3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_ProfitLoss_8B4F26053B57F8A869FA461EBF99E8A3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations_36718006E496BB258A63461EBF99F7DC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations_36718006E496BB258A63461EBF99F7DC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations_FED3639DC008D50EBAA0461EBF997CD7" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations_FED3639DC008D50EBAA0461EBF997CD7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations_91DDFBCC558D7737C296461EBF9948FF" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations_91DDFBCC558D7737C296461EBF9948FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_87F7E20C4107510332C2461EBF995132" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_87F7E20C4107510332C2461EBF995132" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_F039FA9634FB6CCF9C54461EBF9966AD" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_46A2E3330DFEA0E8D706461EBF98CB31" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_F039FA9634FB6CCF9C54461EBF9966AD" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842StatementOfOperationsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems" xlink:label="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable" xlink:label="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_61E6853C2206BEF1FE86461EBF9DDA68" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_61E6853C2206BEF1FE86461EBF9DDA68" 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_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_BF6A32CE85BCF72B19ED461EBF9D863B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_61E6853C2206BEF1FE86461EBF9DDA68" xlink:to="loc_us-gaap_StatementScenarioAxis_BF6A32CE85BCF72B19ED461EBF9D863B" 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_21A8C688A3333122D3C8461EBF9D65A7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_BF6A32CE85BCF72B19ED461EBF9D863B" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_21A8C688A3333122D3C8461EBF9D65A7_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_21A8C688A3333122D3C8461EBF9D65A7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_BF6A32CE85BCF72B19ED461EBF9D863B" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_21A8C688A3333122D3C8461EBF9D65A7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioPreviouslyReportedMember" xlink:label="loc_us-gaap_ScenarioPreviouslyReportedMember_EB20CA514753B76150F2461EBF9DD339" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_21A8C688A3333122D3C8461EBF9D65A7" xlink:to="loc_us-gaap_ScenarioPreviouslyReportedMember_EB20CA514753B76150F2461EBF9DD339" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestatementAdjustmentMember" xlink:label="loc_us-gaap_RestatementAdjustmentMember_64C974C95D79AB6C2B2E461EBF9D5C59" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_21A8C688A3333122D3C8461EBF9D65A7" xlink:to="loc_us-gaap_RestatementAdjustmentMember_64C974C95D79AB6C2B2E461EBF9D5C59" xlink:type="arc" />
    <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_D2AA9969E1E0C1AE9EE4461EBF9D2881" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_61E6853C2206BEF1FE86461EBF9DDA68" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_D2AA9969E1E0C1AE9EE4461EBF9D2881" 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_AF8B407B62B112CB9793461EBF9D6DB9_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_D2AA9969E1E0C1AE9EE4461EBF9D2881" xlink:to="loc_us-gaap_TypeOfAdoptionMember_AF8B407B62B112CB9793461EBF9D6DB9_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_AF8B407B62B112CB9793461EBF9D6DB9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_D2AA9969E1E0C1AE9EE4461EBF9D2881" xlink:to="loc_us-gaap_TypeOfAdoptionMember_AF8B407B62B112CB9793461EBF9D6DB9" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member" xlink:label="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_76FB4C30D1A4CC26D9E5462AE3D83F84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_AF8B407B62B112CB9793461EBF9D6DB9" xlink:to="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_76FB4C30D1A4CC26D9E5462AE3D83F84" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingLeasesIncomeStatementLeaseRevenue" xlink:label="loc_us-gaap_OperatingLeasesIncomeStatementLeaseRevenue_8B81680EE7EEE5A63C8D461EBF9D8F29" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_OperatingLeasesIncomeStatementLeaseRevenue_8B81680EE7EEE5A63C8D461EBF9D8F29" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_CostOfRevenueForOperatingLeasesAndIncentives" xlink:label="loc_run_CostOfRevenueForOperatingLeasesAndIncentives_3CA173175D336714B3B5461EBF9D1545" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_run_CostOfRevenueForOperatingLeasesAndIncentives_3CA173175D336714B3B5461EBF9D1545" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SellingAndMarketingExpense" xlink:label="loc_us-gaap_SellingAndMarketingExpense_184A96661E272B2F8BEE461EBF9D33E7" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_SellingAndMarketingExpense_184A96661E272B2F8BEE461EBF9D33E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_GeneralAndAdministrativeExpense" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpense_76AC37441C3F9683D5BF461EBF9D4C97" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_76AC37441C3F9683D5BF461EBF9D4C97" 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_CD0A58FC349DDACA54A4461EBF9DFEDD" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_CD0A58FC349DDACA54A4461EBF9DFEDD" 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_892C0E64A229F2010A17461EBF9D104D" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_892C0E64A229F2010A17461EBF9D104D" 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_D6ED4F7FEB13BDD6D3DC461EBF9D4EE2" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_ProfitLoss_D6ED4F7FEB13BDD6D3DC461EBF9D4EE2" 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_0014175486F03E690646461EBF9D8BF7" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_0014175486F03E690646461EBF9D8BF7" 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_1984ADCC97C268EDCEB6461EBF9E64CE" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_NetIncomeLoss_1984ADCC97C268EDCEB6461EBF9E64CE" 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_55CF28DB32DE79DB1215461EBF9E89B3" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_EarningsPerShareBasic_55CF28DB32DE79DB1215461EBF9E89B3" 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_C7186C9BA2FF0339570E461EBF9E7CC7" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_6176828A126785F46AFD461EBF9D1D06" xlink:to="loc_us-gaap_EarningsPerShareDiluted_C7186C9BA2FF0339570E461EBF9E7CC7" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesCashAndRestrictedCashDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesDeferredRevenueDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueArrangementLineItems" xlink:label="loc_us-gaap_DeferredRevenueArrangementLineItems_593E3987220EC8E07B36425A719081FF" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueArrangementByTypeTable" xlink:label="loc_us-gaap_DeferredRevenueArrangementByTypeTable_FDC323035027A253DE12425A718C3950" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_593E3987220EC8E07B36425A719081FF" xlink:to="loc_us-gaap_DeferredRevenueArrangementByTypeTable_FDC323035027A253DE12425A718C3950" 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_DeferredRevenueArrangementTypeAxis" xlink:label="loc_us-gaap_DeferredRevenueArrangementTypeAxis_F9CCF41FBE7E231360D5425A718D4220" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DeferredRevenueArrangementByTypeTable_FDC323035027A253DE12425A718C3950" xlink:to="loc_us-gaap_DeferredRevenueArrangementTypeAxis_F9CCF41FBE7E231360D5425A718D4220" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueArrangementTypeDomain" xlink:label="loc_us-gaap_DeferredRevenueArrangementTypeDomain_04FA509A6824FE9FB41E425A718D598B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeAxis_F9CCF41FBE7E231360D5425A718D4220" xlink:to="loc_us-gaap_DeferredRevenueArrangementTypeDomain_04FA509A6824FE9FB41E425A718D598B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueArrangementTypeDomain" xlink:label="loc_us-gaap_DeferredRevenueArrangementTypeDomain_04FA509A6824FE9FB41E425A718D598B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeAxis_F9CCF41FBE7E231360D5425A718D4220" xlink:to="loc_us-gaap_DeferredRevenueArrangementTypeDomain_04FA509A6824FE9FB41E425A718D598B" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_PaymentsUnderCustomerAgreementsMember" xlink:label="loc_run_PaymentsUnderCustomerAgreementsMember_464F97C0CC1CFBEA40F1425A718DF765" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeDomain_04FA509A6824FE9FB41E425A718D598B" xlink:to="loc_run_PaymentsUnderCustomerAgreementsMember_464F97C0CC1CFBEA40F1425A718DF765" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SRECContractsMember" xlink:label="loc_run_SRECContractsMember_EA17C99BF9CBC1017F13425A718FE014" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeDomain_04FA509A6824FE9FB41E425A718D598B" xlink:to="loc_run_SRECContractsMember_EA17C99BF9CBC1017F13425A718FE014" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredRevenueStatusAxis" xlink:label="loc_run_DeferredRevenueStatusAxis_35319DFEFD943DF00C1642612C9082F9" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DeferredRevenueArrangementByTypeTable_FDC323035027A253DE12425A718C3950" xlink:to="loc_run_DeferredRevenueStatusAxis_35319DFEFD943DF00C1642612C9082F9" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredRevenueStatusDomain" xlink:label="loc_run_DeferredRevenueStatusDomain_9B55204724B3924CE5BE42612C942657_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_run_DeferredRevenueStatusAxis_35319DFEFD943DF00C1642612C9082F9" xlink:to="loc_run_DeferredRevenueStatusDomain_9B55204724B3924CE5BE42612C942657_default" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredRevenueStatusDomain" xlink:label="loc_run_DeferredRevenueStatusDomain_9B55204724B3924CE5BE42612C942657" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_run_DeferredRevenueStatusAxis_35319DFEFD943DF00C1642612C9082F9" xlink:to="loc_run_DeferredRevenueStatusDomain_9B55204724B3924CE5BE42612C942657" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_PaymentsReceivedMember" xlink:label="loc_run_PaymentsReceivedMember_9212772685323D52EDF94261A97DE854" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_DeferredRevenueStatusDomain_9B55204724B3924CE5BE42612C942657" xlink:to="loc_run_PaymentsReceivedMember_9212772685323D52EDF94261A97DE854" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_FinancingMember" xlink:label="loc_run_FinancingMember_3FF8EC14C84E9ECE08654261FE50CCEA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_DeferredRevenueStatusDomain_9B55204724B3924CE5BE42612C942657" xlink:to="loc_run_FinancingMember_3FF8EC14C84E9ECE08654261FE50CCEA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenue" xlink:label="loc_us-gaap_DeferredRevenue_E6043CC254FEE04D232E425A719022DA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_593E3987220EC8E07B36425A719081FF" xlink:to="loc_us-gaap_DeferredRevenue_E6043CC254FEE04D232E425A719022DA" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesScheduleOfRevenuesFromExternalCustomersDetails" 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_31D7EAE188EFF108630C41FF1661572F" 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_E6B97BF0864009DCEF9841FF1661911E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_31D7EAE188EFF108630C41FF1661572F" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_E6B97BF0864009DCEF9841FF1661911E" 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_ProductOrServiceAxis" xlink:label="loc_us-gaap_ProductOrServiceAxis_E07672CD6490790AAE5041FF16616896" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_E6B97BF0864009DCEF9841FF1661911E" xlink:to="loc_us-gaap_ProductOrServiceAxis_E07672CD6490790AAE5041FF16616896" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProductsAndServicesDomain" xlink:label="loc_us-gaap_ProductsAndServicesDomain_BD794B2BC8385007F97A41FF16615984_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_E07672CD6490790AAE5041FF16616896" xlink:to="loc_us-gaap_ProductsAndServicesDomain_BD794B2BC8385007F97A41FF16615984_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProductsAndServicesDomain" xlink:label="loc_us-gaap_ProductsAndServicesDomain_BD794B2BC8385007F97A41FF16615984" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_E07672CD6490790AAE5041FF16616896" xlink:to="loc_us-gaap_ProductsAndServicesDomain_BD794B2BC8385007F97A41FF16615984" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_SolarEnergySystemsMember" xlink:label="loc_run_SolarEnergySystemsMember_1CA1D62C5865A03FCFB841FF1661672E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_BD794B2BC8385007F97A41FF16615984" xlink:to="loc_run_SolarEnergySystemsMember_1CA1D62C5865A03FCFB841FF1661672E" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_ProductsMember" xlink:label="loc_run_ProductsMember_64B07B4429AD18C6C2BC41FF1661616C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_BD794B2BC8385007F97A41FF16615984" xlink:to="loc_run_ProductsMember_64B07B4429AD18C6C2BC41FF1661616C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingLeasesIncomeStatementMinimumLeaseRevenue" xlink:label="loc_us-gaap_OperatingLeasesIncomeStatementMinimumLeaseRevenue_04F359D36EB9EB6C435441FF166281E9" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_31D7EAE188EFF108630C41FF1661572F" xlink:to="loc_us-gaap_OperatingLeasesIncomeStatementMinimumLeaseRevenue_04F359D36EB9EB6C435441FF166281E9" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_GovernmentTaxRebatesAndOtherIncentives" xlink:label="loc_run_GovernmentTaxRebatesAndOtherIncentives_E33D88BA00FEF1EAB73941FF16627DB8" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_31D7EAE188EFF108630C41FF1661572F" xlink:to="loc_run_GovernmentTaxRebatesAndOtherIncentives_E33D88BA00FEF1EAB73941FF16627DB8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingLeasesIncomeStatementLeaseRevenue" xlink:label="loc_us-gaap_OperatingLeasesIncomeStatementLeaseRevenue_6B2A9253432FB95153F841FF16625F3D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_31D7EAE188EFF108630C41FF1661572F" xlink:to="loc_us-gaap_OperatingLeasesIncomeStatementLeaseRevenue_6B2A9253432FB95153F841FF16625F3D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SalesRevenueGoodsNet" xlink:label="loc_us-gaap_SalesRevenueGoodsNet_866DF0192957D30F6ED641FF1662BE76" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_31D7EAE188EFF108630C41FF1661572F" xlink:to="loc_us-gaap_SalesRevenueGoodsNet_866DF0192957D30F6ED641FF1662BE76" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Revenues" xlink:label="loc_us-gaap_Revenues_36A9FE599D2F95172F5C41FF1662BDC7" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_31D7EAE188EFF108630C41FF1661572F" xlink:to="loc_us-gaap_Revenues_36A9FE599D2F95172F5C41FF1662BDC7" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/VieArrangements" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/VieArrangementsCarryingAmountsAndClassificationOfViesAssetsAndLiabilitiesIncludedInConsolidatedBalanceSheetsDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableInterestEntityLineItems" xlink:label="loc_us-gaap_VariableInterestEntityLineItems_6BDD02180448BC9569B441FF16544CF6" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfVariableInterestEntitiesTable" xlink:label="loc_us-gaap_ScheduleOfVariableInterestEntitiesTable_AFA7E7BF7BCE34FCB3AD41FF16531AA7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_VariableInterestEntityLineItems_6BDD02180448BC9569B441FF16544CF6" xlink:to="loc_us-gaap_ScheduleOfVariableInterestEntitiesTable_AFA7E7BF7BCE34FCB3AD41FF16531AA7" 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_VariableInterestEntitiesByClassificationOfEntityAxis" xlink:label="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_27E0EDDA4A340916B8A741FF1654C035" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfVariableInterestEntitiesTable_AFA7E7BF7BCE34FCB3AD41FF16531AA7" xlink:to="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_27E0EDDA4A340916B8A741FF1654C035" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassificationOfVariableInterestEntityDomain" xlink:label="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_39D9FDC8980DBD5CD58C41FF1654C7F8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_27E0EDDA4A340916B8A741FF1654C035" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_39D9FDC8980DBD5CD58C41FF1654C7F8_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassificationOfVariableInterestEntityDomain" xlink:label="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_39D9FDC8980DBD5CD58C41FF1654C7F8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_27E0EDDA4A340916B8A741FF1654C035" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_39D9FDC8980DBD5CD58C41FF1654C7F8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VariableInterestEntityPrimaryBeneficiaryMember" xlink:label="loc_us-gaap_VariableInterestEntityPrimaryBeneficiaryMember_F9B940D6704D1FB99C6E41FF1654E4C2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_39D9FDC8980DBD5CD58C41FF1654C7F8" xlink:to="loc_us-gaap_VariableInterestEntityPrimaryBeneficiaryMember_F9B940D6704D1FB99C6E41FF1654E4C2" 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_360BB5EECD022A284ADA41FF1654057D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableInterestEntityLineItems_6BDD02180448BC9569B441FF16544CF6" xlink:to="loc_us-gaap_AssetsAbstract_360BB5EECD022A284ADA41FF1654057D" 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_8CBC271DD490607FB97841FF1654B263" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_360BB5EECD022A284ADA41FF1654057D" xlink:to="loc_us-gaap_AssetsCurrentAbstract_8CBC271DD490607FB97841FF1654B263" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_Cash" xlink:label="loc_us-gaap_Cash_D2DFF0FA093B870E439241FF1655135D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_8CBC271DD490607FB97841FF1654B263" xlink:to="loc_us-gaap_Cash_D2DFF0FA093B870E439241FF1655135D" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_RestrictedCashAtCarryingValue" xlink:label="loc_run_RestrictedCashAtCarryingValue_541C0264BE163ACAD55141FF1655D728" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_8CBC271DD490607FB97841FF1654B263" xlink:to="loc_run_RestrictedCashAtCarryingValue_541C0264BE163ACAD55141FF1655D728" 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_E0F4EDC7579884C9F2FC41FF16555EE0" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_8CBC271DD490607FB97841FF1654B263" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_E0F4EDC7579884C9F2FC41FF16555EE0" 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_DA826DA23576DA21EFF841FF1655E944" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_8CBC271DD490607FB97841FF1654B263" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_DA826DA23576DA21EFF841FF1655E944" 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_0BF14ED72C532926780C41FF1655C518" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_8CBC271DD490607FB97841FF1654B263" xlink:to="loc_us-gaap_AssetsCurrent_0BF14ED72C532926780C41FF1655C518" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet" xlink:label="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_F999F9AAAD502643F04C41FF1655089A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_360BB5EECD022A284ADA41FF1654057D" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_F999F9AAAD502643F04C41FF1655089A" 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_73FFACE9581840B89C7541FF165517A2" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_360BB5EECD022A284ADA41FF1654057D" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_73FFACE9581840B89C7541FF165517A2" 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_1933A73A1AB360C167DE41FF1655A8D4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_360BB5EECD022A284ADA41FF1654057D" xlink:to="loc_us-gaap_Assets_1933A73A1AB360C167DE41FF1655A8D4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LiabilitiesAbstract" xlink:label="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableInterestEntityLineItems_6BDD02180448BC9569B441FF16544CF6" xlink:to="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" 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_C09926CDE09576C1BD9341FF16554227" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:to="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" 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_5DC7DEC7CFFD2EDF06F541FF165653C2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_us-gaap_AccountsPayableCurrent_5DC7DEC7CFFD2EDF06F541FF165653C2" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests" xlink:label="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_C763657524C8AFC3F91041FF1656CA01" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_C763657524C8AFC3F91041FF1656CA01" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccruedLiabilitiesAndOtherLiabilities" xlink:label="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_7D942221B1DE91CE6C3E41FF165600C0" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_7D942221B1DE91CE6C3E41FF165600C0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueCurrent" xlink:label="loc_us-gaap_DeferredRevenueCurrent_3E97FB139685112A7EAA41FF1656EFBC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_us-gaap_DeferredRevenueCurrent_3E97FB139685112A7EAA41FF1656EFBC" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredGrantCurrentPortion" xlink:label="loc_run_DeferredGrantCurrentPortion_1FEBF7554FE9EEFF7A7641FF16560D5E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_run_DeferredGrantCurrentPortion_1FEBF7554FE9EEFF7A7641FF16560D5E" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_NonRecourseDebtCurrent" xlink:label="loc_run_NonRecourseDebtCurrent_3E1465BE185385E1B86B41FF16569B67" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_run_NonRecourseDebtCurrent_3E1465BE185385E1B86B41FF16569B67" 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_97597BEA48F350B9F89641FF1656ABC7" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_C09926CDE09576C1BD9341FF16554227" xlink:to="loc_us-gaap_LiabilitiesCurrent_97597BEA48F350B9F89641FF1656ABC7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredRevenueNoncurrent" xlink:label="loc_us-gaap_DeferredRevenueNoncurrent_AC1EE74CBDB788073FE041FF1656CBD6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:to="loc_us-gaap_DeferredRevenueNoncurrent_AC1EE74CBDB788073FE041FF1656CBD6" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_DeferredGrantIncomeNoncurrent" xlink:label="loc_run_DeferredGrantIncomeNoncurrent_B67F2739E7A62F12D69141FF1656BCDD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:to="loc_run_DeferredGrantIncomeNoncurrent_B67F2739E7A62F12D69141FF1656BCDD" xlink:type="arc" />
    <link:loc xlink:href="run-20180331.xsd#run_NonRecourseDebtNoncurrent" xlink:label="loc_run_NonRecourseDebtNoncurrent_C56EEB6B47877C28D69841FF16564A64" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:to="loc_run_NonRecourseDebtNoncurrent_C56EEB6B47877C28D69841FF16564A64" 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_88B3005C1F35B60987C841FF16567318" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_88B3005C1F35B60987C841FF16567318" 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_DBA7E7633AB5ACA8E2EF41FF165654C4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_7CCA73884BDACA4B462C41FF16550E9D" xlink:to="loc_us-gaap_Liabilities_DBA7E7633AB5ACA8E2EF41FF165654C4" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/VieArrangementsTables" xlink:type="extended" />
</link:linkbase>


