<?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-20181231.xsd#AccruedExpensesAndOtherLiabilities" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilitiesScheduleOfAccruedExpensesAndOtherLiabilitiesDetails" xlink:href="run-20181231.xsd#AccruedExpensesAndOtherLiabilitiesScheduleOfAccruedExpensesAndOtherLiabilitiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/AccruedExpensesAndOtherLiabilitiesTables" xlink:href="run-20181231.xsd#AccruedExpensesAndOtherLiabilitiesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Acquisitions" xlink:href="run-20181231.xsd#Acquisitions" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/AcquisitionsAdditionalInformationDetails" xlink:href="run-20181231.xsd#AcquisitionsAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CashEquityFinancing" xlink:href="run-20181231.xsd#CashEquityFinancing" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingencies" xlink:href="run-20181231.xsd#CommitmentsAndContingencies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesAdditionalInformationDetails" xlink:href="run-20181231.xsd#CommitmentsAndContingenciesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesComponentsOfLeaseExpenseDetails" xlink:href="run-20181231.xsd#CommitmentsAndContingenciesComponentsOfLeaseExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesFutureMinimumLeasePaymentsDetails" xlink:href="run-20181231.xsd#CommitmentsAndContingenciesFutureMinimumLeasePaymentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesOtherInformationRelatedToLeasesDetails" xlink:href="run-20181231.xsd#CommitmentsAndContingenciesOtherInformationRelatedToLeasesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/CommitmentsAndContingenciesTables" xlink:href="run-20181231.xsd#CommitmentsAndContingenciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedBalanceSheets" xlink:href="run-20181231.xsd#ConsolidatedBalanceSheets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedBalanceSheetsParenthetical" xlink:href="run-20181231.xsd#ConsolidatedBalanceSheetsParenthetical" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfCashFlows" xlink:href="run-20181231.xsd#ConsolidatedStatementsOfCashFlows" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfComprehensiveIncome" xlink:href="run-20181231.xsd#ConsolidatedStatementsOfComprehensiveIncome" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfOperations" xlink:href="run-20181231.xsd#ConsolidatedStatementsOfOperations" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/ConsolidatedStatementsOfRedeemableNoncontrollingInterestsAndStockholdersEquity" xlink:href="run-20181231.xsd#ConsolidatedStatementsOfRedeemableNoncontrollingInterestsAndStockholdersEquity" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Derivatives" xlink:href="run-20181231.xsd#Derivatives" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesAccumlatedOtherComprehensiveIncomeLossDetails" xlink:href="run-20181231.xsd#DerivativesAccumlatedOtherComprehensiveIncomeLossDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesAdditionalInformationDetails" xlink:href="run-20181231.xsd#DerivativesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesOffsettingArrangementsLossDetails" xlink:href="run-20181231.xsd#DerivativesOffsettingArrangementsLossDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesSummaryOfDesignatedDerivativeInstrumentsClassifiedAsDerivativeAssetsDetails" xlink:href="run-20181231.xsd#DerivativesSummaryOfDesignatedDerivativeInstrumentsClassifiedAsDerivativeAssetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DerivativesTables" xlink:href="run-20181231.xsd#DerivativesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/DocumentAndEntityInformation" xlink:href="run-20181231.xsd#DocumentAndEntityInformation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurement" xlink:href="run-20181231.xsd#FairValueMeasurement" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurementScheduleOfCarryingValuesAndFairValuesOfDebtInstrumentsDetails" xlink:href="run-20181231.xsd#FairValueMeasurementScheduleOfCarryingValuesAndFairValuesOfDebtInstrumentsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurementScheduleOfFairValueFinancialInstrumentsMeasuredOnRecurringBasisDetails" xlink:href="run-20181231.xsd#FairValueMeasurementScheduleOfFairValueFinancialInstrumentsMeasuredOnRecurringBasisDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/FairValueMeasurementTables" xlink:href="run-20181231.xsd#FairValueMeasurementTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNet" xlink:href="run-20181231.xsd#GoodwillAndIntangibleAssetsNet" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetAdditionalInformationDetails" xlink:href="run-20181231.xsd#GoodwillAndIntangibleAssetsNetAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetScheduleOfExpectedAmortizationOfIntangibleAssetsDetails" xlink:href="run-20181231.xsd#GoodwillAndIntangibleAssetsNetScheduleOfExpectedAmortizationOfIntangibleAssetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetSummaryOfIntangibleAssetsNetDetails" xlink:href="run-20181231.xsd#GoodwillAndIntangibleAssetsNetSummaryOfIntangibleAssetsNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetTables" xlink:href="run-20181231.xsd#GoodwillAndIntangibleAssetsNetTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxes" xlink:href="run-20181231.xsd#IncomeTaxes" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesAdditionalInformationDetails" xlink:href="run-20181231.xsd#IncomeTaxesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesIncomeTaxProvisionBenefitDetails" xlink:href="run-20181231.xsd#IncomeTaxesIncomeTaxProvisionBenefitDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesIncomeTaxesUnrecognizedTaxBenefitsDetails" xlink:href="run-20181231.xsd#IncomeTaxesIncomeTaxesUnrecognizedTaxBenefitsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesLossBeforeIncomeTaxesDetails" xlink:href="run-20181231.xsd#IncomeTaxesLossBeforeIncomeTaxesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesReconciliationOfStatutoryFederalRateAndCompanysEffectiveTaxRateDetails" xlink:href="run-20181231.xsd#IncomeTaxesReconciliationOfStatutoryFederalRateAndCompanysEffectiveTaxRateDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesSignificantComponentsOfDeferredTaxAssetsAndLiabilitiesDetails" xlink:href="run-20181231.xsd#IncomeTaxesSignificantComponentsOfDeferredTaxAssetsAndLiabilitiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesSummaryOfTaxYearsThatRemainOpenAndSubjectToExaminationByTaxAuthoritiesDetails" xlink:href="run-20181231.xsd#IncomeTaxesSummaryOfTaxYearsThatRemainOpenAndSubjectToExaminationByTaxAuthoritiesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IncomeTaxesTables" xlink:href="run-20181231.xsd#IncomeTaxesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Indebtedness" xlink:href="run-20181231.xsd#Indebtedness" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessAdditionalInformationDetails" xlink:href="run-20181231.xsd#IndebtednessAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessScheduleOfDebtDetails" xlink:href="run-20181231.xsd#IndebtednessScheduleOfDebtDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessScheduleOfMaturitiesOfDebtExcludingDebtDiscountDetails" xlink:href="run-20181231.xsd#IndebtednessScheduleOfMaturitiesOfDebtExcludingDebtDiscountDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/IndebtednessTables" xlink:href="run-20181231.xsd#IndebtednessTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Inventories" xlink:href="run-20181231.xsd#Inventories" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/InventoriesScheduleOfInventoriesDetails" xlink:href="run-20181231.xsd#InventoriesScheduleOfInventoriesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/InventoriesTables" xlink:href="run-20181231.xsd#InventoriesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/NetIncomePerShare" xlink:href="run-20181231.xsd#NetIncomePerShare" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/NetIncomePerShareComputationOfBasicAndDilutedNetIncomeLossPerShareDetails" xlink:href="run-20181231.xsd#NetIncomePerShareComputationOfBasicAndDilutedNetIncomeLossPerShareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/NetIncomePerShareScheduleOfSharesExcludedFromComputationOfDilutedNetIncomeLossPerShareDetails" xlink:href="run-20181231.xsd#NetIncomePerShareScheduleOfSharesExcludedFromComputationOfDilutedNetIncomeLossPerShareDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/NetIncomePerShareTables" xlink:href="run-20181231.xsd#NetIncomePerShareTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/Organization" xlink:href="run-20181231.xsd#Organization" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OrganizationAdditionalInformationDetails" xlink:href="run-20181231.xsd#OrganizationAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OtherAssets" xlink:href="run-20181231.xsd#OtherAssets" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OtherAssetsScheduleOfPrepaidExpensesAndOtherCurrentAssetsDetails" xlink:href="run-20181231.xsd#OtherAssetsScheduleOfPrepaidExpensesAndOtherCurrentAssetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/OtherAssetsTables" xlink:href="run-20181231.xsd#OtherAssetsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PassThroughFinancingObligations" xlink:href="run-20181231.xsd#PassThroughFinancingObligations" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PassThroughFinancingObligationsAdditionalInformationDetails" xlink:href="run-20181231.xsd#PassThroughFinancingObligationsAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PropertyAndEquipmentNet" xlink:href="run-20181231.xsd#PropertyAndEquipmentNet" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PropertyAndEquipmentNetAdditionalInformationDetails" xlink:href="run-20181231.xsd#PropertyAndEquipmentNetAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PropertyAndEquipmentNetScheduleOfPropertyAndEquipmentNetDetails" xlink:href="run-20181231.xsd#PropertyAndEquipmentNetScheduleOfPropertyAndEquipmentNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/PropertyAndEquipmentNetTables" xlink:href="run-20181231.xsd#PropertyAndEquipmentNetTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/QuarterlyResultsOfOperations" xlink:href="run-20181231.xsd#QuarterlyResultsOfOperations" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/QuarterlyResultsOfOperationsDetails" xlink:href="run-20181231.xsd#QuarterlyResultsOfOperationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/QuarterlyResultsOfOperationsTables" xlink:href="run-20181231.xsd#QuarterlyResultsOfOperationsTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RedeemableNoncontrollingInterests" xlink:href="run-20181231.xsd#RedeemableNoncontrollingInterests" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsDetails" xlink:href="run-20181231.xsd#RedeemableNoncontrollingInterestsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RelatedPartyTransactions" xlink:href="run-20181231.xsd#RelatedPartyTransactions" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/RelatedPartyTransactionsAdditionalInformationDetails" xlink:href="run-20181231.xsd#RelatedPartyTransactionsAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNet" xlink:href="run-20181231.xsd#SolarEnergySystemsNet" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNetAdditionalInformationDetails" xlink:href="run-20181231.xsd#SolarEnergySystemsNetAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNetDetails" xlink:href="run-20181231.xsd#SolarEnergySystemsNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SolarEnergySystemsNetTables" xlink:href="run-20181231.xsd#SolarEnergySystemsNetTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensation" xlink:href="run-20181231.xsd#StockBasedCompensation" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationAdditionalInformationDetails" xlink:href="run-20181231.xsd#StockBasedCompensationAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationEstimatedFairValueOfStockOptionsDetails" xlink:href="run-20181231.xsd#StockBasedCompensationEstimatedFairValueOfStockOptionsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfActivityForAllRsusDetails" xlink:href="run-20181231.xsd#StockBasedCompensationSummaryOfActivityForAllRsusDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockBasedCompensationExpenseDetails" xlink:href="run-20181231.xsd#StockBasedCompensationSummaryOfStockBasedCompensationExpenseDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationSummaryOfStockOptionActivityDetails" xlink:href="run-20181231.xsd#StockBasedCompensationSummaryOfStockOptionActivityDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockBasedCompensationTables" xlink:href="run-20181231.xsd#StockBasedCompensationTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockholdersEquity" xlink:href="run-20181231.xsd#StockholdersEquity" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockholdersEquityAdditionalInformationDetails" xlink:href="run-20181231.xsd#StockholdersEquityAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockholdersEquityScheduleOfReserveShareOfCommonStockForIssuanceDetails" xlink:href="run-20181231.xsd#StockholdersEquityScheduleOfReserveShareOfCommonStockForIssuanceDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/StockholdersEquityTables" xlink:href="run-20181231.xsd#StockholdersEquityTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPolicies" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAccountsReceivableNetDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesAccountsReceivableNetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdditionalInformationDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesAdditionalInformationDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842BalanceSheetDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842BalanceSheetDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842CashFlowsDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842CashFlowsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842StatementOfOperationsDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesAdoptionOfTopic606AndAsc842StatementOfOperationsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAmortizedFiniteLivedIntangibleAssetsEstimatedUsefulLivesDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesAmortizedFiniteLivedIntangibleAssetsEstimatedUsefulLivesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesCashAndRestrictedCashDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesCashAndRestrictedCashDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesDeferredRevenueDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesDeferredRevenueDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesDepreciatedPropertyAndEquipmentNetEstimatedUsefulLivesDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesDepreciatedPropertyAndEquipmentNetEstimatedUsefulLivesDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesPolicies" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesPolicies" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesScheduleOfRevenuesFromExternalCustomersDetails" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesScheduleOfRevenuesFromExternalCustomersDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesTables" xlink:href="run-20181231.xsd#SummaryOfSignificantAccountingPoliciesTables" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/VieArrangements" xlink:href="run-20181231.xsd#VieArrangements" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/VieArrangementsCarryingAmountsAndClassificationOfViesAssetsAndLiabilitiesIncludedInConsolidatedBalanceSheetsDetails" xlink:href="run-20181231.xsd#VieArrangementsCarryingAmountsAndClassificationOfViesAssetsAndLiabilitiesIncludedInConsolidatedBalanceSheetsDetails" xlink:type="simple" />
  <link:roleRef roleURI="http://www.sunrun.com/role/VieArrangementsTables" xlink:href="run-20181231.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/AccruedExpensesAndOtherLiabilitiesScheduleOfAccruedExpensesAndOtherLiabilitiesDetails" 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/Acquisitions" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/AcquisitionsAdditionalInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionLineItems" xlink:label="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable" xlink:label="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_52A007BBF9E17919C6631E18675BA8C1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:to="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_52A007BBF9E17919C6631E18675BA8C1" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAxis" xlink:label="loc_us-gaap_BusinessAcquisitionAxis_F90CB83900CC17C4B7C31E18675B6440" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_52A007BBF9E17919C6631E18675BA8C1" xlink:to="loc_us-gaap_BusinessAcquisitionAxis_F90CB83900CC17C4B7C31E18675B6440" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B62709B644D9AA715A331E186760C376_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_F90CB83900CC17C4B7C31E18675B6440" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B62709B644D9AA715A331E186760C376_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionAcquireeDomain" xlink:label="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B62709B644D9AA715A331E186760C376" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BusinessAcquisitionAxis_F90CB83900CC17C4B7C31E18675B6440" xlink:to="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B62709B644D9AA715A331E186760C376" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CleanEnergyExpertsLLCMember" xlink:label="loc_run_CleanEnergyExpertsLLCMember_DB345DFB4F55797FB7691E1867608404" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionAcquireeDomain_B62709B644D9AA715A331E186760C376" xlink:to="loc_run_CleanEnergyExpertsLLCMember_DB345DFB4F55797FB7691E1867608404" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContingentConsiderationByTypeAxis" xlink:label="loc_us-gaap_ContingentConsiderationByTypeAxis_D9BF84764A3C0BCDF4111E186760F031" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfBusinessAcquisitionsByAcquisitionTable_52A007BBF9E17919C6631E18675BA8C1" xlink:to="loc_us-gaap_ContingentConsiderationByTypeAxis_D9BF84764A3C0BCDF4111E186760F031" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContingentConsiderationTypeDomain" xlink:label="loc_us-gaap_ContingentConsiderationTypeDomain_A8B19E2DAFD9ABD2CAC71E1867608508_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ContingentConsiderationByTypeAxis_D9BF84764A3C0BCDF4111E186760F031" xlink:to="loc_us-gaap_ContingentConsiderationTypeDomain_A8B19E2DAFD9ABD2CAC71E1867608508_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContingentConsiderationTypeDomain" xlink:label="loc_us-gaap_ContingentConsiderationTypeDomain_A8B19E2DAFD9ABD2CAC71E1867608508" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ContingentConsiderationByTypeAxis_D9BF84764A3C0BCDF4111E186760F031" xlink:to="loc_us-gaap_ContingentConsiderationTypeDomain_A8B19E2DAFD9ABD2CAC71E1867608508" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AchievementofSalesTargetsandContinuedEmploymentofKeyEmployeesAcquiredinAcquisitionMember" xlink:label="loc_run_AchievementofSalesTargetsandContinuedEmploymentofKeyEmployeesAcquiredinAcquisitionMember_287F2744FA90A83A8D3D1E1867607B5E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ContingentConsiderationTypeDomain_A8B19E2DAFD9ABD2CAC71E1867608508" xlink:to="loc_run_AchievementofSalesTargetsandContinuedEmploymentofKeyEmployeesAcquiredinAcquisitionMember_287F2744FA90A83A8D3D1E1867607B5E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BusinessAcquisitionPaymentOfCash" xlink:label="loc_run_BusinessAcquisitionPaymentOfCash_83EE0E8303685846BAA61E1867606415" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:to="loc_run_BusinessAcquisitionPaymentOfCash_83EE0E8303685846BAA61E1867606415" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BusinessCombinationConsiderationAggregateShareAmount" xlink:label="loc_run_BusinessCombinationConsiderationAggregateShareAmount_9DCDBD2BF3BDAFB2F87E1E1867649FC4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:to="loc_run_BusinessCombinationConsiderationAggregateShareAmount_9DCDBD2BF3BDAFB2F87E1E1867649FC4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionEquityInterestIssuedOrIssuableValueAssigned" xlink:label="loc_us-gaap_BusinessAcquisitionEquityInterestIssuedOrIssuableValueAssigned_186A0C9B1E67B4BBD8E11E1867648B71" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:to="loc_us-gaap_BusinessAcquisitionEquityInterestIssuedOrIssuableValueAssigned_186A0C9B1E67B4BBD8E11E1867648B71" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsToAcquireBusinessesGross" xlink:label="loc_us-gaap_PaymentsToAcquireBusinessesGross_777F7FC06FA70EFF5A5B1E186764843A" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:to="loc_us-gaap_PaymentsToAcquireBusinessesGross_777F7FC06FA70EFF5A5B1E186764843A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BusinessAcquisitionEquityInterestsIssuedOrIssuableNumberOfSharesIssued" xlink:label="loc_us-gaap_BusinessAcquisitionEquityInterestsIssuedOrIssuableNumberOfSharesIssued_1ECB18A960E9965051C01E1867656D54" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BusinessAcquisitionLineItems_106C6410CC90B5568CCA1E186760175B" xlink:to="loc_us-gaap_BusinessAcquisitionEquityInterestsIssuedOrIssuableNumberOfSharesIssued_1ECB18A960E9965051C01E1867656D54" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/CashEquityFinancing" 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_E0408275ACD792BF951C32C50C306007" 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_F9D8829C1BDF07F8E1F132C50C2CE872" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_OtherCommitmentsTable_F9D8829C1BDF07F8E1F132C50C2CE872" 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_AB1EB02F1E1E86D63ED832C50C2C2186" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_F9D8829C1BDF07F8E1F132C50C2CE872" xlink:to="loc_us-gaap_ProductOrServiceAxis_AB1EB02F1E1E86D63ED832C50C2C2186" 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_9555BEBF932A9740D9BA32C50C2D5749_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_AB1EB02F1E1E86D63ED832C50C2C2186" xlink:to="loc_us-gaap_ProductsAndServicesDomain_9555BEBF932A9740D9BA32C50C2D5749_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_9555BEBF932A9740D9BA32C50C2D5749" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_AB1EB02F1E1E86D63ED832C50C2C2186" xlink:to="loc_us-gaap_ProductsAndServicesDomain_9555BEBF932A9740D9BA32C50C2D5749" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PhotovoltaicModulesMember" xlink:label="loc_run_PhotovoltaicModulesMember_EEEBC2EF9EBE1405523232C50C2D9F36" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_9555BEBF932A9740D9BA32C50C2D5749" xlink:to="loc_run_PhotovoltaicModulesMember_EEEBC2EF9EBE1405523232C50C2D9F36" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationStatusAxis" xlink:label="loc_us-gaap_LitigationStatusAxis_9EBE236956CA2759720F32C50C2DB940" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_F9D8829C1BDF07F8E1F132C50C2CE872" xlink:to="loc_us-gaap_LitigationStatusAxis_9EBE236956CA2759720F32C50C2DB940" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationStatusDomain" xlink:label="loc_us-gaap_LitigationStatusDomain_AF9E19B4FA1FA96FF72632C50C2D5500_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LitigationStatusAxis_9EBE236956CA2759720F32C50C2DB940" xlink:to="loc_us-gaap_LitigationStatusDomain_AF9E19B4FA1FA96FF72632C50C2D5500_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationStatusDomain" xlink:label="loc_us-gaap_LitigationStatusDomain_AF9E19B4FA1FA96FF72632C50C2D5500" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LitigationStatusAxis_9EBE236956CA2759720F32C50C2DB940" xlink:to="loc_us-gaap_LitigationStatusDomain_AF9E19B4FA1FA96FF72632C50C2D5500" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SettledLitigationMember" xlink:label="loc_us-gaap_SettledLitigationMember_394778396745E169033F32C50C2E1EA7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LitigationStatusDomain_AF9E19B4FA1FA96FF72632C50C2D5500" xlink:to="loc_us-gaap_SettledLitigationMember_394778396745E169033F32C50C2E1EA7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationCaseAxis" xlink:label="loc_us-gaap_LitigationCaseAxis_344F310FECD0C4799FB832C50C2EC7E5" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_F9D8829C1BDF07F8E1F132C50C2CE872" xlink:to="loc_us-gaap_LitigationCaseAxis_344F310FECD0C4799FB832C50C2EC7E5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationCaseTypeDomain" xlink:label="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LitigationCaseAxis_344F310FECD0C4799FB832C50C2EC7E5" xlink:to="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationCaseTypeDomain" xlink:label="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LitigationCaseAxis_344F310FECD0C4799FB832C50C2EC7E5" xlink:to="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_Slovinetal.v.SunrunInc.andCleanEnergyExpertsLLCMember" xlink:label="loc_run_Slovinetal.v.SunrunInc.andCleanEnergyExpertsLLCMember_058DAD2F485B5C26375832C50C2ECB67" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353" xlink:to="loc_run_Slovinetal.v.SunrunInc.andCleanEnergyExpertsLLCMember_058DAD2F485B5C26375832C50C2ECB67" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_Cohenetal.v.SunrunInc.etal.Member" xlink:label="loc_run_Cohenetal.v.SunrunInc.etal.Member_2042F7AD5A39635A7E8332C50C2F08B7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353" xlink:to="loc_run_Cohenetal.v.SunrunInc.etal.Member_2042F7AD5A39635A7E8332C50C2F08B7" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_Finketal.v.SunrunInc.etal.Member" xlink:label="loc_run_Finketal.v.SunrunInc.etal.Member_B0602A8F68BF6EE871AB32C50C2F90EA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LitigationCaseTypeDomain_44428A9B0A3DC527C4F632C50C2EF353" xlink:to="loc_run_Finketal.v.SunrunInc.etal.Member_B0602A8F68BF6EE871AB32C50C2F90EA" 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_487B7419A30A5D778F2732C50C2FDACF" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_F9D8829C1BDF07F8E1F132C50C2CE872" xlink:to="loc_us-gaap_CreditFacilityAxis_487B7419A30A5D778F2732C50C2FDACF" 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_B88839531E0511DCB0FD32C50C2F6EF1_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_487B7419A30A5D778F2732C50C2FDACF" xlink:to="loc_us-gaap_CreditFacilityDomain_B88839531E0511DCB0FD32C50C2F6EF1_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_B88839531E0511DCB0FD32C50C2F6EF1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_487B7419A30A5D778F2732C50C2FDACF" xlink:to="loc_us-gaap_CreditFacilityDomain_B88839531E0511DCB0FD32C50C2F6EF1" 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_77ECCD822A58E7A818C832C50C2F6306" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_B88839531E0511DCB0FD32C50C2F6EF1" xlink:to="loc_us-gaap_LetterOfCreditMember_77ECCD822A58E7A818C832C50C2F6306" 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_7656F862AEEA8BDAB8E732C50C30B022" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_OtherCommitmentsTable_F9D8829C1BDF07F8E1F132C50C2CE872" xlink:to="loc_us-gaap_RangeAxis_7656F862AEEA8BDAB8E732C50C30B022" 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_8A889D0176A054664EA132C50C30143F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_7656F862AEEA8BDAB8E732C50C30B022" xlink:to="loc_us-gaap_RangeMember_8A889D0176A054664EA132C50C30143F_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_8A889D0176A054664EA132C50C30143F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_7656F862AEEA8BDAB8E732C50C30B022" xlink:to="loc_us-gaap_RangeMember_8A889D0176A054664EA132C50C30143F" 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_6B203D4430B23D254E7332C50C301779" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_8A889D0176A054664EA132C50C30143F" xlink:to="loc_us-gaap_MinimumMember_6B203D4430B23D254E7332C50C301779" 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_CE9E053D10A34DE6A94F32C50C3095D4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_8A889D0176A054664EA132C50C30143F" xlink:to="loc_us-gaap_MaximumMember_CE9E053D10A34DE6A94F32C50C3095D4" 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_E9FE8D6F42B4DA44196532C50C313D19" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_LettersOfCreditOutstandingAmount_E9FE8D6F42B4DA44196532C50C313D19" 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_CF4B61ACA3F6B2C74DCD32C50C31DA47" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_LineOfCreditFacilityUnusedCapacityCommitmentFeePercentage_CF4B61ACA3F6B2C74DCD32C50C31DA47" 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_58B54C52C5D4998D2BBE32C50C31DC1A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_LongTermPurchaseCommitmentAmount_58B54C52C5D4998D2BBE32C50C31DC1A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LossContingencyAccrualAtCarryingValue" xlink:label="loc_us-gaap_LossContingencyAccrualAtCarryingValue_1F06621E45E15109BBD832C50C31BA46" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_LossContingencyAccrualAtCarryingValue_1F06621E45E15109BBD832C50C31BA46" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LitigationSettlementAmountAwardedToOtherParty" xlink:label="loc_us-gaap_LitigationSettlementAmountAwardedToOtherParty_54FE39B31BFF274AACA832C50C318711" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_LitigationSettlementAmountAwardedToOtherParty_54FE39B31BFF274AACA832C50C318711" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LossContingencyUndiscountedAmountOfInsuranceRelatedAssessmentLiability" xlink:label="loc_us-gaap_LossContingencyUndiscountedAmountOfInsuranceRelatedAssessmentLiability_A184E213EE999158FC1232C50C314B29" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherCommitmentsLineItems_E0408275ACD792BF951C32C50C306007" xlink:to="loc_us-gaap_LossContingencyUndiscountedAmountOfInsuranceRelatedAssessmentLiability_A184E213EE999158FC1232C50C314B29" 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/ConsolidatedBalanceSheets" 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_DAEE71FF3ABA724C885D321C4BF182D2" 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_EDDC040B3ACBC7EFC18C321C4BF1E1C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_StatementTable_EDDC040B3ACBC7EFC18C321C4BF1E1C7" 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_16A2898EB6AC8FA02FB6321C4BF1BF87" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_EDDC040B3ACBC7EFC18C321C4BF1E1C7" xlink:to="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_16A2898EB6AC8FA02FB6321C4BF1BF87" 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_CAB417EFB37087EFFFD4321C4BF1D6D5_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_16A2898EB6AC8FA02FB6321C4BF1BF87" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_CAB417EFB37087EFFFD4321C4BF1D6D5_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_CAB417EFB37087EFFFD4321C4BF1D6D5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_16A2898EB6AC8FA02FB6321C4BF1BF87" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_CAB417EFB37087EFFFD4321C4BF1D6D5" 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_C1D82D769491EBA6B86D321C4BF1EBD5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_CAB417EFB37087EFFFD4321C4BF1D6D5" xlink:to="loc_us-gaap_VariableInterestEntityPrimaryBeneficiaryMember_C1D82D769491EBA6B86D321C4BF1EBD5" 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_C65CA80F627339C83FF8321C4BF1A8D0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableCurrent_C65CA80F627339C83FF8321C4BF1A8D0" 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_A2EDC72DB69C95E02004321C4BF1D0F4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_PreferredStockParOrStatedValuePerShare_A2EDC72DB69C95E02004321C4BF1D0F4" 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_746906ED6E8CA8B042DA321C4BF15F94" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_PreferredStockSharesAuthorized_746906ED6E8CA8B042DA321C4BF15F94" 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_A6A649441207E84A69D1321C4BF11B55" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_PreferredStockSharesIssued_A6A649441207E84A69D1321C4BF11B55" 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_3EB626FB26DD1E6862AD321C4BF18EB3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_PreferredStockSharesOutstanding_3EB626FB26DD1E6862AD321C4BF18EB3" 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_A7E00B39EA41D3DEDD3F321C4BF1FE17" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_CommonStockParOrStatedValuePerShare_A7E00B39EA41D3DEDD3F321C4BF1FE17" 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_BC4978709FD99BEE0BAF321C4BF16A86" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_CommonStockSharesAuthorized_BC4978709FD99BEE0BAF321C4BF16A86" 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_5D23D409B8FDCC637710321C4BF18AAD" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_CommonStockSharesIssued_5D23D409B8FDCC637710321C4BF18AAD" 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_679E1B14855C3C046784321C4BF112D6" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_679E1B14855C3C046784321C4BF112D6" 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_29D5CAF71E7B97A121B3321C4BF178B8" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_Assets_29D5CAF71E7B97A121B3321C4BF178B8" 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_A607DB5F526F0B300536321C4BF1D549" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_A607DB5F526F0B300536321C4BF1D549" 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_BB435D9A14EAC2C32A1B321C4BF133FB" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_Cash_BB435D9A14EAC2C32A1B321C4BF133FB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestrictedCashCurrent" xlink:label="loc_us-gaap_RestrictedCashCurrent_FC99BA9C2513CF769031321C4BF1FC24" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_RestrictedCashCurrent_FC99BA9C2513CF769031321C4BF1FC24" 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_8A668F572283C0776C8E321C4BF1860E" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_8A668F572283C0776C8E321C4BF1860E" 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_FF0386A7CA3F9E6B8950321C4BF1D847" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_FF0386A7CA3F9E6B8950321C4BF1D847" 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_CCF5B8248AED61F4457D321C4BF1FC2A" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_CCF5B8248AED61F4457D321C4BF1FC2A" 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_329611ECC5A2E7B29001321C4BF5FAC5" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_Liabilities_329611ECC5A2E7B29001321C4BF5FAC5" 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_F43DBABA9467419C1ABC321C4BF568AE" xlink:type="locator" />
    <link:definitionArc order="18" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_AccountsPayableCurrent_F43DBABA9467419C1ABC321C4BF568AE" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests" xlink:label="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_AEE1E724E95D83FF0839321C4BF5B759" xlink:type="locator" />
    <link:definitionArc order="19" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_AEE1E724E95D83FF0839321C4BF5B759" 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_10D715B16A036AA0A69A321C4BF5FB83" xlink:type="locator" />
    <link:definitionArc order="20" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_10D715B16A036AA0A69A321C4BF5FB83" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiability" xlink:label="loc_us-gaap_ContractWithCustomerLiability_E2044AEC29E49D7D3ADA324010F048FF" xlink:type="locator" />
    <link:definitionArc order="21" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_ContractWithCustomerLiability_E2044AEC29E49D7D3ADA324010F048FF" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredGrants" xlink:label="loc_run_DeferredGrants_FF02A9797960B414CBB7321C4BF502E0" xlink:type="locator" />
    <link:definitionArc order="22" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_run_DeferredGrants_FF02A9797960B414CBB7321C4BF502E0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NonRecourseDebt" xlink:label="loc_us-gaap_NonRecourseDebt_E2A48752EA056192DCC3321C4BF54F12" xlink:type="locator" />
    <link:definitionArc order="23" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_NonRecourseDebt_E2A48752EA056192DCC3321C4BF54F12" 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_3561219ACF128AA924A3321C4BF56E32" xlink:type="locator" />
    <link:definitionArc order="24" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_DAEE71FF3ABA724C885D321C4BF182D2" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_3561219ACF128AA924A3321C4BF56E32" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfCashFlows" 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_C95EA20BE9B19147E96B326D20D040FD" 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_0693B1C076CBCC2EBD81326D20CC3CDE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_StatementTable_0693B1C076CBCC2EBD81326D20CC3CDE" 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_3D11268B8C0BE5CD5984326D20CC3EFA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_0693B1C076CBCC2EBD81326D20CC3CDE" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_3D11268B8C0BE5CD5984326D20CC3EFA" 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_BAA191D17FB1FB9D3FA7326D20CCDA70_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_3D11268B8C0BE5CD5984326D20CC3EFA" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_BAA191D17FB1FB9D3FA7326D20CCDA70_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_BAA191D17FB1FB9D3FA7326D20CCDA70" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_3D11268B8C0BE5CD5984326D20CC3EFA" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_BAA191D17FB1FB9D3FA7326D20CCDA70" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RecourseDebtMember" xlink:label="loc_run_RecourseDebtMember_37431735B2EEB4642FE5326D20D0D3A1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_BAA191D17FB1FB9D3FA7326D20CCDA70" xlink:to="loc_run_RecourseDebtMember_37431735B2EEB4642FE5326D20D0D3A1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_NonRecourseDebtMember" xlink:label="loc_run_NonRecourseDebtMember_A6378D5690E6D29F4E20326D20D0F23F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_BAA191D17FB1FB9D3FA7326D20CCDA70" xlink:to="loc_run_NonRecourseDebtMember_A6378D5690E6D29F4E20326D20D0F23F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivitiesAbstract" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesAbstract_B62BEBC5B0B47B8F7869326D20D047EC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesAbstract_B62BEBC5B0B47B8F7869326D20D047EC" 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_0710C30E7C08AEEF73A6326D20D0A35E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesAbstract_B62BEBC5B0B47B8F7869326D20D047EC" xlink:to="loc_us-gaap_ProfitLoss_0710C30E7C08AEEF73A6326D20D0A35E" 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_E00560963FF1AF1B030F326D20D0944C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" 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_EEE3A86978274CB8513E326D20D0BDEE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_us-gaap_DepreciationAndAmortization_EEE3A86978274CB8513E326D20D0BDEE" 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_02E8994ABE3D44CA33D3326D20D09A45" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_02E8994ABE3D44CA33D3326D20D09A45" 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_E1438BBC8465E8A8AAFA326D20D0C789" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_us-gaap_ShareBasedCompensation_E1438BBC8465E8A8AAFA326D20D0C789" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestOnLeaseFinancing" xlink:label="loc_run_InterestOnLeaseFinancing_2B1EE0E411539BD3339A326D20D06871" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_run_InterestOnLeaseFinancing_2B1EE0E411539BD3339A326D20D06871" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ReductionInLeasePassThroughFinancingObligations" xlink:label="loc_run_ReductionInLeasePassThroughFinancingObligations_1B6508B4A71024EBBC22326D20D04003" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_run_ReductionInLeasePassThroughFinancingObligations_1B6508B4A71024EBBC22326D20D04003" 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_5DED42FF2C1B82B89DCC326D20D068BA" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_us-gaap_OtherNoncashExpense_5DED42FF2C1B82B89DCC326D20D068BA" 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_855E677334E269C63729326D20D0AB26" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract_E00560963FF1AF1B030F326D20D0944C" xlink:to="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" 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_3C03D054E87BEFF02EF6326D20D017EA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_3C03D054E87BEFF02EF6326D20D017EA" 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_16A2FE2E82B731541FD6326D20D0D702" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_us-gaap_IncreaseDecreaseInInventories_16A2FE2E82B731541FD6326D20D0D702" 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_336A75980FE1005F1BDA326D20D0641C" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_336A75980FE1005F1BDA326D20D0641C" 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_488B92DA4A25096951A9326D20D0078D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsPayable_488B92DA4A25096951A9326D20D0078D" 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_9B4FDF82EB9018352B40326D20D4AA42" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedLiabilitiesAndOtherOperatingLiabilities_9B4FDF82EB9018352B40326D20D4AA42" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_IncreaseDecreaseinContractwithCustomerLiability" xlink:label="loc_run_IncreaseDecreaseinContractwithCustomerLiability_5918D302835CCA512AB0326D20D4088E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_run_IncreaseDecreaseinContractwithCustomerLiability_5918D302835CCA512AB0326D20D4088E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_DA2313FA7DB7270EFDEE326D20D4E058" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInOperatingCapitalAbstract_855E677334E269C63729326D20D0AB26" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_DA2313FA7DB7270EFDEE326D20D4E058" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract_1CF440B56F1B695B5C6E326D20D4AF68" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract_1CF440B56F1B695B5C6E326D20D4AF68" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PaymentsForCostOfSolarEnergySystemsToBeLeased" xlink:label="loc_run_PaymentsForCostOfSolarEnergySystemsToBeLeased_C4489D6F61E19ED3C66A326D20D4128F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract_1CF440B56F1B695B5C6E326D20D4AF68" xlink:to="loc_run_PaymentsForCostOfSolarEnergySystemsToBeLeased_C4489D6F61E19ED3C66A326D20D4128F" 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_338CFC66F8B5658AA9C9326D20D412F2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract_1CF440B56F1B695B5C6E326D20D4AF68" xlink:to="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_338CFC66F8B5658AA9C9326D20D412F2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PaymentsToAcquireBusinessesNetOfCashAcquired" xlink:label="loc_us-gaap_PaymentsToAcquireBusinessesNetOfCashAcquired_CA1BB9C2A3F1C7691C20326D20D4A270" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract_1CF440B56F1B695B5C6E326D20D4AF68" xlink:to="loc_us-gaap_PaymentsToAcquireBusinessesNetOfCashAcquired_CA1BB9C2A3F1C7691C20326D20D4A270" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_FEE7A25837E19957CDAD326D20D4AABB" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract_1CF440B56F1B695B5C6E326D20D4AF68" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_FEE7A25837E19957CDAD326D20D4AABB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ProceedsFromStateTaxCreditsNetOfRecapture" xlink:label="loc_run_ProceedsFromStateTaxCreditsNetOfRecapture_584F4BE322BC9C2C491D326D20D4A309" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_run_ProceedsFromStateTaxCreditsNetOfRecapture_584F4BE322BC9C2C491D326D20D4A309" 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_DA98E94D452093B1C7D2326D20D40DC4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfDebt_DA98E94D452093B1C7D2326D20D40DC4" 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_C61DF316D31C1E253BCB326D20D4B5AD" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_RepaymentsOfDebt_C61DF316D31C1E253BCB326D20D4B5AD" 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_14E1F2655ED70E8E10EB326D20D47D8C" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_PaymentsOfDebtIssuanceCosts_14E1F2655ED70E8E10EB326D20D47D8C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ProceedsFromLeasePassThroughFinancingObligations" xlink:label="loc_run_ProceedsFromLeasePassThroughFinancingObligations_7ECDA30905DB7EF73814326D20D4F029" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_run_ProceedsFromLeasePassThroughFinancingObligations_7ECDA30905DB7EF73814326D20D4F029" 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_972A0B5D15D21ABF87DC326D20D47F0E" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_RepaymentsOfLongTermCapitalLeaseObligations_972A0B5D15D21ABF87DC326D20D47F0E" 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_6676AE05B2280CF30772326D20D4DDFD" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_ProceedsFromMinorityShareholders_6676AE05B2280CF30772326D20D4DDFD" 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_6BBB7A87024BCA684C3A326D20D4AA00" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_PaymentsToMinorityShareholders_6BBB7A87024BCA684C3A326D20D4AA00" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PaymentsToAcquireNonControllingInterest" xlink:label="loc_run_PaymentsToAcquireNonControllingInterest_AB04BC191C210F010382326D20D4186E" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_run_PaymentsToAcquireNonControllingInterest_AB04BC191C210F010382326D20D4186E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PaymentsforProceedsfromFromStockOptionsExercisedAndIssuanceOfSharesInConnectionWithEmployeeStockPurchasePlan" xlink:label="loc_run_PaymentsforProceedsfromFromStockOptionsExercisedAndIssuanceOfSharesInConnectionWithEmployeeStockPurchasePlan_67C7F519750A0BF4E281326D20D44A46" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_run_PaymentsforProceedsfromFromStockOptionsExercisedAndIssuanceOfSharesInConnectionWithEmployeeStockPurchasePlan_67C7F519750A0BF4E281326D20D44A46" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ProceedsFromPaymentsForOfferingCostsPaidRelatedToInitialPublicOfferingNet" xlink:label="loc_run_ProceedsFromPaymentsForOfferingCostsPaidRelatedToInitialPublicOfferingNet_29A0AA2B53F3388C8880326D20DC923B" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_run_ProceedsFromPaymentsForOfferingCostsPaidRelatedToInitialPublicOfferingNet_29A0AA2B53F3388C8880326D20DC923B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_AD43C6E8114AE806A265326D20DC0827" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract_DF2651779E7AA8C291A9326DB8ED7A63" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_AD43C6E8114AE806A265326D20DC0827" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_E25DC4EF79A5CCEB743A326D20DCAF56" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_E25DC4EF79A5CCEB743A326D20DCAF56" 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_A68BC2DA9EE78D646FCC326D20DC6548" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_A68BC2DA9EE78D646FCC326D20DC6548" 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_FB64094CF200528F21BA326D20DCCD61" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_SupplementalCashFlowInformationAbstract_FB64094CF200528F21BA326D20DCCD61" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InterestPaidNet" xlink:label="loc_us-gaap_InterestPaidNet_37AB0D1FAECE97021BF5326D20DC4527" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SupplementalCashFlowInformationAbstract_FB64094CF200528F21BA326D20DCCD61" xlink:to="loc_us-gaap_InterestPaidNet_37AB0D1FAECE97021BF5326D20DC4527" 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_39E72B5183DAEAC3B16C326D20DCF132" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_SupplementalCashFlowInformationAbstract_FB64094CF200528F21BA326D20DCCD61" xlink:to="loc_us-gaap_IncomeTaxesPaid_39E72B5183DAEAC3B16C326D20DCF132" 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_5E044D51BE2CB54CA91A326D20DC8257" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_C95EA20BE9B19147E96B326D20D040FD" xlink:to="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_5E044D51BE2CB54CA91A326D20DC8257" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PurchasesOfSolarEnergySystemsAndPropertyAndEquipmentIncludedInAccountsPayableAndAccruedExpenses" xlink:label="loc_run_PurchasesOfSolarEnergySystemsAndPropertyAndEquipmentIncludedInAccountsPayableAndAccruedExpenses_2100534B54FCCD8FA808326D20DC33FE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_5E044D51BE2CB54CA91A326D20DC8257" xlink:to="loc_run_PurchasesOfSolarEnergySystemsAndPropertyAndEquipmentIncludedInAccountsPayableAndAccruedExpenses_2100534B54FCCD8FA808326D20DC33FE" 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_6913A9F790498968BCEC326D20DCE937" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_5E044D51BE2CB54CA91A326D20DC8257" xlink:to="loc_us-gaap_NotesAssumed1_6913A9F790498968BCEC326D20DCE937" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncashOrPartNoncashAcquisitionValueOfAssetsAcquired1" xlink:label="loc_us-gaap_NoncashOrPartNoncashAcquisitionValueOfAssetsAcquired1_F021F85844A6DA710EA4326D20DC347F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_NoncashInvestingAndFinancingItemsAbstract_5E044D51BE2CB54CA91A326D20DC8257" xlink:to="loc_us-gaap_NoncashOrPartNoncashAcquisitionValueOfAssetsAcquired1_F021F85844A6DA710EA4326D20DC347F" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfComprehensiveIncome" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfOperations" 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_A8F41602BD408FA214BC35818A7AF9E1" 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_983FD70F9385F0312FED35818A760AB3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_StatementTable_983FD70F9385F0312FED35818A760AB3" 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_4B1B951796AAA187B1FA35818A77B29C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_983FD70F9385F0312FED35818A760AB3" xlink:to="loc_us-gaap_ProductOrServiceAxis_4B1B951796AAA187B1FA35818A77B29C" 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_24966B84F27C2009B70035818A777DD0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_4B1B951796AAA187B1FA35818A77B29C" xlink:to="loc_us-gaap_ProductsAndServicesDomain_24966B84F27C2009B70035818A777DD0_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_24966B84F27C2009B70035818A777DD0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_4B1B951796AAA187B1FA35818A77B29C" xlink:to="loc_us-gaap_ProductsAndServicesDomain_24966B84F27C2009B70035818A777DD0" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ServiceMember" xlink:label="loc_run_ServiceMember_A49A0A4644D405C6961835818A77AEC2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_24966B84F27C2009B70035818A777DD0" xlink:to="loc_run_ServiceMember_A49A0A4644D405C6961835818A77AEC2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProductMember" xlink:label="loc_us-gaap_ProductMember_FEE81125902A0B13CDF335818A79977A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_24966B84F27C2009B70035818A777DD0" xlink:to="loc_us-gaap_ProductMember_FEE81125902A0B13CDF335818A79977A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenuesAbstract" xlink:label="loc_us-gaap_RevenuesAbstract_9F51666E71AB79605DCD35818A7A22EB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_RevenuesAbstract_9F51666E71AB79605DCD35818A7A22EB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_0D49849833CE506DD88735818A7AA148" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesAbstract_9F51666E71AB79605DCD35818A7A22EB" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_0D49849833CE506DD88735818A7AA148" 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_138F4F62136BD836BC6635818A7AB509" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenuesAbstract_9F51666E71AB79605DCD35818A7A22EB" xlink:to="loc_us-gaap_Revenues_138F4F62136BD836BC6635818A7AB509" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostsAndExpensesAbstract" xlink:label="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostOfGoodsAndServicesSold" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_6B76C77FC6DBBE493D6435818A7B5A2E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_6B76C77FC6DBBE493D6435818A7B5A2E" 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_90C007E501D464E44E3B35818A7BA3C1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:to="loc_us-gaap_SellingAndMarketingExpense_90C007E501D464E44E3B35818A7BA3C1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ResearchAndDevelopmentExpense" xlink:label="loc_us-gaap_ResearchAndDevelopmentExpense_E5C2AEDB80911A63A6CA35818A7B8CF9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:to="loc_us-gaap_ResearchAndDevelopmentExpense_E5C2AEDB80911A63A6CA35818A7B8CF9" 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_F637CF1EF5B6125750DF35818A7B9FD7" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_F637CF1EF5B6125750DF35818A7B9FD7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AmortizationOfIntangibleAssets" xlink:label="loc_us-gaap_AmortizationOfIntangibleAssets_27D78355ABE78161792035818A7CABA6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:to="loc_us-gaap_AmortizationOfIntangibleAssets_27D78355ABE78161792035818A7CABA6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostsAndExpenses" xlink:label="loc_us-gaap_CostsAndExpenses_BA7B50D3A5863A3E33B835818A7CF4C6" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CostsAndExpensesAbstract_793583634A69C4ECD0E235818A7B47D4" xlink:to="loc_us-gaap_CostsAndExpenses_BA7B50D3A5863A3E33B835818A7CF4C6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingIncomeLoss" xlink:label="loc_us-gaap_OperatingIncomeLoss_5C1F981C41E7140162F435818A7C531B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_OperatingIncomeLoss_5C1F981C41E7140162F435818A7C531B" 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_A06263F72901AB4CAAAA35818A7C18B7" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_A06263F72901AB4CAAAA35818A7C18B7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherNonoperatingIncomeExpense" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_22BBE2B4094CACE46F1935818A7C1266" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_22BBE2B4094CACE46F1935818A7C1266" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_820781D9185C5660C3A535818A7CC8C8" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_820781D9185C5660C3A535818A7CC8C8" 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_793741700ADC045E7D6035818A7DA091" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_793741700ADC045E7D6035818A7DA091" 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_125F22DE2DB1F5F8DAE735818A7DD9F7" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_ProfitLoss_125F22DE2DB1F5F8DAE735818A7DD9F7" 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_C81992D17FFEE608122B35818A7D77F0" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_C81992D17FFEE608122B35818A7D77F0" 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_C466543B246CDA81F15835818A7D97AC" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_NetIncomeLoss_C466543B246CDA81F15835818A7D97AC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarningsPerShareBasicAndDilutedAbstract" xlink:label="loc_us-gaap_EarningsPerShareBasicAndDilutedAbstract_355421381BFA064F3EAB35818A7D1660" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_EarningsPerShareBasicAndDilutedAbstract_355421381BFA064F3EAB35818A7D1660" 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_83C8DB55A22BEAF5920F35818A7E35B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicAndDilutedAbstract_355421381BFA064F3EAB35818A7D1660" xlink:to="loc_us-gaap_EarningsPerShareBasic_83C8DB55A22BEAF5920F35818A7E35B3" 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_CB878502F990D581C8A335818A7E09C1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EarningsPerShareBasicAndDilutedAbstract_355421381BFA064F3EAB35818A7D1660" xlink:to="loc_us-gaap_EarningsPerShareDiluted_CB878502F990D581C8A335818A7E09C1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingAbstract" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingAbstract_611BC5F2CCD84A4C65FA35818A7ED6ED" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_A8F41602BD408FA214BC35818A7AF9E1" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingAbstract_611BC5F2CCD84A4C65FA35818A7ED6ED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingBasic" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_7F176ACDA266B3EB1B5B35818A7EC9FF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingAbstract_611BC5F2CCD84A4C65FA35818A7ED6ED" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_7F176ACDA266B3EB1B5B35818A7EC9FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding" xlink:label="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_A0D9CACCA9BD99C5C28A35818A7E67C3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingAbstract_611BC5F2CCD84A4C65FA35818A7ED6ED" xlink:to="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_A0D9CACCA9BD99C5C28A35818A7E67C3" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/ConsolidatedStatementsOfRedeemableNoncontrollingInterestsAndStockholdersEquity" 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_03B81A395652BDFC5D083549FBC436B2" 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_C0FC69EF3CCC9EBD6C4F3549FBC217BB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_03B81A395652BDFC5D083549FBC436B2" xlink:to="loc_us-gaap_StatementTable_C0FC69EF3CCC9EBD6C4F3549FBC217BB" 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_1DDD44E01195C0FA068A3549FBC2BF9D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_C0FC69EF3CCC9EBD6C4F3549FBC217BB" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_1DDD44E01195C0FA068A3549FBC2BF9D" 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_FE1D2807D7C52DE80DE93549FBC2AA66_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_1DDD44E01195C0FA068A3549FBC2BF9D" xlink:to="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66_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_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_1DDD44E01195C0FA068A3549FBC2BF9D" xlink:to="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RedeemableNoncontrollingInterestMember" xlink:label="loc_run_RedeemableNoncontrollingInterestMember_110AD20ED060B4CCF6DF3549FBC32451" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_run_RedeemableNoncontrollingInterestMember_110AD20ED060B4CCF6DF3549FBC32451" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PreferredStockMember" xlink:label="loc_us-gaap_PreferredStockMember_3DBB0BB4BC97746EACC03549FBC3C1B6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_PreferredStockMember_3DBB0BB4BC97746EACC03549FBC3C1B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockMember" xlink:label="loc_us-gaap_CommonStockMember_C928045C7B9B7D4ECBFF3549FBC3DABF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_CommonStockMember_C928045C7B9B7D4ECBFF3549FBC3DABF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdditionalPaidInCapitalMember" xlink:label="loc_us-gaap_AdditionalPaidInCapitalMember_1115348AB5C19B84A3003549FBC3F4D5" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_AdditionalPaidInCapitalMember_1115348AB5C19B84A3003549FBC3F4D5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeMember" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_361FD6F57A986643D3DA3549FBC42CF3" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeMember_361FD6F57A986643D3DA3549FBC42CF3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_0820BF07AD437192F0AC3549FBC4F798" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_RetainedEarningsMember_0820BF07AD437192F0AC3549FBC4F798" 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_57E8AF162585B788BA363549FBC40299" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_ParentMember_57E8AF162585B788BA363549FBC40299" 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_DA4F9C4E134B405D98143549FBC4C940" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_FE1D2807D7C52DE80DE93549FBC2AA66" xlink:to="loc_us-gaap_NoncontrollingInterestMember_DA4F9C4E134B405D98143549FBC4C940" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncreaseDecreaseInStockholdersEquityRollForward" xlink:label="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_03B81A395652BDFC5D083549FBC436B2" xlink:to="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" 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_30B7BBA24384C8984A553549FBC5ED6A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount_30B7BBA24384C8984A553549FBC5ED6A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharesIssued" xlink:label="loc_us-gaap_SharesIssued_F49C4CCE35F345221A783549FBC57606" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_SharesIssued_F49C4CCE35F345221A783549FBC57606" 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_4ABAB1FFF720D06926DB3549FBC5B830" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_4ABAB1FFF720D06926DB3549FBC5B830" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_EEF79BCB04C299EE5AE43549FBC5FCB4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_EEF79BCB04C299EE5AE43549FBC5FCB4" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RedeemableNoncontrollingInterestEquityCarryingAmountAdjustedBalance" xlink:label="loc_run_RedeemableNoncontrollingInterestEquityCarryingAmountAdjustedBalance_AECCF65C00EC34BCBDA13549FBC51988" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_run_RedeemableNoncontrollingInterestEquityCarryingAmountAdjustedBalance_AECCF65C00EC34BCBDA13549FBC51988" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAdjustedBalance1" xlink:label="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAdjustedBalance1_5879BE9B004D16D7338A3549FBC6C826" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterestAdjustedBalance1_5879BE9B004D16D7338A3549FBC6C826" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharesStockOptionsExercised" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharesStockOptionsExercised_847C36BE259E5CB74ACF3549FBC6F38B" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharesStockOptionsExercised_847C36BE259E5CB74ACF3549FBC6F38B" 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_466C7CD80D6906772D563549FBC663B9" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised_466C7CD80D6906772D563549FBC663B9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestrictedStockSharesIssuedNetOfSharesForTaxWithholdings" xlink:label="loc_us-gaap_RestrictedStockSharesIssuedNetOfSharesForTaxWithholdings_5F696564668143D8F1733549FBC68032" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_RestrictedStockSharesIssuedNetOfSharesForTaxWithholdings_5F696564668143D8F1733549FBC68032" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestrictedStockValueSharesIssuedNetOfTaxWithholdings" xlink:label="loc_us-gaap_RestrictedStockValueSharesIssuedNetOfTaxWithholdings_5707244DEB925F1DFA8D3549FBC646E9" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_RestrictedStockValueSharesIssuedNetOfTaxWithholdings_5707244DEB925F1DFA8D3549FBC646E9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharesEmployeeStockPurchasePlans" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharesEmployeeStockPurchasePlans_8F0BA47868730173D21A3549FBC60F0D" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharesEmployeeStockPurchasePlans_8F0BA47868730173D21A3549FBC60F0D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueEmployeeStockPurchasePlan" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueEmployeeStockPurchasePlan_B104937B4B9D97F908823549FBC717C1" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueEmployeeStockPurchasePlan_B104937B4B9D97F908823549FBC717C1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueShareBasedCompensation" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueShareBasedCompensation_2F745EE99E4D092833B23549FBC75A40" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueShareBasedCompensation_2F745EE99E4D092833B23549FBC75A40" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NoncontrollingInterestIncreaseFromBusinessCombination" xlink:label="loc_us-gaap_NoncontrollingInterestIncreaseFromBusinessCombination_B7F7B40A0EF7584816643549FBC70CA4" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_NoncontrollingInterestIncreaseFromBusinessCombination_B7F7B40A0EF7584816643549FBC70CA4" 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_12BF46B5CAB7CAF71CFF3549FBC76E9E" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_NoncontrollingInterestIncreaseFromSubsidiaryEquityIssuance_12BF46B5CAB7CAF71CFF3549FBC76E9E" 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_8998B0159D603E953EE93549FBC7CB73" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_MinorityInterestDecreaseFromDistributionsToNoncontrollingInterestHolders_8998B0159D603E953EE93549FBC7CB73" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodSharesAcquisitions" xlink:label="loc_us-gaap_StockIssuedDuringPeriodSharesAcquisitions_B38EFB4D162D2DABB2BF3549FBC89186" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodSharesAcquisitions_B38EFB4D162D2DABB2BF3549FBC89186" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueAcquisitions" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueAcquisitions_A186D670E3FE716C73363549FBC8F570" xlink:type="locator" />
    <link:definitionArc order="18" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueAcquisitions_A186D670E3FE716C73363549FBC8F570" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StockIssuedDuringPeriodValueNewIssues" xlink:label="loc_us-gaap_StockIssuedDuringPeriodValueNewIssues_AD6553DDEFFBB947D36A3549FBC8394B" xlink:type="locator" />
    <link:definitionArc order="19" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_StockIssuedDuringPeriodValueNewIssues_AD6553DDEFFBB947D36A3549FBC8394B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeLossAttributableToParent" xlink:label="loc_us-gaap_IncomeLossAttributableToParent_B19F0FCEDB7EACBEEE983549FBC849EB" xlink:type="locator" />
    <link:definitionArc order="20" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_IncomeLossAttributableToParent_B19F0FCEDB7EACBEEE983549FBC849EB" 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_9BF6DE94AA227DF607293549FBC9245A" xlink:type="locator" />
    <link:definitionArc order="21" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_9BF6DE94AA227DF607293549FBC9245A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherComprehensiveIncomeLossNetofTaxPortionAttributabletoParentBeforeCumulativeAdjustment" xlink:label="loc_run_OtherComprehensiveIncomeLossNetofTaxPortionAttributabletoParentBeforeCumulativeAdjustment_E7C72544E5C20254FE85354BE9C98930" xlink:type="locator" />
    <link:definitionArc order="22" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncreaseDecreaseInStockholdersEquityRollForward_B0F9F62C7120772563B93549FBC4BD93" xlink:to="loc_run_OtherComprehensiveIncomeLossNetofTaxPortionAttributabletoParentBeforeCumulativeAdjustment_E7C72544E5C20254FE85354BE9C98930" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/Derivatives" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DerivativesAccumlatedOtherComprehensiveIncomeLossDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems_847F9AB04A27F944DF27352785AFAD37" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossTable" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossTable_0E816CD767112884B911352785AD71A4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems_847F9AB04A27F944DF27352785AFAD37" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossTable_0E816CD767112884B911352785AD71A4" 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_96037DFC8ED892B6D2DE352785AD00E0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossTable_0E816CD767112884B911352785AD71A4" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_96037DFC8ED892B6D2DE352785AD00E0" 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_E6F9895129FB14333596352785ADF99F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_96037DFC8ED892B6D2DE352785AD00E0" xlink:to="loc_us-gaap_EquityComponentDomain_E6F9895129FB14333596352785ADF99F_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_E6F9895129FB14333596352785ADF99F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_96037DFC8ED892B6D2DE352785AD00E0" xlink:to="loc_us-gaap_EquityComponentDomain_E6F9895129FB14333596352785ADF99F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedNetGainLossFromDesignatedOrQualifyingCashFlowHedgesMember" xlink:label="loc_us-gaap_AccumulatedNetGainLossFromDesignatedOrQualifyingCashFlowHedgesMember_542A856966AD6B86BA15352785AE349C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_E6F9895129FB14333596352785ADF99F" xlink:to="loc_us-gaap_AccumulatedNetGainLossFromDesignatedOrQualifyingCashFlowHedgesMember_542A856966AD6B86BA15352785AE349C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_IncomeStatementLocationAxis" xlink:label="loc_us-gaap_IncomeStatementLocationAxis_8616095AB8A7E78957FF352785AE0F9B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossTable_0E816CD767112884B911352785AD71A4" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_8616095AB8A7E78957FF352785AE0F9B" 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_E09DA2D0483DE146D859352785AE6FC3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_8616095AB8A7E78957FF352785AE0F9B" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_E09DA2D0483DE146D859352785AE6FC3_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_E09DA2D0483DE146D859352785AE6FC3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_8616095AB8A7E78957FF352785AE0F9B" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_E09DA2D0483DE146D859352785AE6FC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherOperatingIncomeExpenseMember" xlink:label="loc_us-gaap_OtherOperatingIncomeExpenseMember_44B6F6FD6262EAB85470352785AE52A3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_E09DA2D0483DE146D859352785AE6FC3" xlink:to="loc_us-gaap_OtherOperatingIncomeExpenseMember_44B6F6FD6262EAB85470352785AE52A3" 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_8CBAD58B7EBBF90C3178352785AF424A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossTable_0E816CD767112884B911352785AD71A4" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_8CBAD58B7EBBF90C3178352785AF424A" 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_B4FE7A5AA809F683DF98352785AF1598_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_8CBAD58B7EBBF90C3178352785AF424A" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_B4FE7A5AA809F683DF98352785AF1598_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_B4FE7A5AA809F683DF98352785AF1598" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_8CBAD58B7EBBF90C3178352785AF424A" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_B4FE7A5AA809F683DF98352785AF1598" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SwapMember" xlink:label="loc_us-gaap_SwapMember_416DDD9779D26124164B352785AF41C1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_B4FE7A5AA809F683DF98352785AF1598" xlink:to="loc_us-gaap_SwapMember_416DDD9779D26124164B352785AF41C1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems_847F9AB04A27F944DF27352785AFAD37" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" 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_991419BB8696F90422F6352785B51BD8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" xlink:to="loc_us-gaap_StockholdersEquityIncludingPortionAttributableToNoncontrollingInterest_991419BB8696F90422F6352785B51BD8" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossbeforeReclassificationafterTax" xlink:label="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossbeforeReclassificationafterTax_E43CBA64070192401B523536C6B223FD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" xlink:to="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossbeforeReclassificationafterTax_E43CBA64070192401B523536C6B223FD" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationafterTax" xlink:label="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationafterTax_92898970DC0E5319DB11352785B64E1D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" xlink:to="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationafterTax_92898970DC0E5319DB11352785B64E1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_DA6A32E17BCADBD1C58A352785B67F76" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_DA6A32E17BCADBD1C58A352785B67F76" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossafterReclassificationandTax" xlink:label="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossafterReclassificationandTax_7DE35AAA502B9FBEC6933532BF2DC5B5" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPeriodIncreaseDecreaseAbstract_DC70ACD61C57589963DC352785B06F49" xlink:to="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossafterReclassificationandTax_7DE35AAA502B9FBEC6933532BF2DC5B5" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossbeforeReclassificationTax" xlink:label="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossbeforeReclassificationTax_A61CA4A3AA12EE7673BF3538E63190D0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems_847F9AB04A27F944DF27352785AFAD37" xlink:to="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossbeforeReclassificationTax_A61CA4A3AA12EE7673BF3538E63190D0" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax" xlink:label="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax_626DB74496E96300D2F4352785B696FF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems_847F9AB04A27F944DF27352785AFAD37" xlink:to="loc_run_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationTax_626DB74496E96300D2F4352785B696FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CumulativeEffectOnRetainedEarningsTax1" xlink:label="loc_us-gaap_CumulativeEffectOnRetainedEarningsTax1_18F3FC5C6F7505D51009352785B7ECF0" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossLineItems_847F9AB04A27F944DF27352785AFAD37" xlink:to="loc_us-gaap_CumulativeEffectOnRetainedEarningsTax1_18F3FC5C6F7505D51009352785B7ECF0" xlink:type="arc" />
  </link:definitionLink>
  <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_8DECDE1BAD071F186AE13549F9D24D7C" 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_1F1276A5CCE7648DE2D63549F9D1D465" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_8DECDE1BAD071F186AE13549F9D24D7C" xlink:to="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1F1276A5CCE7648DE2D63549F9D1D465" 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_AE288D0BEE6855A226BF3549F9D1091A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValuesDerivativesBalanceSheetLocationByDerivativeContractTypeByHedgingDesignationTable_1F1276A5CCE7648DE2D63549F9D1D465" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_AE288D0BEE6855A226BF3549F9D1091A" 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_17B60C53CE5D4C3F2B743549F9D2FD39_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_AE288D0BEE6855A226BF3549F9D1091A" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_17B60C53CE5D4C3F2B743549F9D2FD39_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_17B60C53CE5D4C3F2B743549F9D2FD39" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_AE288D0BEE6855A226BF3549F9D1091A" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_17B60C53CE5D4C3F2B743549F9D2FD39" 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_E4449D93AEC2E3C36E113549F9D2C258" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_17B60C53CE5D4C3F2B743549F9D2FD39" xlink:to="loc_us-gaap_InterestRateSwapMember_E4449D93AEC2E3C36E113549F9D2C258" 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_719EA2A93FD28AB64F333549F9D3D2D7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_8DECDE1BAD071F186AE13549F9D24D7C" xlink:to="loc_us-gaap_InterestRateCashFlowHedgeGainLossToBeReclassifiedDuringNext12MonthsNet_719EA2A93FD28AB64F333549F9D3D2D7" 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_8835EF7645E3FB692EC33549F9D37634" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_8DECDE1BAD071F186AE13549F9D24D7C" xlink:to="loc_us-gaap_DerivativeAssetsNoncurrent_8835EF7645E3FB692EC33549F9D37634" 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_80DFEA7AACC4ED18A3693549F9D32299" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativesFairValueLineItems_8DECDE1BAD071F186AE13549F9D24D7C" xlink:to="loc_us-gaap_DerivativeLiabilitiesNoncurrent_80DFEA7AACC4ED18A3693549F9D32299" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DerivativesOffsettingArrangementsLossDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/DerivativesSummaryOfDesignatedDerivativeInstrumentsClassifiedAsDerivativeAssetsDetails" 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_D7FCBC1360248CC901FC2AE141655CD2" 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_C8AC0B904CCB7B7D3C142AE14161150A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_D7FCBC1360248CC901FC2AE141655CD2" xlink:to="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_C8AC0B904CCB7B7D3C142AE14161150A" 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_EE0BF8506BA8CFB66B0A2AE14161E237" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_C8AC0B904CCB7B7D3C142AE14161150A" xlink:to="loc_us-gaap_DerivativeInstrumentRiskAxis_EE0BF8506BA8CFB66B0A2AE14161E237" 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_4EB1CBAB475D2581914C2AE141621709_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_EE0BF8506BA8CFB66B0A2AE14161E237" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_4EB1CBAB475D2581914C2AE141621709_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_4EB1CBAB475D2581914C2AE141621709" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DerivativeInstrumentRiskAxis_EE0BF8506BA8CFB66B0A2AE14161E237" xlink:to="loc_us-gaap_DerivativeContractTypeDomain_4EB1CBAB475D2581914C2AE141621709" 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_0B39F2E258EC2591A2B82AE141626D01" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeContractTypeDomain_4EB1CBAB475D2581914C2AE141621709" xlink:to="loc_us-gaap_InterestRateSwapMember_0B39F2E258EC2591A2B82AE141626D01" 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_A2BCDB7346413E1B15032AE1416228BA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_C8AC0B904CCB7B7D3C142AE14161150A" xlink:to="loc_us-gaap_CreditDerivativesByContractTypeAxis_A2BCDB7346413E1B15032AE1416228BA" 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_F6CFFEDAAF1B4DC71BE62AE14162036F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditDerivativesByContractTypeAxis_A2BCDB7346413E1B15032AE1416228BA" xlink:to="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F_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_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditDerivativesByContractTypeAxis_A2BCDB7346413E1B15032AE1416228BA" xlink:to="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractOneMember" xlink:label="loc_run_InterestRateSwapContractOneMember_B3F186D92DA9A123D9522AE141634501" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractOneMember_B3F186D92DA9A123D9522AE141634501" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractTwoMember" xlink:label="loc_run_InterestRateSwapContractTwoMember_0258458ACDB199AC705E2AE14163958A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractTwoMember_0258458ACDB199AC705E2AE14163958A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractThreeMember" xlink:label="loc_run_InterestRateSwapContractThreeMember_F4664613FD4FDB3418332AE14163F3BA" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractThreeMember_F4664613FD4FDB3418332AE14163F3BA" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractFourMember" xlink:label="loc_run_InterestRateSwapContractFourMember_44DE6F154E0E3139049A2AE141637EDD" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractFourMember_44DE6F154E0E3139049A2AE141637EDD" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractFiveMember" xlink:label="loc_run_InterestRateSwapContractFiveMember_B32A0B5339A1A038B5132AE141631EF6" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractFiveMember_B32A0B5339A1A038B5132AE141631EF6" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractSixMember" xlink:label="loc_run_InterestRateSwapContractSixMember_7F86656950035661AA222AE141646125" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractSixMember_7F86656950035661AA222AE141646125" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractSevenMember" xlink:label="loc_run_InterestRateSwapContractSevenMember_D36086ED3801F29F202C2AE1416409E6" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractSevenMember_D36086ED3801F29F202C2AE1416409E6" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractEightMember" xlink:label="loc_run_InterestRateSwapContractEightMember_34665035E6C6052865102AE141642676" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractEightMember_34665035E6C6052865102AE141642676" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractNineMember" xlink:label="loc_run_InterestRateSwapContractNineMember_E8D447EF785EF50BDFFB2AE14164184D" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractNineMember_E8D447EF785EF50BDFFB2AE14164184D" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractTenMember" xlink:label="loc_run_InterestRateSwapContractTenMember_4A58720822EC148EE2FE2AE14164C5E4" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractTenMember_4A58720822EC148EE2FE2AE14164C5E4" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractElevenMember" xlink:label="loc_run_InterestRateSwapContractElevenMember_8B0CF7F38D59CB06E6F32AE14164B0F6" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractElevenMember_8B0CF7F38D59CB06E6F32AE14164B0F6" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestRateSwapContractTwelveMember" xlink:label="loc_run_InterestRateSwapContractTwelveMember_9F8EBEF442F7D5E8749A2AE14165D68F" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditDerivativesContractTypeDomain_F6CFFEDAAF1B4DC71BE62AE14162036F" xlink:to="loc_run_InterestRateSwapContractTwelveMember_9F8EBEF442F7D5E8749A2AE14165D68F" 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_8CBD03103101B8ABA3702AE14165FA61" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresTable_C8AC0B904CCB7B7D3C142AE14161150A" xlink:to="loc_us-gaap_RangeAxis_8CBD03103101B8ABA3702AE14165FA61" 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_5C513F5EA02148C21B132AE1416537CB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_8CBD03103101B8ABA3702AE14165FA61" xlink:to="loc_us-gaap_RangeMember_5C513F5EA02148C21B132AE1416537CB_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_5C513F5EA02148C21B132AE1416537CB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_8CBD03103101B8ABA3702AE14165FA61" xlink:to="loc_us-gaap_RangeMember_5C513F5EA02148C21B132AE1416537CB" 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_FE957B28C26A38504D462AE14165697D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_5C513F5EA02148C21B132AE1416537CB" xlink:to="loc_us-gaap_MinimumMember_FE957B28C26A38504D462AE14165697D" 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_39CF98E4094A196F128C2AE14165EAD9" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_5C513F5EA02148C21B132AE1416537CB" xlink:to="loc_us-gaap_MaximumMember_39CF98E4094A196F128C2AE14165EAD9" 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_CF68F56BDDF52A8943222AE141662EAF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_D7FCBC1360248CC901FC2AE141655CD2" xlink:to="loc_us-gaap_DerivativeNumberOfInstrumentsHeld_CF68F56BDDF52A8943222AE141662EAF" 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_ECE3731E9458DFCD39672AE14166BD54" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_D7FCBC1360248CC901FC2AE141655CD2" xlink:to="loc_us-gaap_PercentageOfDebtHedgedByInterestRateDerivatives_ECE3731E9458DFCD39672AE14166BD54" 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_EFA563A79CDA22C5E33D2AE14166038A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_D7FCBC1360248CC901FC2AE141655CD2" xlink:to="loc_invest_DerivativeNotionalAmount_EFA563A79CDA22C5E33D2AE14166038A" 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_AC79C747338C5FBBD0F12AE1416672E6" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DerivativeInstrumentsAndHedgingActivitiesDisclosuresLineItems_D7FCBC1360248CC901FC2AE141655CD2" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_AC79C747338C5FBBD0F12AE1416672E6" 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/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_53D60AE5117BC5C4A4B00CDC082D72F5" 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_5513DD594E400D0F45A80CDC082B3694" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_53D60AE5117BC5C4A4B00CDC082D72F5" xlink:to="loc_us-gaap_FairValueByBalanceSheetGroupingTable_5513DD594E400D0F45A80CDC082B3694" 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_FC8753CB37BC2C7ED3AF0CDC082B4B99" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_5513DD594E400D0F45A80CDC082B3694" xlink:to="loc_us-gaap_DebtInstrumentAxis_FC8753CB37BC2C7ED3AF0CDC082B4B99" 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_170732A2E3C54D6D91270CDC082B2A40_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_FC8753CB37BC2C7ED3AF0CDC082B4B99" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40_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_170732A2E3C54D6D91270CDC082B2A40" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_FC8753CB37BC2C7ED3AF0CDC082B4B99" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankLineOfCreditMember" xlink:label="loc_run_BankLineOfCreditMember_DBCC47B20CAB1E16AB710CDC082B353F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40" xlink:to="loc_run_BankLineOfCreditMember_DBCC47B20CAB1E16AB710CDC082B353F" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SeniorDebtMember" xlink:label="loc_run_SeniorDebtMember_4419DAC601FC8960A59A0CDC082CAE9E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40" xlink:to="loc_run_SeniorDebtMember_4419DAC601FC8960A59A0CDC082CAE9E" 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_928158C97505829D81600CDC082C8413" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40" xlink:to="loc_us-gaap_SubordinatedDebtMember_928158C97505829D81600CDC082C8413" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SecuritizationDebtMember" xlink:label="loc_run_SecuritizationDebtMember_120706FA794E3537BCB70CDC082C37A4" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40" xlink:to="loc_run_SecuritizationDebtMember_120706FA794E3537BCB70CDC082C37A4" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SRECLoansMember" xlink:label="loc_run_SRECLoansMember_8529568B5568670661630CDC082C1DCE" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_170732A2E3C54D6D91270CDC082B2A40" xlink:to="loc_run_SRECLoansMember_8529568B5568670661630CDC082C1DCE" 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_CB7584120435B49A77F70CDC082CE5DE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueByBalanceSheetGroupingTable_5513DD594E400D0F45A80CDC082B3694" xlink:to="loc_us-gaap_FairValueByMeasurementBasisAxis_CB7584120435B49A77F70CDC082CE5DE" 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_8D8A0E585FA5D672BFC70CDC082D0567_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementBasisAxis_CB7584120435B49A77F70CDC082CE5DE" xlink:to="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_8D8A0E585FA5D672BFC70CDC082D0567_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_C30F818FAB2252C2C47D0CDC082CC60F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementBasisAxis_CB7584120435B49A77F70CDC082CE5DE" xlink:to="loc_us-gaap_FairValueDisclosureItemAmountsDomain_C30F818FAB2252C2C47D0CDC082CC60F" 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_8D8A0E585FA5D672BFC70CDC082D0567" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueDisclosureItemAmountsDomain_C30F818FAB2252C2C47D0CDC082CC60F" xlink:to="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_8D8A0E585FA5D672BFC70CDC082D0567" 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_65B471E119984998F5E20CDC082DD190" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_8D8A0E585FA5D672BFC70CDC082D0567" xlink:to="loc_us-gaap_CarryingReportedAmountFairValueDisclosureMember_65B471E119984998F5E20CDC082DD190" 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_E93346B4AF28D5C5AA030CDC082DD4D0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PortionAtFairValueFairValueDisclosureMember_8D8A0E585FA5D672BFC70CDC082D0567" xlink:to="loc_us-gaap_EstimateOfFairValueFairValueDisclosureMember_E93346B4AF28D5C5AA030CDC082DD4D0" 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_F183508E1E4E98485FC10CDC082E79B3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueBalanceSheetGroupingFinancialStatementCaptionsLineItems_53D60AE5117BC5C4A4B00CDC082D72F5" xlink:to="loc_us-gaap_LongTermDebtFairValue_F183508E1E4E98485FC10CDC082E79B3" 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_6DD2984DCD2D203964110CDC0826A7D3" 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_CF1D5E6A29104ACBF9860CDC08239751" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_6DD2984DCD2D203964110CDC0826A7D3" xlink:to="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_CF1D5E6A29104ACBF9860CDC08239751" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueByMeasurementFrequencyAxis" xlink:label="loc_us-gaap_FairValueByMeasurementFrequencyAxis_F5101B4C3DFD072B9EAD0CDC0823CC6A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_CF1D5E6A29104ACBF9860CDC08239751" xlink:to="loc_us-gaap_FairValueByMeasurementFrequencyAxis_F5101B4C3DFD072B9EAD0CDC0823CC6A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_E946932CB2C4906E7ECF0CDC0824D6BB_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_F5101B4C3DFD072B9EAD0CDC0823CC6A" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_E946932CB2C4906E7ECF0CDC0824D6BB_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementFrequencyDomain" xlink:label="loc_us-gaap_FairValueMeasurementFrequencyDomain_E946932CB2C4906E7ECF0CDC0824D6BB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByMeasurementFrequencyAxis_F5101B4C3DFD072B9EAD0CDC0823CC6A" xlink:to="loc_us-gaap_FairValueMeasurementFrequencyDomain_E946932CB2C4906E7ECF0CDC0824D6BB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FairValueMeasurementsRecurringMember" xlink:label="loc_us-gaap_FairValueMeasurementsRecurringMember_FEBA0348CB664100EA230CDC0824FD2B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementFrequencyDomain_E946932CB2C4906E7ECF0CDC0824D6BB" xlink:to="loc_us-gaap_FairValueMeasurementsRecurringMember_FEBA0348CB664100EA230CDC0824FD2B" 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_11F924A0DE166850C6850CDC08243E8A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_CF1D5E6A29104ACBF9860CDC08239751" xlink:to="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_11F924A0DE166850C6850CDC08243E8A" 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_5FDF43D89884CB407D630CDC0824D89B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_11F924A0DE166850C6850CDC08243E8A" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_5FDF43D89884CB407D630CDC0824D89B_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_5FDF43D89884CB407D630CDC0824D89B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FairValueByFairValueHierarchyLevelAxis_11F924A0DE166850C6850CDC08243E8A" xlink:to="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_5FDF43D89884CB407D630CDC0824D89B" 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_9502C10685583BF638B40CDC0825E979" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_5FDF43D89884CB407D630CDC0824D89B" xlink:to="loc_us-gaap_FairValueInputsLevel1Member_9502C10685583BF638B40CDC0825E979" 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_8B7A76E18EB58FD465D80CDC08250FEA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_5FDF43D89884CB407D630CDC0824D89B" xlink:to="loc_us-gaap_FairValueInputsLevel2Member_8B7A76E18EB58FD465D80CDC08250FEA" 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_07EE8DDD86F9A5C1801F0CDC0825C72F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueMeasurementsFairValueHierarchyDomain_5FDF43D89884CB407D630CDC0824D89B" xlink:to="loc_us-gaap_FairValueInputsLevel3Member_07EE8DDD86F9A5C1801F0CDC0825C72F" xlink:type="arc" />
    <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_666D5F5A9C8D4F7C92B20CDC08257B5A" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable_CF1D5E6A29104ACBF9860CDC08239751" xlink:to="loc_us-gaap_FinancialInstrumentAxis_666D5F5A9C8D4F7C92B20CDC08257B5A" 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_47DF5D5DABAC12BEC89F0CDC08264CC2_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FinancialInstrumentAxis_666D5F5A9C8D4F7C92B20CDC08257B5A" xlink:to="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_47DF5D5DABAC12BEC89F0CDC08264CC2_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_47DF5D5DABAC12BEC89F0CDC08264CC2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FinancialInstrumentAxis_666D5F5A9C8D4F7C92B20CDC08257B5A" xlink:to="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_47DF5D5DABAC12BEC89F0CDC08264CC2" 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_FF5E6E07FEC6BE2FF3730CDC08266181" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TransfersAndServicingOfFinancialInstrumentsTypesOfFinancialInstrumentsDomain_47DF5D5DABAC12BEC89F0CDC08264CC2" xlink:to="loc_us-gaap_InterestRateSwapMember_FF5E6E07FEC6BE2FF3730CDC08266181" 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_309A94CA5CA3CEB3512C0CDC0826C7A8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_6DD2984DCD2D203964110CDC0826A7D3" xlink:to="loc_us-gaap_DerivativeAssets_309A94CA5CA3CEB3512C0CDC0826C7A8" 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_CA135AD159509FBE815C0CDC0827F315" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems_6DD2984DCD2D203964110CDC0826A7D3" xlink:to="loc_us-gaap_DerivativeLiabilities_CA135AD159509FBE815C0CDC0827F315" 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/GoodwillAndIntangibleAssetsNet" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetAdditionalInformationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetScheduleOfExpectedAmortizationOfIntangibleAssetsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetSummaryOfIntangibleAssetsNetDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_6E8CFC95AF48231DF9550CDC07F7A860" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_F2F9CC8D0273D77BFD740CDC07F62C62" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_6E8CFC95AF48231DF9550CDC07F7A860" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_F2F9CC8D0273D77BFD740CDC07F62C62" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_7D36B5EAF37404271A540CDC07F6DBB6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_F2F9CC8D0273D77BFD740CDC07F62C62" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_7D36B5EAF37404271A540CDC07F6DBB6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_7D36B5EAF37404271A540CDC07F6DBB6" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_7D36B5EAF37404271A540CDC07F6DBB6" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_F4DCF7F4BC14DD2C10760CDC07F7237C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3" xlink:to="loc_us-gaap_CustomerRelationshipsMember_F4DCF7F4BC14DD2C10760CDC07F7237C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DevelopedTechnologyRightsMember" xlink:label="loc_us-gaap_DevelopedTechnologyRightsMember_595FD4412F801FA18A590CDC07F70FBF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3" xlink:to="loc_us-gaap_DevelopedTechnologyRightsMember_595FD4412F801FA18A590CDC07F70FBF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TradeNamesMember" xlink:label="loc_us-gaap_TradeNamesMember_E670AA769CBC5C0E51550CDC07F70D5B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_4023404A8CDD93C0FB240CDC07F61CC3" xlink:to="loc_us-gaap_TradeNamesMember_E670AA769CBC5C0E51550CDC07F70D5B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsGross" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsGross_A418218D4182FBFB52410CDC07F7A872" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_6E8CFC95AF48231DF9550CDC07F7A860" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsGross_A418218D4182FBFB52410CDC07F7A872" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_86DC210759677E68897C0CDC07F88931" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_6E8CFC95AF48231DF9550CDC07F7A860" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_86DC210759677E68897C0CDC07F88931" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsNet" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsNet_77164FA193186F2958630CDC07F8CD95" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_6E8CFC95AF48231DF9550CDC07F7A860" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsNet_77164FA193186F2958630CDC07F8CD95" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetWeightedAveragePeriodBeforeNextRenewalOrExtension" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetWeightedAveragePeriodBeforeNextRenewalOrExtension_19221FD13DAA09A001740CDC07F84A2E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_6E8CFC95AF48231DF9550CDC07F7A860" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetWeightedAveragePeriodBeforeNextRenewalOrExtension_19221FD13DAA09A001740CDC07F84A2E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/GoodwillAndIntangibleAssetsNetTables" 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_FC108CB6E137A44C202E32C50C4CD11B" 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_807E45CE11B880A447FD32C50C46DF54" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdjustmentsForNewAccountingPronouncementsAxis" xlink:label="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5FE450FA3DA49DBD902A32C50C47C172" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5FE450FA3DA49DBD902A32C50C47C172" 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_98F99E80A1389522DFB932C50C476D99_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5FE450FA3DA49DBD902A32C50C47C172" xlink:to="loc_us-gaap_TypeOfAdoptionMember_98F99E80A1389522DFB932C50C476D99_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_98F99E80A1389522DFB932C50C476D99" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_5FE450FA3DA49DBD902A32C50C47C172" xlink:to="loc_us-gaap_TypeOfAdoptionMember_98F99E80A1389522DFB932C50C476D99" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountingStandardsUpdate201616Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201616Member_A7663015E7BB6399165532C50C475F04" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_98F99E80A1389522DFB932C50C476D99" xlink:to="loc_us-gaap_AccountingStandardsUpdate201616Member_A7663015E7BB6399165532C50C475F04" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountingStandardsUpdate201609Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201609Member_7424E2F9B7126D6A00BF32C50C470DC0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_98F99E80A1389522DFB932C50C476D99" xlink:to="loc_us-gaap_AccountingStandardsUpdate201609Member_7424E2F9B7126D6A00BF32C50C470DC0" xlink:type="arc" />
    <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_B430233FB8F7CCD0097732C50C48D8B7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:to="loc_us-gaap_IncomeTaxAuthorityNameAxis_B430233FB8F7CCD0097732C50C48D8B7" 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_BAE78987E437D098523132C50C48FFA6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameAxis_B430233FB8F7CCD0097732C50C48D8B7" xlink:to="loc_us-gaap_IncomeTaxAuthorityNameDomain_BAE78987E437D098523132C50C48FFA6_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_BAE78987E437D098523132C50C48FFA6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameAxis_B430233FB8F7CCD0097732C50C48D8B7" xlink:to="loc_us-gaap_IncomeTaxAuthorityNameDomain_BAE78987E437D098523132C50C48FFA6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CaliforniaFranchiseTaxBoardMember" xlink:label="loc_us-gaap_CaliforniaFranchiseTaxBoardMember_AFBA555AD02368AA042A32C50C488E3F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameDomain_BAE78987E437D098523132C50C48FFA6" xlink:to="loc_us-gaap_CaliforniaFranchiseTaxBoardMember_AFBA555AD02368AA042A32C50C488E3F" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_OtherStateMember" xlink:label="loc_run_OtherStateMember_68A1397A56A0765CF39D32C50C481653" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameDomain_BAE78987E437D098523132C50C48FFA6" xlink:to="loc_run_OtherStateMember_68A1397A56A0765CF39D32C50C481653" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CaliforniaEnterpriseZoneCreditsMember" xlink:label="loc_run_CaliforniaEnterpriseZoneCreditsMember_36BEC68307729632FFF032C50C49BF90" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityNameDomain_BAE78987E437D098523132C50C48FFA6" xlink:to="loc_run_CaliforniaEnterpriseZoneCreditsMember_36BEC68307729632FFF032C50C49BF90" 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_EB790D9B2CA2EACC6E0232C50C4991A4" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:to="loc_us-gaap_IncomeTaxAuthorityAxis_EB790D9B2CA2EACC6E0232C50C4991A4" 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_E094F15C998D2B73514E32C50C49FB13_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeTaxAuthorityAxis_EB790D9B2CA2EACC6E0232C50C4991A4" xlink:to="loc_us-gaap_IncomeTaxAuthorityDomain_E094F15C998D2B73514E32C50C49FB13_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_E094F15C998D2B73514E32C50C49FB13" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeTaxAuthorityAxis_EB790D9B2CA2EACC6E0232C50C4991A4" xlink:to="loc_us-gaap_IncomeTaxAuthorityDomain_E094F15C998D2B73514E32C50C49FB13" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCountryMember" xlink:label="loc_us-gaap_DomesticCountryMember_53958A7AE569B3D4FA8D32C50C49ED18" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityDomain_E094F15C998D2B73514E32C50C49FB13" xlink:to="loc_us-gaap_DomesticCountryMember_53958A7AE569B3D4FA8D32C50C49ED18" 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_98BC2D6EFA7C5D09ACFE32C50C49D5F1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityDomain_E094F15C998D2B73514E32C50C49FB13" xlink:to="loc_us-gaap_StateAndLocalJurisdictionMember_98BC2D6EFA7C5D09ACFE32C50C49D5F1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementScenarioAxis" xlink:label="loc_us-gaap_StatementScenarioAxis_1063987D201EC05E168432C50C49C18E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:to="loc_us-gaap_StatementScenarioAxis_1063987D201EC05E168432C50C49C18E" 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_AB9611234BABF17DE26632C50C4A68B6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_1063987D201EC05E168432C50C49C18E" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_AB9611234BABF17DE26632C50C4A68B6_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_AB9611234BABF17DE26632C50C4A68B6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_1063987D201EC05E168432C50C49C18E" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_AB9611234BABF17DE26632C50C4A68B6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioAdjustmentMember" xlink:label="loc_us-gaap_ScenarioAdjustmentMember_BAEC232FF193B1377A6432C50C4A2AA2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_AB9611234BABF17DE26632C50C4A68B6" xlink:to="loc_us-gaap_ScenarioAdjustmentMember_BAEC232FF193B1377A6432C50C4A2AA2" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_4F68945D4C56A0FFEE1E32C50C4A73B7" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_4F68945D4C56A0FFEE1E32C50C4A73B7" 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_8B37383A6F37BA07DB7B32C50C4AC734_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_4F68945D4C56A0FFEE1E32C50C4A73B7" xlink:to="loc_us-gaap_EquityComponentDomain_8B37383A6F37BA07DB7B32C50C4AC734_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_8B37383A6F37BA07DB7B32C50C4AC734" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_4F68945D4C56A0FFEE1E32C50C4A73B7" xlink:to="loc_us-gaap_EquityComponentDomain_8B37383A6F37BA07DB7B32C50C4AC734" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_56A6EBFD2C692C1D49D432C50C4B7DAE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_8B37383A6F37BA07DB7B32C50C4AC734" xlink:to="loc_us-gaap_RetainedEarningsMember_56A6EBFD2C692C1D49D432C50C4B7DAE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BalanceSheetLocationAxis" xlink:label="loc_us-gaap_BalanceSheetLocationAxis_3D050F34B434D61D5BDF32C50C4B5330" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_807E45CE11B880A447FD32C50C46DF54" xlink:to="loc_us-gaap_BalanceSheetLocationAxis_3D050F34B434D61D5BDF32C50C4B5330" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BalanceSheetLocationDomain" xlink:label="loc_us-gaap_BalanceSheetLocationDomain_06B24B374531A0FE957432C50C4BEA38_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_BalanceSheetLocationAxis_3D050F34B434D61D5BDF32C50C4B5330" xlink:to="loc_us-gaap_BalanceSheetLocationDomain_06B24B374531A0FE957432C50C4BEA38_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_BalanceSheetLocationDomain" xlink:label="loc_us-gaap_BalanceSheetLocationDomain_06B24B374531A0FE957432C50C4BEA38" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_BalanceSheetLocationAxis_3D050F34B434D61D5BDF32C50C4B5330" xlink:to="loc_us-gaap_BalanceSheetLocationDomain_06B24B374531A0FE957432C50C4BEA38" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredTaxAssetMember" xlink:label="loc_run_DeferredTaxAssetMember_05DC553FC2C2A54CE8CC32C50C4BC79D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_BalanceSheetLocationDomain_06B24B374531A0FE957432C50C4BEA38" xlink:to="loc_run_DeferredTaxAssetMember_05DC553FC2C2A54CE8CC32C50C4BC79D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_InvestmentTaxCredit" xlink:label="loc_us-gaap_InvestmentTaxCredit_AB704CF656B624DBDFF632C50C4C1BA1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_InvestmentTaxCredit_AB704CF656B624DBDFF632C50C4C1BA1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxAssetsValuationAllowance" xlink:label="loc_us-gaap_DeferredTaxAssetsValuationAllowance_A02B96760C9A782EC56732C50C4CF0C3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_DeferredTaxAssetsValuationAllowance_A02B96760C9A782EC56732C50C4CF0C3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ValuationAllowanceDeferredTaxAssetChangeInAmount" xlink:label="loc_us-gaap_ValuationAllowanceDeferredTaxAssetChangeInAmount_2011477ADC81AEA4C30632C50C4CFD8E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_ValuationAllowanceDeferredTaxAssetChangeInAmount_2011477ADC81AEA4C30632C50C4CFD8E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PrepaidTaxes" xlink:label="loc_us-gaap_PrepaidTaxes_87B0969D6833E1A2ABEB32C50C4C01E5" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_PrepaidTaxes_87B0969D6833E1A2ABEB32C50C4C01E5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxAssetsGross" xlink:label="loc_us-gaap_DeferredTaxAssetsGross_B6DB83005015EA749F1F32C50C4DA1FF" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_DeferredTaxAssetsGross_B6DB83005015EA749F1F32C50C4DA1FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxAssetsOperatingLossCarryforwardsDomestic" xlink:label="loc_us-gaap_DeferredTaxAssetsOperatingLossCarryforwardsDomestic_DA9BFA42722D44DB273B32C50C4D2B18" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_DeferredTaxAssetsOperatingLossCarryforwardsDomestic_DA9BFA42722D44DB273B32C50C4D2B18" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxAssetsOperatingLossCarryforwardsStateAndLocal" xlink:label="loc_us-gaap_DeferredTaxAssetsOperatingLossCarryforwardsStateAndLocal_7BFC16403F93AEC586A232C50C4D21E7" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_DeferredTaxAssetsOperatingLossCarryforwardsStateAndLocal_7BFC16403F93AEC586A232C50C4D21E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_665FAA7F487C63E17DBD32C50C4D9075" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_665FAA7F487C63E17DBD32C50C4D9075" 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_E014832F7186E8ED790832C50C4D4FD2" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_E014832F7186E8ED790832C50C4D4FD2" 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_3CA99D0EC6F5CB6FF9C232C50C4DA56E" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_UnrecognizedTaxBenefits_3CA99D0EC6F5CB6FF9C232C50C4DA56E" 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_F980B227D19B8301D18132C50C4E2027" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsIncomeTaxPenaltiesAndInterestAccrued_F980B227D19B8301D18132C50C4E2027" 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_89813504C7FA6E7101C232C50C4ED1B8" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_89813504C7FA6E7101C232C50C4ED1B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_UnrecognizedTaxBenefitsPeriodIncreaseDecrease" xlink:label="loc_us-gaap_UnrecognizedTaxBenefitsPeriodIncreaseDecrease_02BD3F8796E014C8CAB032C50C4E2FAA" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_UnrecognizedTaxBenefitsPeriodIncreaseDecrease_02BD3F8796E014C8CAB032C50C4E2FAA" 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_146DB7D27B1EA7C2CFD832C50C4E1000" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_FC108CB6E137A44C202E32C50C4CD11B" xlink:to="loc_us-gaap_OperatingLossCarryforwards_146DB7D27B1EA7C2CFD832C50C4E1000" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesIncomeTaxProvisionBenefitDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesIncomeTaxesUnrecognizedTaxBenefitsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesLossBeforeIncomeTaxesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesReconciliationOfStatutoryFederalRateAndCompanysEffectiveTaxRateDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesSignificantComponentsOfDeferredTaxAssetsAndLiabilitiesDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesSummaryOfTaxYearsThatRemainOpenAndSubjectToExaminationByTaxAuthoritiesDetails" 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_4ADF1A6D15FA431678A132C50C3DE792" 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_0D65C39197E3A4B81EE532C50C3BFF03" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_4ADF1A6D15FA431678A132C50C3DE792" xlink:to="loc_us-gaap_IncomeTaxContingencyTable_0D65C39197E3A4B81EE532C50C3BFF03" 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_IncomeTaxAuthorityAxis" xlink:label="loc_us-gaap_IncomeTaxAuthorityAxis_69D46B2AA2BE2647046832C50C3CE7A7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_0D65C39197E3A4B81EE532C50C3BFF03" xlink:to="loc_us-gaap_IncomeTaxAuthorityAxis_69D46B2AA2BE2647046832C50C3CE7A7" 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_EAEBB7BCBBDF713AD74232C50C3C0FE8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeTaxAuthorityAxis_69D46B2AA2BE2647046832C50C3CE7A7" xlink:to="loc_us-gaap_IncomeTaxAuthorityDomain_EAEBB7BCBBDF713AD74232C50C3C0FE8_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_EAEBB7BCBBDF713AD74232C50C3C0FE8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeTaxAuthorityAxis_69D46B2AA2BE2647046832C50C3CE7A7" xlink:to="loc_us-gaap_IncomeTaxAuthorityDomain_EAEBB7BCBBDF713AD74232C50C3C0FE8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DomesticCountryMember" xlink:label="loc_us-gaap_DomesticCountryMember_AE3D4465B0CA41B9351532C50C3CBDB1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityDomain_EAEBB7BCBBDF713AD74232C50C3C0FE8" xlink:to="loc_us-gaap_DomesticCountryMember_AE3D4465B0CA41B9351532C50C3CBDB1" 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_41371646FC6D3462EC4C32C50C3C48AA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxAuthorityDomain_EAEBB7BCBBDF713AD74232C50C3C0FE8" xlink:to="loc_us-gaap_StateAndLocalJurisdictionMember_41371646FC6D3462EC4C32C50C3C48AA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TaxPeriodAxis" xlink:label="loc_us-gaap_TaxPeriodAxis_3669759839BB4F66FC1C32C50C3CD54A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_IncomeTaxContingencyTable_0D65C39197E3A4B81EE532C50C3BFF03" xlink:to="loc_us-gaap_TaxPeriodAxis_3669759839BB4F66FC1C32C50C3CD54A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TaxPeriodDomain" xlink:label="loc_us-gaap_TaxPeriodDomain_7A04BA55E7C590A43FD732C50C3D983A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_TaxPeriodAxis_3669759839BB4F66FC1C32C50C3CD54A" xlink:to="loc_us-gaap_TaxPeriodDomain_7A04BA55E7C590A43FD732C50C3D983A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TaxPeriodDomain" xlink:label="loc_us-gaap_TaxPeriodDomain_7A04BA55E7C590A43FD732C50C3D983A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_TaxPeriodAxis_3669759839BB4F66FC1C32C50C3CD54A" xlink:to="loc_us-gaap_TaxPeriodDomain_7A04BA55E7C590A43FD732C50C3D983A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EarliestTaxYearMember" xlink:label="loc_us-gaap_EarliestTaxYearMember_AAA0925679229079872232C50C3D7EE4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TaxPeriodDomain_7A04BA55E7C590A43FD732C50C3D983A" xlink:to="loc_us-gaap_EarliestTaxYearMember_AAA0925679229079872232C50C3D7EE4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LatestTaxYearMember" xlink:label="loc_us-gaap_LatestTaxYearMember_9F6024642E74B0DAF67432C50C3D1E2C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TaxPeriodDomain_7A04BA55E7C590A43FD732C50C3D983A" xlink:to="loc_us-gaap_LatestTaxYearMember_9F6024642E74B0DAF67432C50C3D1E2C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OpenTaxYear" xlink:label="loc_us-gaap_OpenTaxYear_CAAF88636FFF990BA53232C50C3E2187" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeTaxContingencyLineItems_4ADF1A6D15FA431678A132C50C3DE792" xlink:to="loc_us-gaap_OpenTaxYear_CAAF88636FFF990BA53232C50C3E2187" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IncomeTaxesTables" xlink:type="extended" />
  <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_971696F849011E75739C314EA90BFBE5" 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_85A867A3878294233D53314EA902A6BB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" 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_5030091D1FC584FF6144314EA90276FE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_us-gaap_DebtInstrumentAxis_5030091D1FC584FF6144314EA90276FE" 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_16AA12A9EC606324FE0F314EA902780C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_5030091D1FC584FF6144314EA90276FE" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C_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_16AA12A9EC606324FE0F314EA902780C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_5030091D1FC584FF6144314EA90276FE" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankLineOfCreditMember" xlink:label="loc_run_BankLineOfCreditMember_C7216E858BE0CB7789D5314EA903FBFB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_BankLineOfCreditMember_C7216E858BE0CB7789D5314EA903FBFB" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanDueinOctober2024Member" xlink:label="loc_run_TermLoanDueinOctober2024Member_F24EC5EBE890080ECB1C314EA903F075" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_TermLoanDueinOctober2024Member_F24EC5EBE890080ECB1C314EA903F075" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanDueinApril2024Member" xlink:label="loc_run_TermLoanDueinApril2024Member_503112751BFE3BA87D57314EA90308B3" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_TermLoanDueinApril2024Member_503112751BFE3BA87D57314EA90308B3" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanDueinDecember2020Member" xlink:label="loc_run_TermLoanDueinDecember2020Member_7E7873B7BA3B2C0F0FA8314EA9034632" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_TermLoanDueinDecember2020Member_7E7873B7BA3B2C0F0FA8314EA9034632" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanBMember" xlink:label="loc_run_TermLoanBMember_01F36CAC57E98E0D0598314EA903BC28" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_TermLoanBMember_01F36CAC57E98E0D0598314EA903BC28" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanBClassAMember" xlink:label="loc_run_TermLoanBClassAMember_F4364570B600EC4ED16C314EA904CB7C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_TermLoanBMember_01F36CAC57E98E0D0598314EA903BC28" xlink:to="loc_run_TermLoanBClassAMember_F4364570B600EC4ED16C314EA904CB7C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanBClassBMember" xlink:label="loc_run_TermLoanBClassBMember_20CC9FDBBBB0E48936F2314EA904F978" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_TermLoanBMember_01F36CAC57E98E0D0598314EA903BC28" xlink:to="loc_run_TermLoanBClassBMember_20CC9FDBBBB0E48936F2314EA904F978" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanMember" xlink:label="loc_run_TermLoanMember_1152665FEEE5CD6A7CC2314EA904A3B1" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_TermLoanMember_1152665FEEE5CD6A7CC2314EA904A3B1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanAMember" xlink:label="loc_run_TermLoanAMember_F2640B29CA3BEA8511D5314EA904DBFA" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_TermLoanAMember_F2640B29CA3BEA8511D5314EA904DBFA" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankLoanDueSeptember2020Member" xlink:label="loc_run_BankLoanDueSeptember2020Member_0227B7E0DB6A55305834314EA90405C1" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_BankLoanDueSeptember2020Member_0227B7E0DB6A55305834314EA90405C1" 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_B0E5814D59D51DDE1631314EA904CDE5" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_us-gaap_SubordinatedDebtMember_B0E5814D59D51DDE1631314EA904CDE5" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankTermLoanDueAprilTwentyTwentyTwoMember" xlink:label="loc_run_BankTermLoanDueAprilTwentyTwentyTwoMember_8169861249EBD1B9FD4C314EA904A941" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_BankTermLoanDueAprilTwentyTwentyTwoMember_8169861249EBD1B9FD4C314EA904A941" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheTwoMember" xlink:label="loc_run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheTwoMember_600ED077ACD74043CAC0314EA905A1B1" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_BankTermLoanDueSeptemberTwentyTwentyTwoTrancheTwoMember_600ED077ACD74043CAC0314EA905A1B1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankTermLoanDueJanuaryTwentyThirtyMember" xlink:label="loc_run_BankTermLoanDueJanuaryTwentyThirtyMember_A405795895488B6A0243315FFB6D9069" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_BankTermLoanDueJanuaryTwentyThirtyMember_A405795895488B6A0243315FFB6D9069" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SolarAssetBackedNotesMember" xlink:label="loc_run_SolarAssetBackedNotesMember_7088399775FC28690568314EA90529D7" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_SolarAssetBackedNotesMember_7088399775FC28690568314EA90529D7" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SRECLoansMember" xlink:label="loc_run_SRECLoansMember_9EA9B4B7F20BE1808D47314EA90507ED" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_16AA12A9EC606324FE0F314EA902780C" xlink:to="loc_run_SRECLoansMember_9EA9B4B7F20BE1808D47314EA90507ED" 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_8D75DF58246BE6EDAAF9314EA905089F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_us-gaap_LineOfCreditFacilityAxis_8D75DF58246BE6EDAAF9314EA905089F" 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_DA5BD0E458F931C9EEB1314EA905DF5C_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LineOfCreditFacilityAxis_8D75DF58246BE6EDAAF9314EA905089F" xlink:to="loc_us-gaap_LineOfCreditFacilityLenderDomain_DA5BD0E458F931C9EEB1314EA905DF5C_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_DA5BD0E458F931C9EEB1314EA905DF5C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LineOfCreditFacilityAxis_8D75DF58246BE6EDAAF9314EA905089F" xlink:to="loc_us-gaap_LineOfCreditFacilityLenderDomain_DA5BD0E458F931C9EEB1314EA905DF5C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AggregationFacilityOctober2024Member" xlink:label="loc_run_AggregationFacilityOctober2024Member_975DA0EEAA882F59E51A314EA90675D1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLenderDomain_DA5BD0E458F931C9EEB1314EA905DF5C" xlink:to="loc_run_AggregationFacilityOctober2024Member_975DA0EEAA882F59E51A314EA90675D1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AggregationFacilityMember" xlink:label="loc_run_AggregationFacilityMember_3C091E7BD655AA8A74B4314EA9065DC7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLenderDomain_DA5BD0E458F931C9EEB1314EA905DF5C" xlink:to="loc_run_AggregationFacilityMember_3C091E7BD655AA8A74B4314EA9065DC7" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RevolvingLoanFacilitySeptember2020Member" xlink:label="loc_run_RevolvingLoanFacilitySeptember2020Member_BE506387763C7F47E329314EA906E3F2" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LineOfCreditFacilityLenderDomain_DA5BD0E458F931C9EEB1314EA905DF5C" xlink:to="loc_run_RevolvingLoanFacilitySeptember2020Member_BE506387763C7F47E329314EA906E3F2" 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_8AB318A22BFC84B2993A314EA906D63F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_us-gaap_RangeAxis_8AB318A22BFC84B2993A314EA906D63F" 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_0F7F4E940FB1832DC012314EA9067883_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_8AB318A22BFC84B2993A314EA906D63F" xlink:to="loc_us-gaap_RangeMember_0F7F4E940FB1832DC012314EA9067883_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_0F7F4E940FB1832DC012314EA9067883" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_8AB318A22BFC84B2993A314EA906D63F" xlink:to="loc_us-gaap_RangeMember_0F7F4E940FB1832DC012314EA9067883" 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_AD1822D4CA83FDEEA019314EA9073DE3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_0F7F4E940FB1832DC012314EA9067883" xlink:to="loc_us-gaap_MinimumMember_AD1822D4CA83FDEEA019314EA9073DE3" 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_8F86EF0EB0AEA0246B9B314EA907A4C7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_0F7F4E940FB1832DC012314EA9067883" xlink:to="loc_us-gaap_MaximumMember_8F86EF0EB0AEA0246B9B314EA907A4C7" 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_18A20192DAEA37875F7D314EA9072AA6" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_us-gaap_VariableRateAxis_18A20192DAEA37875F7D314EA9072AA6" 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_98837BF1F6D92A194044314EA907327B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableRateAxis_18A20192DAEA37875F7D314EA9072AA6" xlink:to="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B_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_98837BF1F6D92A194044314EA907327B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableRateAxis_18A20192DAEA37875F7D314EA9072AA6" xlink:to="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B" 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_42A2576EB84DA15C1F88314EA907211F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B" xlink:to="loc_us-gaap_LondonInterbankOfferedRateLIBORMember_42A2576EB84DA15C1F88314EA907211F" 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_105027092E2EF07DFD02314EA90868BE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B" xlink:to="loc_us-gaap_BaseRateMember_105027092E2EF07DFD02314EA90868BE" 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_D6A637BE328F6312C319314EA90808CF" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B" xlink:to="loc_us-gaap_FederalFundsEffectiveSwapRateMember_D6A637BE328F6312C319314EA90808CF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PrimeRateMember" xlink:label="loc_us-gaap_PrimeRateMember_5079DC9ACE7E72AE18D2314EA9086B73" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B" xlink:to="loc_us-gaap_PrimeRateMember_5079DC9ACE7E72AE18D2314EA9086B73" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_LiborFloorRateMember" xlink:label="loc_run_LiborFloorRateMember_E7889AF1175486259AF9314EA908D28E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableRateDomain_98837BF1F6D92A194044314EA907327B" xlink:to="loc_run_LiborFloorRateMember_E7889AF1175486259AF9314EA908D28E" 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_C798C19853502AE485FA314EA9082159" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_us-gaap_CreditFacilityAxis_C798C19853502AE485FA314EA9082159" 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_26F9CFF0C28E77EE2757314EA909D120_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_CreditFacilityAxis_C798C19853502AE485FA314EA9082159" xlink:to="loc_us-gaap_CreditFacilityDomain_26F9CFF0C28E77EE2757314EA909D120_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_26F9CFF0C28E77EE2757314EA909D120" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_CreditFacilityAxis_C798C19853502AE485FA314EA9082159" xlink:to="loc_us-gaap_CreditFacilityDomain_26F9CFF0C28E77EE2757314EA909D120" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SeniorSecuredRevolvingLetterOfCreditFacilityMember" xlink:label="loc_run_SeniorSecuredRevolvingLetterOfCreditFacilityMember_5EF226E968AAC714C76D314EA909462D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_26F9CFF0C28E77EE2757314EA909D120" xlink:to="loc_run_SeniorSecuredRevolvingLetterOfCreditFacilityMember_5EF226E968AAC714C76D314EA909462D" 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_4C71812DBA56F1F6C423314EA9094061" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_26F9CFF0C28E77EE2757314EA909D120" xlink:to="loc_us-gaap_LineOfCreditMember_4C71812DBA56F1F6C423314EA9094061" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanMember" xlink:label="loc_run_TermLoanMember_454A8B61B299AC145C40314EA909B342" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_26F9CFF0C28E77EE2757314EA909D120" xlink:to="loc_run_TermLoanMember_454A8B61B299AC145C40314EA909B342" 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_FF34D20F93C576AEC812314EA90986C9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_CreditFacilityDomain_26F9CFF0C28E77EE2757314EA909D120" xlink:to="loc_us-gaap_LetterOfCreditMember_FF34D20F93C576AEC812314EA90986C9" 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_C4FD0B07AE9DE94DCED2314EA9092465" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_C4FD0B07AE9DE94DCED2314EA9092465" 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_1463421237A4B44A3121314EA90AB02E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_C4FD0B07AE9DE94DCED2314EA9092465" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_1463421237A4B44A3121314EA90AB02E_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_1463421237A4B44A3121314EA90AB02E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_C4FD0B07AE9DE94DCED2314EA9092465" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_1463421237A4B44A3121314EA90AB02E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RecourseDebtMember" xlink:label="loc_run_RecourseDebtMember_96FD3E550E9A46D0F5F0314EA90AACC0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_1463421237A4B44A3121314EA90AB02E" xlink:to="loc_run_RecourseDebtMember_96FD3E550E9A46D0F5F0314EA90AACC0" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_NonRecourseDebtMember" xlink:label="loc_run_NonRecourseDebtMember_B72B82616D9329FED1CE314EA90A6E77" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_1463421237A4B44A3121314EA90AB02E" xlink:to="loc_run_NonRecourseDebtMember_B72B82616D9329FED1CE314EA90A6E77" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_LegalEntityAxis" xlink:label="loc_dei_LegalEntityAxis_BCD692A94F3AA15F4BB8314EA90A3405" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_85A867A3878294233D53314EA902A6BB" xlink:to="loc_dei_LegalEntityAxis_BCD692A94F3AA15F4BB8314EA90A3405" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_dei_LegalEntityAxis_BCD692A94F3AA15F4BB8314EA90A3405" xlink:to="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.sec.gov/dei/2014/dei-2014-01-31.xsd#dei_EntityDomain" xlink:label="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_dei_LegalEntityAxis_BCD692A94F3AA15F4BB8314EA90A3405" xlink:to="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SubsidiaryThreeMember" xlink:label="loc_run_SubsidiaryThreeMember_B696DF2DA557068D4315316210C7EB5B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A" xlink:to="loc_run_SubsidiaryThreeMember_B696DF2DA557068D4315316210C7EB5B" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SubsidiaryOneMember" xlink:label="loc_run_SubsidiaryOneMember_5F67F42E9B5FB11D96CF314EA90B5987" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A" xlink:to="loc_run_SubsidiaryOneMember_5F67F42E9B5FB11D96CF314EA90B5987" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SubsidiaryTwoMember" xlink:label="loc_run_SubsidiaryTwoMember_2CCDBC0839476C73D152314EA90BD7FC" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_dei_EntityDomain_A9AF058DF4E3DA8DFB7B314EA90AB88A" xlink:to="loc_run_SubsidiaryTwoMember_2CCDBC0839476C73D152314EA90BD7FC" 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_1FA4E6F938428E764CE0314EA90B0E03" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity_1FA4E6F938428E764CE0314EA90B0E03" 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_C814F50C6CBA36704A54314EA90CB66A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_us-gaap_DebtInstrumentBasisSpreadOnVariableRate1_C814F50C6CBA36704A54314EA90CB66A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_MinimumUnencumberedLiquidAssets" xlink:label="loc_run_MinimumUnencumberedLiquidAssets_6CD31FDD341482E795E1314EA90CE4D7" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_MinimumUnencumberedLiquidAssets_6CD31FDD341482E795E1314EA90CE4D7" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DebtCovenantLiabilityMaintenance" xlink:label="loc_run_DebtCovenantLiabilityMaintenance_E07EB5D52632C409ACB23159BE98F5C3" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_DebtCovenantLiabilityMaintenance_E07EB5D52632C409ACB23159BE98F5C3" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InterestCoverageRatio" xlink:label="loc_run_InterestCoverageRatio_66EEE4AC0057B543D29B314EA90C580B" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_InterestCoverageRatio_66EEE4AC0057B543D29B314EA90C580B" 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_6CBB037AA83DA4820A43314EA90C504C" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_us-gaap_LongTermDebt_6CBB037AA83DA4820A43314EA90C504C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DebtInstrumentPrepaymentPenalty" xlink:label="loc_run_DebtInstrumentPrepaymentPenalty_2CCA49F3248045819748315BAF952B6A" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_DebtInstrumentPrepaymentPenalty_2CCA49F3248045819748315BAF952B6A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TermLoanPrepaymentPenaltyPercent" xlink:label="loc_run_TermLoanPrepaymentPenaltyPercent_F23B65743F041B491E96314EA90C9B45" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_TermLoanPrepaymentPenaltyPercent_F23B65743F041B491E96314EA90C9B45" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RevolvingLineOfCreditFacilityAvailablePeriodIncrease" xlink:label="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodIncrease_9AE9BE4CF846CA89FD75314EA90CCA65" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodIncrease_9AE9BE4CF846CA89FD75314EA90CCA65" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DebtInstrumentBasisSpreadonVariableRateFederalFundsRate" xlink:label="loc_run_DebtInstrumentBasisSpreadonVariableRateFederalFundsRate_F062B19B0047CF557641314EA90D5594" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_DebtInstrumentBasisSpreadonVariableRateFederalFundsRate_F062B19B0047CF557641314EA90D5594" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DebtInstrumentBasisSpreadOnVariableRatePeriodicIncrease" xlink:label="loc_run_DebtInstrumentBasisSpreadOnVariableRatePeriodicIncrease_28BEA389335529F95D6D314EA90D34D4" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_DebtInstrumentBasisSpreadOnVariableRatePeriodicIncrease_28BEA389335529F95D6D314EA90D34D4" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RevolvingLineOfCreditFacilityAvailablePeriodPeriodIncrease" xlink:label="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodPeriodIncrease_95A62A415FE342FC394C314EA90DBE41" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_RevolvingLineOfCreditFacilityAvailablePeriodPeriodIncrease_95A62A415FE342FC394C314EA90DBE41" 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_D15457376114837C964B314EA90DB15C" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_us-gaap_TransfersAccountedForAsSecuredBorrowingsAssetsCarryingAmount_D15457376114837C964B314EA90DB15C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DebtInstrumentDiscountRate" xlink:label="loc_run_DebtInstrumentDiscountRate_FBFA76A58A4EC67E9326314EA90D67DC" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_971696F849011E75739C314EA90BFBE5" xlink:to="loc_run_DebtInstrumentDiscountRate_FBFA76A58A4EC67E9326314EA90D67DC" 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_D0C132E0038AF29A62F7119D0D6B1B21" 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_71FD3F942E4954CC8CDF119D0D65046B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DebtInstrumentLineItems_D0C132E0038AF29A62F7119D0D6B1B21" xlink:to="loc_us-gaap_DebtInstrumentTable_71FD3F942E4954CC8CDF119D0D65046B" 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_BDD04256EBAA23DA88E8119D0D66F57A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_71FD3F942E4954CC8CDF119D0D65046B" xlink:to="loc_us-gaap_LongtermDebtTypeAxis_BDD04256EBAA23DA88E8119D0D66F57A" 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_2432E327D1AF5B732E3A119D0D66FA68_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_BDD04256EBAA23DA88E8119D0D66F57A" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_2432E327D1AF5B732E3A119D0D66FA68_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_2432E327D1AF5B732E3A119D0D66FA68" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_LongtermDebtTypeAxis_BDD04256EBAA23DA88E8119D0D66F57A" xlink:to="loc_us-gaap_LongtermDebtTypeDomain_2432E327D1AF5B732E3A119D0D66FA68" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RecourseDebtMember" xlink:label="loc_run_RecourseDebtMember_A01CD6BEDED0796B64DE119D0D661C0C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_2432E327D1AF5B732E3A119D0D66FA68" xlink:to="loc_run_RecourseDebtMember_A01CD6BEDED0796B64DE119D0D661C0C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_NonRecourseDebtMember" xlink:label="loc_run_NonRecourseDebtMember_C1087FDE79A2F7B6691D119D0D676C5F" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LongtermDebtTypeDomain_2432E327D1AF5B732E3A119D0D66FA68" xlink:to="loc_run_NonRecourseDebtMember_C1087FDE79A2F7B6691D119D0D676C5F" 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_DBCD36FC5AD42DCB5516119D0D67D3EC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_71FD3F942E4954CC8CDF119D0D65046B" xlink:to="loc_us-gaap_DebtInstrumentAxis_DBCD36FC5AD42DCB5516119D0D67D3EC" 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_CF4FC88166B8F097899F119D0D67A064_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DebtInstrumentAxis_DBCD36FC5AD42DCB5516119D0D67D3EC" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064_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_CF4FC88166B8F097899F119D0D67A064" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DebtInstrumentAxis_DBCD36FC5AD42DCB5516119D0D67D3EC" xlink:to="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_BankLineOfCreditMember" xlink:label="loc_run_BankLineOfCreditMember_D2210BC0D8E97539F2E4119D0D6871FA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:to="loc_run_BankLineOfCreditMember_D2210BC0D8E97539F2E4119D0D6871FA" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SeniorDebtMember" xlink:label="loc_run_SeniorDebtMember_6EAB976A522C3D2F5334119D0D69B9BF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:to="loc_run_SeniorDebtMember_6EAB976A522C3D2F5334119D0D69B9BF" 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_8D13659FEED77AE524A0119D0D69C238" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:to="loc_us-gaap_SubordinatedDebtMember_8D13659FEED77AE524A0119D0D69C238" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SecuritizationDebtClassAMember" xlink:label="loc_run_SecuritizationDebtClassAMember_7FD303B7C88815A387BA119D0D6A2DBC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:to="loc_run_SecuritizationDebtClassAMember_7FD303B7C88815A387BA119D0D6A2DBC" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SecuritizationDebtClassBMember" xlink:label="loc_run_SecuritizationDebtClassBMember_3D733FA351216D8CE224119D0D6AAA71" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:to="loc_run_SecuritizationDebtClassBMember_3D733FA351216D8CE224119D0D6AAA71" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SRECLoansMember" xlink:label="loc_run_SRECLoansMember_83556534FD90A12E9251119D0D6A8F36" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentNameDomain_CF4FC88166B8F097899F119D0D67A064" xlink:to="loc_run_SRECLoansMember_83556534FD90A12E9251119D0D6A8F36" 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_E764B54ED9B8E74D9A34119D0D6AF894" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DebtInstrumentTable_71FD3F942E4954CC8CDF119D0D65046B" xlink:to="loc_us-gaap_RangeAxis_E764B54ED9B8E74D9A34119D0D6AF894" 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_07B84D43715BA2EFF2F3119D0D6AA589_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_E764B54ED9B8E74D9A34119D0D6AF894" xlink:to="loc_us-gaap_RangeMember_07B84D43715BA2EFF2F3119D0D6AA589_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_07B84D43715BA2EFF2F3119D0D6AA589" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_E764B54ED9B8E74D9A34119D0D6AF894" xlink:to="loc_us-gaap_RangeMember_07B84D43715BA2EFF2F3119D0D6AA589" 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_DD470BF0D3D689DC803F119D0D6BD380" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_07B84D43715BA2EFF2F3119D0D6AA589" xlink:to="loc_us-gaap_MinimumMember_DD470BF0D3D689DC803F119D0D6BD380" 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_8D609E056EADF9E856CB119D0D6B5773" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_07B84D43715BA2EFF2F3119D0D6AA589" xlink:to="loc_us-gaap_MaximumMember_8D609E056EADF9E856CB119D0D6B5773" 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_F05FFF968F04D5119FA7119D0D6B73D4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_D0C132E0038AF29A62F7119D0D6B1B21" xlink:to="loc_us-gaap_LongTermDebtCurrent_F05FFF968F04D5119FA7119D0D6B73D4" 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_A5934C219859C4FE797B119D0D6CFA4C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_D0C132E0038AF29A62F7119D0D6B1B21" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_A5934C219859C4FE797B119D0D6CFA4C" 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_4A2E9E284147DB35848D119D0D6C03AB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_D0C132E0038AF29A62F7119D0D6B1B21" xlink:to="loc_us-gaap_LongTermDebt_4A2E9E284147DB35848D119D0D6C03AB" 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_9B90FB71701DC403B0B8119D0D6CAE2B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_D0C132E0038AF29A62F7119D0D6B1B21" xlink:to="loc_us-gaap_DebtInstrumentUnusedBorrowingCapacityAmount_9B90FB71701DC403B0B8119D0D6CAE2B" 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_620A74279CB3FF5B6824119D0D6C063B" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DebtInstrumentLineItems_D0C132E0038AF29A62F7119D0D6B1B21" xlink:to="loc_us-gaap_DebtInstrumentInterestRateStatedPercentage_620A74279CB3FF5B6824119D0D6C063B" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/IndebtednessScheduleOfMaturitiesOfDebtExcludingDebtDiscountDetails" xlink:type="extended" />
  <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/NetIncomePerShare" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/NetIncomePerShareComputationOfBasicAndDilutedNetIncomeLossPerShareDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/NetIncomePerShareScheduleOfSharesExcludedFromComputationOfDilutedNetIncomeLossPerShareDetails" 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_4D8301D533095AC6172132C50BF4ADB1" 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_91B30ABD10B15F90BD5A32C50BF2F471" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_4D8301D533095AC6172132C50BF4ADB1" xlink:to="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_91B30ABD10B15F90BD5A32C50BF2F471" 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_D4A4847E11804123F95A32C50BF27FA0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable_91B30ABD10B15F90BD5A32C50BF2F471" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_D4A4847E11804123F95A32C50BF27FA0" 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_E311D1E6241454681CB932C50BF35333_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_D4A4847E11804123F95A32C50BF27FA0" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_E311D1E6241454681CB932C50BF35333_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_E311D1E6241454681CB932C50BF35333" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis_D4A4847E11804123F95A32C50BF27FA0" xlink:to="loc_us-gaap_AntidilutiveSecuritiesNameDomain_E311D1E6241454681CB932C50BF35333" 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_3121EB262861503A50CD32C50BF3CE07" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_E311D1E6241454681CB932C50BF35333" xlink:to="loc_us-gaap_WarrantMember_3121EB262861503A50CD32C50BF3CE07" 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_3C17812BFC17F7A2E2DF32C50BF3A4BB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_E311D1E6241454681CB932C50BF35333" xlink:to="loc_us-gaap_EmployeeStockOptionMember_3C17812BFC17F7A2E2DF32C50BF3A4BB" 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_8F7830DFDD2564E4700532C50BF47F53" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesNameDomain_E311D1E6241454681CB932C50BF35333" xlink:to="loc_us-gaap_RestrictedStockUnitsRSUMember_8F7830DFDD2564E4700532C50BF47F53" 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_45A4F694A154800F5B3032C50BF4510E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems_4D8301D533095AC6172132C50BF4ADB1" xlink:to="loc_us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount_45A4F694A154800F5B3032C50BF4510E" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/NetIncomePerShareTables" 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:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_OperatingLeasedAssetsLineItems" xlink:label="loc_us-gaap_OperatingLeasedAssetsLineItems_BE9E0DEC40526906BF4C32C50F27EDC6" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfOperatingLeasedAssetsTable" xlink:label="loc_us-gaap_ScheduleOfOperatingLeasedAssetsTable_00840FE5E0DFEDAD2A5332C50F26D92D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_OperatingLeasedAssetsLineItems_BE9E0DEC40526906BF4C32C50F27EDC6" xlink:to="loc_us-gaap_ScheduleOfOperatingLeasedAssetsTable_00840FE5E0DFEDAD2A5332C50F26D92D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_80D04884A10893873E6732C50F268077" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfOperatingLeasedAssetsTable_00840FE5E0DFEDAD2A5332C50F26D92D" xlink:to="loc_us-gaap_RangeAxis_80D04884A10893873E6732C50F268077" 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_673F6440D41006818D3532C50F26C5B8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_80D04884A10893873E6732C50F268077" xlink:to="loc_us-gaap_RangeMember_673F6440D41006818D3532C50F26C5B8_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_673F6440D41006818D3532C50F26C5B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_80D04884A10893873E6732C50F268077" xlink:to="loc_us-gaap_RangeMember_673F6440D41006818D3532C50F26C5B8" 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_A01DB6F031679FAEA8C932C50F27B06F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_673F6440D41006818D3532C50F26C5B8" xlink:to="loc_us-gaap_MinimumMember_A01DB6F031679FAEA8C932C50F27B06F" 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_EE6F266FC74F237E19A132C50F2757FC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_673F6440D41006818D3532C50F26C5B8" xlink:to="loc_us-gaap_MaximumMember_EE6F266FC74F237E19A132C50F2757FC" 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_C689B50DADBE442D956F32C50F275A08" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_OperatingLeasedAssetsLineItems_BE9E0DEC40526906BF4C32C50F27EDC6" xlink:to="loc_us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract_C689B50DADBE442D956F32C50F275A08" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/OtherAssets" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/OtherAssetsScheduleOfPrepaidExpensesAndOtherCurrentAssetsDetails" 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_970FD9B24520FD45B76930CE71BB4165" 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_BE699C82DBD5D62F761730CE71B9B2FF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_970FD9B24520FD45B76930CE71BB4165" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_BE699C82DBD5D62F761730CE71B9B2FF" 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_7091621EDED1FD5BBB8530CE71BAD80A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_BE699C82DBD5D62F761730CE71B9B2FF" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_7091621EDED1FD5BBB8530CE71BAD80A" 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_BD4E387B23CC1D53C1EA30CE71BA4730_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_7091621EDED1FD5BBB8530CE71BAD80A" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BD4E387B23CC1D53C1EA30CE71BA4730_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_BD4E387B23CC1D53C1EA30CE71BA4730" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_7091621EDED1FD5BBB8530CE71BAD80A" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BD4E387B23CC1D53C1EA30CE71BA4730" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SolarEnergySystemsUnderLeasePassThroughArrangementsMember" xlink:label="loc_run_SolarEnergySystemsUnderLeasePassThroughArrangementsMember_6AF7A4BBCF3A2D2437C630CE71BAD8C1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_BD4E387B23CC1D53C1EA30CE71BA4730" xlink:to="loc_run_SolarEnergySystemsUnderLeasePassThroughArrangementsMember_6AF7A4BBCF3A2D2437C630CE71BAD8C1" 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_F9239C2C7854DDB01C2030CE71BA2172" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_BE699C82DBD5D62F761730CE71B9B2FF" xlink:to="loc_us-gaap_RangeAxis_F9239C2C7854DDB01C2030CE71BA2172" 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_4D325453051D1CB9C04C30CE71BB059F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_F9239C2C7854DDB01C2030CE71BA2172" xlink:to="loc_us-gaap_RangeMember_4D325453051D1CB9C04C30CE71BB059F_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_4D325453051D1CB9C04C30CE71BB059F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_F9239C2C7854DDB01C2030CE71BA2172" xlink:to="loc_us-gaap_RangeMember_4D325453051D1CB9C04C30CE71BB059F" 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_96CE372C67D3B70BA61B30CE71BB5E65" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_4D325453051D1CB9C04C30CE71BB059F" xlink:to="loc_us-gaap_MinimumMember_96CE372C67D3B70BA61B30CE71BB5E65" 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_80C8E14277033C88134330CE71BB3A5C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_4D325453051D1CB9C04C30CE71BB059F" xlink:to="loc_us-gaap_MaximumMember_80C8E14277033C88134330CE71BB3A5C" 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_6E30D93C99F322705A7430CE71BBB23B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_970FD9B24520FD45B76930CE71BB4165" xlink:to="loc_us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract_6E30D93C99F322705A7430CE71BBB23B" 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_E28DCFF619F3AB59A59E30CE71BCB355" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_970FD9B24520FD45B76930CE71BB4165" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross_E28DCFF619F3AB59A59E30CE71BCB355" 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_1754A3915F157DE65A4530CE71BDC691" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_970FD9B24520FD45B76930CE71BB4165" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation_1754A3915F157DE65A4530CE71BDC691" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PercentageOfDiscountOnExpectedRemainingLeasePayments" xlink:label="loc_run_PercentageOfDiscountOnExpectedRemainingLeasePayments_B51026809026E656F8E730CE71BE36C3" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_970FD9B24520FD45B76930CE71BB4165" xlink:to="loc_run_PercentageOfDiscountOnExpectedRemainingLeasePayments_B51026809026E656F8E730CE71BE36C3" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/PropertyAndEquipmentNet" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/PropertyAndEquipmentNetAdditionalInformationDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/PropertyAndEquipmentNetScheduleOfPropertyAndEquipmentNetDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DA979D68F23E929123930CE72591106" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_DA5CB54A0ED989C0189D30CE7257BBF5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DA979D68F23E929123930CE72591106" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_DA5CB54A0ED989C0189D30CE7257BBF5" 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_C5960C195E5E1C1DF7E930CE7258A24F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_DA5CB54A0ED989C0189D30CE7257BBF5" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C5960C195E5E1C1DF7E930CE7258A24F" 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_15851BFD267E417AF04A30CE725819FC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C5960C195E5E1C1DF7E930CE7258A24F" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_15851BFD267E417AF04A30CE725819FC_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_15851BFD267E417AF04A30CE725819FC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_C5960C195E5E1C1DF7E930CE7258A24F" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_15851BFD267E417AF04A30CE725819FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MachineryAndEquipmentMember" xlink:label="loc_us-gaap_MachineryAndEquipmentMember_D0B188E6F2FE5D365D6C30CE7258AA5F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_15851BFD267E417AF04A30CE725819FC" xlink:to="loc_us-gaap_MachineryAndEquipmentMember_D0B188E6F2FE5D365D6C30CE7258AA5F" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_LeaseholdImprovementsFurnitureAndComputerMember" xlink:label="loc_run_LeaseholdImprovementsFurnitureAndComputerMember_047C1758EA5F1EAE4E4430CE7259F59A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_15851BFD267E417AF04A30CE725819FC" xlink:to="loc_run_LeaseholdImprovementsFurnitureAndComputerMember_047C1758EA5F1EAE4E4430CE7259F59A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VehiclesMember" xlink:label="loc_us-gaap_VehiclesMember_E726518F1693CD20557230CE725982B9" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_15851BFD267E417AF04A30CE725819FC" xlink:to="loc_us-gaap_VehiclesMember_E726518F1693CD20557230CE725982B9" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ComputerEquipmentMember" xlink:label="loc_us-gaap_ComputerEquipmentMember_3C87E06D365CFCE62A2A30CE72594934" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_15851BFD267E417AF04A30CE725819FC" xlink:to="loc_us-gaap_ComputerEquipmentMember_3C87E06D365CFCE62A2A30CE72594934" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentGross" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentGross_2548DF8EBA3DFACE0C6B30CE72594E99" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DA979D68F23E929123930CE72591106" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentGross_2548DF8EBA3DFACE0C6B30CE72594E99" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment" xlink:label="loc_us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment_1EE2A069B9C52C44054630CE7259DFAF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DA979D68F23E929123930CE72591106" xlink:to="loc_us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment_1EE2A069B9C52C44054630CE7259DFAF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentNet" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_EC64B3687CAACF1FCDBB30CE725A11CB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_2DA979D68F23E929123930CE72591106" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_EC64B3687CAACF1FCDBB30CE725A11CB" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/PropertyAndEquipmentNetTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/QuarterlyResultsOfOperations" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/QuarterlyResultsOfOperationsDetails" 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_F4A837C1A56DC64ACD493592C0B5B5F5" 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_DA0A725A6B7E3926205B3592C0B3E51A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_StatementTable_DA0A725A6B7E3926205B3592C0B3E51A" 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_3886E19294E53F3EE6733592C0B4E266" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_DA0A725A6B7E3926205B3592C0B3E51A" xlink:to="loc_us-gaap_ProductOrServiceAxis_3886E19294E53F3EE6733592C0B4E266" 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_9289BC7883411C78CF093592C0B4AC69_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_3886E19294E53F3EE6733592C0B4E266" xlink:to="loc_us-gaap_ProductsAndServicesDomain_9289BC7883411C78CF093592C0B4AC69_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_9289BC7883411C78CF093592C0B4AC69" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_3886E19294E53F3EE6733592C0B4E266" xlink:to="loc_us-gaap_ProductsAndServicesDomain_9289BC7883411C78CF093592C0B4AC69" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ServiceMember" xlink:label="loc_run_ServiceMember_A52F5539A8C5163D06473592C0B4AE86" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_9289BC7883411C78CF093592C0B4AC69" xlink:to="loc_run_ServiceMember_A52F5539A8C5163D06473592C0B4AE86" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProductMember" xlink:label="loc_us-gaap_ProductMember_ABFE2F6D073322B6F2BB3592C0B45824" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_9289BC7883411C78CF093592C0B4AC69" xlink:to="loc_us-gaap_ProductMember_ABFE2F6D073322B6F2BB3592C0B45824" 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_406F50E92F0312045ACF3592C0B5FCC1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_StatementTable_DA0A725A6B7E3926205B3592C0B3E51A" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_406F50E92F0312045ACF3592C0B5FCC1" 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_D04485070AFD9F777DFC3592C0B51D27_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_406F50E92F0312045ACF3592C0B5FCC1" xlink:to="loc_us-gaap_TypeOfAdoptionMember_D04485070AFD9F777DFC3592C0B51D27_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_D04485070AFD9F777DFC3592C0B51D27" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_406F50E92F0312045ACF3592C0B5FCC1" xlink:to="loc_us-gaap_TypeOfAdoptionMember_D04485070AFD9F777DFC3592C0B51D27" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountingStandardsUpdate201409Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201409Member_23FABC5892384DC6F8103592C0B5B483" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_D04485070AFD9F777DFC3592C0B51D27" xlink:to="loc_us-gaap_AccountingStandardsUpdate201409Member_23FABC5892384DC6F8103592C0B5B483" 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_B4DFC4C3E2D758864EC43592C0B542FF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_Revenues_B4DFC4C3E2D758864EC43592C0B542FF" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CostOfGoodsAndServicesSold" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_C8351B690D37A32CE6113592C0B64067" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_C8351B690D37A32CE6113592C0B64067" 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_61D316FC6EDEF99B59DD3592C0B6D850" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_ProfitLoss_61D316FC6EDEF99B59DD3592C0B6D850" 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_690610B79514218BBCF83592C0B68E10" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_NetIncomeLoss_690610B79514218BBCF83592C0B68E10" 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_7C6B31A29E0A8B8A3F6F3592C0B650AB" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_EarningsPerShareBasic_7C6B31A29E0A8B8A3F6F3592C0B650AB" 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_6994D2CF1F0A7CCEC14A3592C0B788F7" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_EarningsPerShareDiluted_6994D2CF1F0A7CCEC14A3592C0B788F7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_2DD51F67C6CBE4946A643592C0B7D6F9" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_StatementLineItems_F4A837C1A56DC64ACD493592C0B5B5F5" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_2DD51F67C6CBE4946A643592C0B7D6F9" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/QuarterlyResultsOfOperationsTables" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RedeemableNoncontrollingInterests" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RedeemableNoncontrollingInterestsDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RelatedPartyTransactions" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/RelatedPartyTransactionsAdditionalInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RelatedPartyTransactionLineItems" xlink:label="loc_us-gaap_RelatedPartyTransactionLineItems_6893190F2FD2997CAE1532C50BED5936" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfRelatedPartyTransactionsByRelatedPartyTable" xlink:label="loc_us-gaap_ScheduleOfRelatedPartyTransactionsByRelatedPartyTable_5908D3DB7676A2C0719132C50BEC2935" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RelatedPartyTransactionLineItems_6893190F2FD2997CAE1532C50BED5936" xlink:to="loc_us-gaap_ScheduleOfRelatedPartyTransactionsByRelatedPartyTable_5908D3DB7676A2C0719132C50BEC2935" 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_RelatedPartyTransactionAxis" xlink:label="loc_us-gaap_RelatedPartyTransactionAxis_4648C0811F0E4B6907E932C50BECB681" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfRelatedPartyTransactionsByRelatedPartyTable_5908D3DB7676A2C0719132C50BEC2935" xlink:to="loc_us-gaap_RelatedPartyTransactionAxis_4648C0811F0E4B6907E932C50BECB681" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RelatedPartyTransactionDomain" xlink:label="loc_us-gaap_RelatedPartyTransactionDomain_D6AF828CBC495158CF3332C50BEC151B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RelatedPartyTransactionAxis_4648C0811F0E4B6907E932C50BECB681" xlink:to="loc_us-gaap_RelatedPartyTransactionDomain_D6AF828CBC495158CF3332C50BEC151B_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RelatedPartyTransactionDomain" xlink:label="loc_us-gaap_RelatedPartyTransactionDomain_D6AF828CBC495158CF3332C50BEC151B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RelatedPartyTransactionAxis_4648C0811F0E4B6907E932C50BECB681" xlink:to="loc_us-gaap_RelatedPartyTransactionDomain_D6AF828CBC495158CF3332C50BEC151B" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_EnphaseEnergyINCMember" xlink:label="loc_run_EnphaseEnergyINCMember_EC5C9DBF4CC5AE57B53C32C50BED357B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RelatedPartyTransactionDomain_D6AF828CBC495158CF3332C50BEC151B" xlink:to="loc_run_EnphaseEnergyINCMember_EC5C9DBF4CC5AE57B53C32C50BED357B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RelatedPartyTransactionPurchasesFromRelatedParty" xlink:label="loc_us-gaap_RelatedPartyTransactionPurchasesFromRelatedParty_45C534B63403BB1B24F432C50BED958F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RelatedPartyTransactionLineItems_6893190F2FD2997CAE1532C50BED5936" xlink:to="loc_us-gaap_RelatedPartyTransactionPurchasesFromRelatedParty_45C534B63403BB1B24F432C50BED958F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountsPayableRelatedPartiesCurrentAndNoncurrent" xlink:label="loc_us-gaap_AccountsPayableRelatedPartiesCurrentAndNoncurrent_FEF400BE23FEA8C1A89632C50BEEF7BD" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RelatedPartyTransactionLineItems_6893190F2FD2997CAE1532C50BED5936" xlink:to="loc_us-gaap_AccountsPayableRelatedPartiesCurrentAndNoncurrent_FEF400BE23FEA8C1A89632C50BEEF7BD" xlink:type="arc" />
  </link:definitionLink>
  <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_5BE861539DD5EE4E7E4A30CE72659F38" 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_B5069D76560747ABD9A830CE726486D6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_5BE861539DD5EE4E7E4A30CE72659F38" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_B5069D76560747ABD9A830CE726486D6" 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_56EA25F25C8C6D70A9BE30CE726483BE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseByMajorPropertyClassTable_B5069D76560747ABD9A830CE726486D6" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_56EA25F25C8C6D70A9BE30CE726483BE" 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_1BBA4E5A675D919D501E30CE726434E6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_56EA25F25C8C6D70A9BE30CE726483BE" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_1BBA4E5A675D919D501E30CE726434E6_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_1BBA4E5A675D919D501E30CE726434E6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_56EA25F25C8C6D70A9BE30CE726483BE" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_1BBA4E5A675D919D501E30CE726434E6" 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_19C64C6D9B4E40899A6C30CE726550C7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_1BBA4E5A675D919D501E30CE726434E6" xlink:to="loc_us-gaap_EquipmentMember_19C64C6D9B4E40899A6C30CE726550C7" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InvertersMember" xlink:label="loc_run_InvertersMember_4123350B813A825E2D4330CE7265768B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_1BBA4E5A675D919D501E30CE726434E6" xlink:to="loc_run_InvertersMember_4123350B813A825E2D4330CE7265768B" 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_634D55428D91EA82819830CE726521DA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_5BE861539DD5EE4E7E4A30CE72659F38" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseGross_634D55428D91EA82819830CE726521DA" 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_E4BACDC2A01D42DD5BC930CE726690B0" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_5BE861539DD5EE4E7E4A30CE72659F38" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseAccumulatedDepreciation_E4BACDC2A01D42DD5BC930CE726690B0" 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_BE63BCCFE14FE816111D30CE7266C012" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_5BE861539DD5EE4E7E4A30CE72659F38" xlink:to="loc_us-gaap_ConstructionInProgressGross_BE63BCCFE14FE816111D30CE7266C012" 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_770B919988A45952969830CE72668318" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseLineItems_5BE861539DD5EE4E7E4A30CE72659F38" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_770B919988A45952969830CE72668318" 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_0BFFE12A3F5DDD9FD1D632C50D19670D" 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_B471367C2DCA484ED7D032C50D0E924C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B471367C2DCA484ED7D032C50D0E924C" 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_3E37E23F8CE4C9A11DCB32C50D0E93D0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B471367C2DCA484ED7D032C50D0E924C" xlink:to="loc_us-gaap_PlanNameAxis_3E37E23F8CE4C9A11DCB32C50D0E93D0" 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_69D0FBA21CA96CA2D10232C50D0F8862_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PlanNameAxis_3E37E23F8CE4C9A11DCB32C50D0E93D0" xlink:to="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862_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_69D0FBA21CA96CA2D10232C50D0F8862" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PlanNameAxis_3E37E23F8CE4C9A11DCB32C50D0E93D0" xlink:to="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_MECTwoThousandNineStockPlanMember" xlink:label="loc_run_MECTwoThousandNineStockPlanMember_85CA342D2321FF8149B732C50D0FB72E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862" xlink:to="loc_run_MECTwoThousandNineStockPlanMember_85CA342D2321FF8149B732C50D0FB72E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TwoThousandThirteenEquityIncentivePlanMember" xlink:label="loc_run_TwoThousandThirteenEquityIncentivePlanMember_81A27E5FDC46C7D4C63332C50D0FE575" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862" xlink:to="loc_run_TwoThousandThirteenEquityIncentivePlanMember_81A27E5FDC46C7D4C63332C50D0FE575" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TwoThousandFourteenEquityIncentivePlanMember" xlink:label="loc_run_TwoThousandFourteenEquityIncentivePlanMember_52C15A57392DBD4A9CC932C50D1009C1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862" xlink:to="loc_run_TwoThousandFourteenEquityIncentivePlanMember_52C15A57392DBD4A9CC932C50D1009C1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TwoThousandFifteenEquityIncentivePlanMember" xlink:label="loc_run_TwoThousandFifteenEquityIncentivePlanMember_37EC9617B335E045A60A32C50D1043B9" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862" xlink:to="loc_run_TwoThousandFifteenEquityIncentivePlanMember_37EC9617B335E045A60A32C50D1043B9" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_EmployeeStockPurchasePlanMember" xlink:label="loc_run_EmployeeStockPurchasePlanMember_741AA410F716B8599D5732C50D109208" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_69D0FBA21CA96CA2D10232C50D0F8862" xlink:to="loc_run_EmployeeStockPurchasePlanMember_741AA410F716B8599D5732C50D109208" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VestingAxis" xlink:label="loc_us-gaap_VestingAxis_59A4B29DEE2F5904F67D32C50D10BEA7" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B471367C2DCA484ED7D032C50D0E924C" xlink:to="loc_us-gaap_VestingAxis_59A4B29DEE2F5904F67D32C50D10BEA7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VestingDomain" xlink:label="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VestingAxis_59A4B29DEE2F5904F67D32C50D10BEA7" xlink:to="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_VestingDomain" xlink:label="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VestingAxis_59A4B29DEE2F5904F67D32C50D10BEA7" xlink:to="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationAwardTrancheOneMember" xlink:label="loc_us-gaap_ShareBasedCompensationAwardTrancheOneMember_9611896940CE6BC3531832C50D1121B8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:to="loc_us-gaap_ShareBasedCompensationAwardTrancheOneMember_9611896940CE6BC3531832C50D1121B8" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationAwardTrancheTwoMember" xlink:label="loc_us-gaap_ShareBasedCompensationAwardTrancheTwoMember_33BFCFD875046C48542E32C50D1183C6" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:to="loc_us-gaap_ShareBasedCompensationAwardTrancheTwoMember_33BFCFD875046C48542E32C50D1183C6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationAwardTrancheThreeMember" xlink:label="loc_us-gaap_ShareBasedCompensationAwardTrancheThreeMember_EA4C3A5BBF5A49FB4C6B32C50D1127C2" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:to="loc_us-gaap_ShareBasedCompensationAwardTrancheThreeMember_EA4C3A5BBF5A49FB4C6B32C50D1127C2" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationAwardTrancheFourMember" xlink:label="loc_run_ShareBasedCompensationAwardTrancheFourMember_DED6C4A27B37710E103532C50D117754" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:to="loc_run_ShareBasedCompensationAwardTrancheFourMember_DED6C4A27B37710E103532C50D117754" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationAwardTrancheSixMember" xlink:label="loc_run_ShareBasedCompensationAwardTrancheSixMember_DDAC2BDB107BDF6212C632C50D117714" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:to="loc_run_ShareBasedCompensationAwardTrancheSixMember_DDAC2BDB107BDF6212C632C50D117714" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationAwardTrancheFiveMember" xlink:label="loc_run_ShareBasedCompensationAwardTrancheFiveMember_6AE8A40A52846017357B32C50D1188AE" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VestingDomain_47EE62B3B9044B6CA92A32C50D10202E" xlink:to="loc_run_ShareBasedCompensationAwardTrancheFiveMember_6AE8A40A52846017357B32C50D1188AE" 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_9BFFD8A419116ADB9DE732C50D118F32" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B471367C2DCA484ED7D032C50D0E924C" xlink:to="loc_us-gaap_RangeAxis_9BFFD8A419116ADB9DE732C50D118F32" 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_636378F6C3D8111E678432C50D175AB8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_9BFFD8A419116ADB9DE732C50D118F32" xlink:to="loc_us-gaap_RangeMember_636378F6C3D8111E678432C50D175AB8_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_636378F6C3D8111E678432C50D175AB8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_9BFFD8A419116ADB9DE732C50D118F32" xlink:to="loc_us-gaap_RangeMember_636378F6C3D8111E678432C50D175AB8" 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_30151FB321555CEA938832C50D170A6A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_636378F6C3D8111E678432C50D175AB8" xlink:to="loc_us-gaap_MaximumMember_30151FB321555CEA938832C50D170A6A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_0D35691584CA81E5E6EB32C50D1794A1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B471367C2DCA484ED7D032C50D0E924C" xlink:to="loc_us-gaap_AwardTypeAxis_0D35691584CA81E5E6EB32C50D1794A1" 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_7F2B4FD2821C91E3467932C50D180C59_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_0D35691584CA81E5E6EB32C50D1794A1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7F2B4FD2821C91E3467932C50D180C59_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_7F2B4FD2821C91E3467932C50D180C59" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_0D35691584CA81E5E6EB32C50D1794A1" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7F2B4FD2821C91E3467932C50D180C59" 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_9B5E303E113FFF96608632C50D1817AC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7F2B4FD2821C91E3467932C50D180C59" xlink:to="loc_us-gaap_RestrictedStockUnitsRSUMember_9B5E303E113FFF96608632C50D1817AC" 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_0FB8FC0AE2A55C44E01C32C50D180E39" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7F2B4FD2821C91E3467932C50D180C59" xlink:to="loc_us-gaap_EmployeeStockOptionMember_0FB8FC0AE2A55C44E01C32C50D180E39" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PerformanceBasedAwardsPlanMember" xlink:label="loc_run_PerformanceBasedAwardsPlanMember_7885DEFFE659EBB1181532C50D18CAFE" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_7F2B4FD2821C91E3467932C50D180C59" xlink:to="loc_run_PerformanceBasedAwardsPlanMember_7885DEFFE659EBB1181532C50D18CAFE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_05A21D89B72CE75F19BC32C50D18AAB4" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_B471367C2DCA484ED7D032C50D0E924C" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_05A21D89B72CE75F19BC32C50D18AAB4" 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_D886E304D562D1E1A5F732C50D19DDDA_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_05A21D89B72CE75F19BC32C50D18AAB4" xlink:to="loc_us-gaap_EquityComponentDomain_D886E304D562D1E1A5F732C50D19DDDA_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_D886E304D562D1E1A5F732C50D19DDDA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_05A21D89B72CE75F19BC32C50D18AAB4" xlink:to="loc_us-gaap_EquityComponentDomain_D886E304D562D1E1A5F732C50D19DDDA" 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_54215625B685E1C463CB32C50D193319" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_D886E304D562D1E1A5F732C50D19DDDA" xlink:to="loc_us-gaap_WarrantMember_54215625B685E1C463CB32C50D193319" 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_8ADF20EC2A141646E10332C50D19153F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_CommonStockSharesOutstanding_8ADF20EC2A141646E10332C50D19153F" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfAdditionalSharesAuthorized" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfAdditionalSharesAuthorized_4BD67DB8B7930AD4419832C50D1A8951" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfAdditionalSharesAuthorized_4BD67DB8B7930AD4419832C50D1A8951" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockCapitalSharesReservedForFutureIssuance" xlink:label="loc_us-gaap_CommonStockCapitalSharesReservedForFutureIssuance_1D10E399E1A381FD678532C50D1A7FE1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_CommonStockCapitalSharesReservedForFutureIssuance_1D10E399E1A381FD678532C50D1A7FE1" 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_1331A445931900B11E0F32C50D1A896D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod_1331A445931900B11E0F32C50D1A896D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_68A15F302F979AC9423732C50D1AFEC7" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1_68A15F302F979AC9423732C50D1AFEC7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage" xlink:label="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage_F7690996EF7134B74CC232C50D1ABE40" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage_F7690996EF7134B74CC232C50D1ABE40" 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_A508DE3ED37E0B2FFE5B32C50D1A5162" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_A508DE3ED37E0B2FFE5B32C50D1A5162" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_MinimumAnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfFirstDayOfEachFiscalYear" xlink:label="loc_run_MinimumAnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfFirstDayOfEachFiscalYear_B509B5B0B8A25544553F32C50D1BD9D0" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_MinimumAnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfFirstDayOfEachFiscalYear_B509B5B0B8A25544553F32C50D1BD9D0" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_MinimumPercentageOfAnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfLastDayOfImmediatelyPrecedingFiscalYear" xlink:label="loc_run_MinimumPercentageOfAnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfLastDayOfImmediatelyPrecedingFiscalYear_882E2D58D4114A691E3A32C50D1BD6DD" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_MinimumPercentageOfAnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfLastDayOfImmediatelyPrecedingFiscalYear_882E2D58D4114A691E3A32C50D1BD6DD" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AdditionalCommonStockSharesReservedForIssuance" xlink:label="loc_run_AdditionalCommonStockSharesReservedForIssuance_9983FA09C7D91DF29A0432C50D1BBDED" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_AdditionalCommonStockSharesReservedForIssuance_9983FA09C7D91DF29A0432C50D1BBDED" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SharebasedCompensationArrangementBySharebasedPaymentAwardRepurchaseOptionsUnvestedExercisable" xlink:label="loc_run_SharebasedCompensationArrangementBySharebasedPaymentAwardRepurchaseOptionsUnvestedExercisable_E6490AC303DB3F3A61F532C50D1B462A" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_SharebasedCompensationArrangementBySharebasedPaymentAwardRepurchaseOptionsUnvestedExercisable_E6490AC303DB3F3A61F532C50D1B462A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_StockIssuedDuringPeriodRepurchaseUnvestedStockOptionsExercised" xlink:label="loc_run_StockIssuedDuringPeriodRepurchaseUnvestedStockOptionsExercised_AB0B5160970A982AC60432C50D1BFD1D" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_StockIssuedDuringPeriodRepurchaseUnvestedStockOptionsExercised_AB0B5160970A982AC60432C50D1BFD1D" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfLastDayOfImmediatelyPrecedingFiscalYear" xlink:label="loc_run_AnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfLastDayOfImmediatelyPrecedingFiscalYear_F6914E4F2307BD93613B32C50D1BC4DB" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_AnnualIncreaseIncludedInCommonStockReservedForFutureIssuanceAsOfLastDayOfImmediatelyPrecedingFiscalYear_F6914E4F2307BD93613B32C50D1BC4DB" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_ABC480B9A042B7E9A0C232C50D1C9054" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_ABC480B9A042B7E9A0C232C50D1C9054" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_935D4F1E281847B9520532C50D1CFDD4" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardOptionsExercisesInPeriodTotalIntrinsicValue_935D4F1E281847B9520532C50D1CFDD4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardOptionsVestedInPeriodFairValue1" xlink:label="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardOptionsVestedInPeriodFairValue1_708715E6AE353C78284F32C50D1CCAB7" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardOptionsVestedInPeriodFairValue1_708715E6AE353C78284F32C50D1CCAB7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardTermsOfAward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardTermsOfAward_A679F9E62A37230D596432C50D1CB579" xlink:type="locator" />
    <link:definitionArc order="17" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardTermsOfAward_A679F9E62A37230D596432C50D1CB579" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SubjectToRepurchaseUnvestedStockOptionsOutstanding" xlink:label="loc_run_SubjectToRepurchaseUnvestedStockOptionsOutstanding_5EA4EB8ECBC0354093C732C50D1CC3FF" xlink:type="locator" />
    <link:definitionArc order="18" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_SubjectToRepurchaseUnvestedStockOptionsOutstanding_5EA4EB8ECBC0354093C732C50D1CC3FF" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationArrangementsByShareBasedPaymentAwardsVestingStartingPeriod" xlink:label="loc_run_ShareBasedCompensationArrangementsByShareBasedPaymentAwardsVestingStartingPeriod_020F683C6F54394A9FAA32C50D1CCEBD" xlink:type="locator" />
    <link:definitionArc order="19" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ShareBasedCompensationArrangementsByShareBasedPaymentAwardsVestingStartingPeriod_020F683C6F54394A9FAA32C50D1CCEBD" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationArrangementByShareBasedPaymentAwardExpirationYearAndMonth" xlink:label="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardExpirationYearAndMonth_9D78FCA93CF21C75B33A32C50D1C967D" xlink:type="locator" />
    <link:definitionArc order="20" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardExpirationYearAndMonth_9D78FCA93CF21C75B33A32C50D1C967D" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationArrangementByShareBasedPaymentEquityInstrumentsOtherThanOptionsOutstandingBeforeVestedAndExercisable" xlink:label="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentEquityInstrumentsOtherThanOptionsOutstandingBeforeVestedAndExercisable_AC15238D910E5A6DB54832C50D1D5C31" xlink:type="locator" />
    <link:definitionArc order="21" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentEquityInstrumentsOtherThanOptionsOutstandingBeforeVestedAndExercisable_AC15238D910E5A6DB54832C50D1D5C31" 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_D2102E64C46A5E81F7CB32C50D1D0D86" xlink:type="locator" />
    <link:definitionArc order="22" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_AllocatedShareBasedCompensationExpense_D2102E64C46A5E81F7CB32C50D1D0D86" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SharebasedCompensationArrangementbySharebasedPaymentAwardOfferingPeriod" xlink:label="loc_run_SharebasedCompensationArrangementbySharebasedPaymentAwardOfferingPeriod_BC025C9A45C82A12555732C50D1D8857" xlink:type="locator" />
    <link:definitionArc order="23" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_SharebasedCompensationArrangementbySharebasedPaymentAwardOfferingPeriod_BC025C9A45C82A12555732C50D1D8857" 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_53AF238B4181192A6D1A32C50D1DDA4A" xlink:type="locator" />
    <link:definitionArc order="24" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumEmployeeSubscriptionRate_53AF238B4181192A6D1A32C50D1DDA4A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumDeductibleFairMarketValueOfSharesPerCalendarYear" xlink:label="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumDeductibleFairMarketValueOfSharesPerCalendarYear_D89DC4E50107AD1C8AAF32C50D1DFE8D" xlink:type="locator" />
    <link:definitionArc order="25" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumDeductibleFairMarketValueOfSharesPerCalendarYear_D89DC4E50107AD1C8AAF32C50D1DFE8D" 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_DFDA1CB75BF60E557FF332C50D1E4EDA" xlink:type="locator" />
    <link:definitionArc order="26" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardMaximumNumberOfSharesPerEmployee_DFDA1CB75BF60E557FF332C50D1E4EDA" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ShareBasedCompensationArrangementByShareBasedPaymentAwardPlanOfferingPeriodDescription" xlink:label="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardPlanOfferingPeriodDescription_FD6EF4FE679B9356A60B32C50D1EDA7D" xlink:type="locator" />
    <link:definitionArc order="27" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ShareBasedCompensationArrangementByShareBasedPaymentAwardPlanOfferingPeriodDescription_FD6EF4FE679B9356A60B32C50D1EDA7D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_9DE8FEAEBF234B1BD10A32C50D1EE93A" xlink:type="locator" />
    <link:definitionArc order="28" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognized_9DE8FEAEBF234B1BD10A32C50D1EE93A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1" xlink:label="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_171BEEAA979EFD95A14532C50D23961A" xlink:type="locator" />
    <link:definitionArc order="29" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedPeriodForRecognition1_171BEEAA979EFD95A14532C50D23961A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightTerm" xlink:label="loc_run_ClassofWarrantorRightTerm_09D19DB5B6EE9EB0040F32C50D23EEE2" xlink:type="locator" />
    <link:definitionArc order="30" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightTerm_09D19DB5B6EE9EB0040F32C50D23EEE2" 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_C13CD3FDBF34BB6A846A32C50D232376" xlink:type="locator" />
    <link:definitionArc order="31" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ClassOfWarrantOrRightNumberOfSecuritiesCalledByWarrantsOrRights_C13CD3FDBF34BB6A846A32C50D232376" 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_465387BBB2D3892FC73632C50D244EB2" xlink:type="locator" />
    <link:definitionArc order="32" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_us-gaap_ClassOfWarrantOrRightExercisePriceOfWarrantsOrRights1_465387BBB2D3892FC73632C50D244EB2" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightVestingPercentage" xlink:label="loc_run_ClassofWarrantorRightVestingPercentage_C7A594A0F0AC3A90AD7932C50D24CBB9" xlink:type="locator" />
    <link:definitionArc order="33" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightVestingPercentage_C7A594A0F0AC3A90AD7932C50D24CBB9" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneOne" xlink:label="loc_run_ClassofWarrantorRightMilestoneOne_FD9E4B23CA0AD092172732C50D2441B9" xlink:type="locator" />
    <link:definitionArc order="34" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneOne_FD9E4B23CA0AD092172732C50D2441B9" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneOneDollarValue" xlink:label="loc_run_ClassofWarrantorRightMilestoneOneDollarValue_5F7EB01F02E63589ED7832C50D240221" xlink:type="locator" />
    <link:definitionArc order="35" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneOneDollarValue_5F7EB01F02E63589ED7832C50D240221" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightVestingTerm" xlink:label="loc_run_ClassofWarrantorRightVestingTerm_D5E9146268836450CD0C32C50D242BDD" xlink:type="locator" />
    <link:definitionArc order="36" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightVestingTerm_D5E9146268836450CD0C32C50D242BDD" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneTwo" xlink:label="loc_run_ClassofWarrantorRightMilestoneTwo_51970D14578BAB62AC2532C50D247F4B" xlink:type="locator" />
    <link:definitionArc order="37" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneTwo_51970D14578BAB62AC2532C50D247F4B" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassorRightMilestoneOneVestingPercentage" xlink:label="loc_run_ClassorRightMilestoneOneVestingPercentage_131B0172FC530F583D4832C50D24E77C" xlink:type="locator" />
    <link:definitionArc order="38" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassorRightMilestoneOneVestingPercentage_131B0172FC530F583D4832C50D24E77C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneTwoVestingPercentage" xlink:label="loc_run_ClassofWarrantorRightMilestoneTwoVestingPercentage_C68DA7FCB06E2B2B8C1032C50D250C8C" xlink:type="locator" />
    <link:definitionArc order="39" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneTwoVestingPercentage_C68DA7FCB06E2B2B8C1032C50D250C8C" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneOneandTwoDollarValue" xlink:label="loc_run_ClassofWarrantorRightMilestoneOneandTwoDollarValue_254FFA4A4DC9A1FDD33632C50D257A55" xlink:type="locator" />
    <link:definitionArc order="40" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneOneandTwoDollarValue_254FFA4A4DC9A1FDD33632C50D257A55" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneThreeVestingPercentage" xlink:label="loc_run_ClassofWarrantorRightMilestoneThreeVestingPercentage_AFB3CDC65315E23419AA32C50D259623" xlink:type="locator" />
    <link:definitionArc order="41" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneThreeVestingPercentage_AFB3CDC65315E23419AA32C50D259623" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ClassofWarrantorRightMilestoneThree" xlink:label="loc_run_ClassofWarrantorRightMilestoneThree_33D18F48BE57C5633C1832C50D257C14" xlink:type="locator" />
    <link:definitionArc order="42" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_0BFFE12A3F5DDD9FD1D632C50D19670D" xlink:to="loc_run_ClassofWarrantorRightMilestoneThree_33D18F48BE57C5633C1832C50D257C14" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationEstimatedFairValueOfStockOptionsDetails" 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_CC596C1136665888537D32C50CC00C2E" 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_8D786E82E2603807E03032C50CBEF2F2" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CC596C1136665888537D32C50CC00C2E" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8D786E82E2603807E03032C50CBEF2F2" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RangeAxis" xlink:label="loc_us-gaap_RangeAxis_5AB2B6B3435F30E1AE3232C50CBF7ACC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_8D786E82E2603807E03032C50CBEF2F2" xlink:to="loc_us-gaap_RangeAxis_5AB2B6B3435F30E1AE3232C50CBF7ACC" 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_98B19BEE91DD9F19E64732C50CBF0F11_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_5AB2B6B3435F30E1AE3232C50CBF7ACC" xlink:to="loc_us-gaap_RangeMember_98B19BEE91DD9F19E64732C50CBF0F11_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_98B19BEE91DD9F19E64732C50CBF0F11" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_5AB2B6B3435F30E1AE3232C50CBF7ACC" xlink:to="loc_us-gaap_RangeMember_98B19BEE91DD9F19E64732C50CBF0F11" 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_3AA1D65B0AB81594EAB932C50CBFFFFF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_98B19BEE91DD9F19E64732C50CBF0F11" xlink:to="loc_us-gaap_MinimumMember_3AA1D65B0AB81594EAB932C50CBFFFFF" 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_B2310CC8234C27C225D032C50CBFAE04" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_98B19BEE91DD9F19E64732C50CBF0F11" xlink:to="loc_us-gaap_MaximumMember_B2310CC8234C27C225D032C50CBFAE04" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsRiskFreeInterestRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsRiskFreeInterestRate_C6ED1FD3F327B2D7CAB832C50CC05F43" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CC596C1136665888537D32C50CC00C2E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsRiskFreeInterestRate_C6ED1FD3F327B2D7CAB832C50CC05F43" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_1C3EF75D37FB9AA087B832C50CC09C43" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CC596C1136665888537D32C50CC00C2E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedVolatilityRate_1C3EF75D37FB9AA087B832C50CC09C43" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardFairValueAssumptionsExpectedTerm1" xlink:label="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardFairValueAssumptionsExpectedTerm1_E519F72E0A17D92643B632C50CC0CE36" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CC596C1136665888537D32C50CC00C2E" xlink:to="loc_us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardFairValueAssumptionsExpectedTerm1_E519F72E0A17D92643B632C50CC0CE36" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_2EE5405B8D0C08E24F8432C50CC0F6BA" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_CC596C1136665888537D32C50CC00C2E" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardFairValueAssumptionsExpectedDividendRate_2EE5405B8D0C08E24F8432C50CC0F6BA" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockBasedCompensationSummaryOfActivityForAllRsusDetails" 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_9C5FFAE9899184755D500CDC0727598F" 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_F691C0B378CF83821C590CDC07265F02" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_9C5FFAE9899184755D500CDC0727598F" xlink:to="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_F691C0B378CF83821C590CDC07265F02" 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_2F5740BDC878779DBF170CDC0727C70D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable_F691C0B378CF83821C590CDC07265F02" xlink:to="loc_us-gaap_AwardTypeAxis_2F5740BDC878779DBF170CDC0727C70D" 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_174385A3A835B1167DE10CDC0727B17E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_2F5740BDC878779DBF170CDC0727C70D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_174385A3A835B1167DE10CDC0727B17E_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_174385A3A835B1167DE10CDC0727B17E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_2F5740BDC878779DBF170CDC0727C70D" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_174385A3A835B1167DE10CDC0727B17E" 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_C43EC7EDF8F5BFD899E70CDC0727F110" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_174385A3A835B1167DE10CDC0727B17E" xlink:to="loc_us-gaap_RestrictedStockUnitsRSUMember_C43EC7EDF8F5BFD899E70CDC0727F110" 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_686EB1856495156180780CDC0728FCEB" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_9C5FFAE9899184755D500CDC0727598F" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_686EB1856495156180780CDC0728FCEB" 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_C9A7BB08C482D1EA00540CDC07284B6B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_686EB1856495156180780CDC0728FCEB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedNumber_C9A7BB08C482D1EA00540CDC07284B6B" 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_26B2821CE99095CF2D4E0CDC07282033" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_686EB1856495156180780CDC0728FCEB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriod_26B2821CE99095CF2D4E0CDC07282033" 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_1F7BEDA84CA383D7C1730CDC0728A56E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_686EB1856495156180780CDC0728FCEB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriod_1F7BEDA84CA383D7C1730CDC0728A56E" 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_3F7ABEB8B2334F7FD5C30CDC0729FEEE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedRollForward_686EB1856495156180780CDC0728FCEB" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeitedInPeriod_3F7ABEB8B2334F7FD5C30CDC0729FEEE" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward" xlink:label="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_B40C3C6915E05CB857560CDC0729F6AC" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems_9C5FFAE9899184755D500CDC0727598F" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_B40C3C6915E05CB857560CDC0729F6AC" 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_F03F2E7BAF521C37DD740CDC07294D43" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_B40C3C6915E05CB857560CDC0729F6AC" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValue_F03F2E7BAF521C37DD740CDC07294D43" 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_594D34E5C7F3687A2A840CDC07295209" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_B40C3C6915E05CB857560CDC0729F6AC" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsGrantsInPeriodWeightedAverageGrantDateFairValue_594D34E5C7F3687A2A840CDC07295209" 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_CF16A8D671EE82C1947E0CDC0729DD17" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_B40C3C6915E05CB857560CDC0729F6AC" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsVestedInPeriodWeightedAverageGrantDateFairValue_CF16A8D671EE82C1947E0CDC0729DD17" 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_6306132C4760710A12E70CDC072A9533" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsNonvestedWeightedAverageGrantDateFairValueRollForward_B40C3C6915E05CB857560CDC0729F6AC" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardEquityInstrumentsOtherThanOptionsForfeituresWeightedAverageGrantDateFairValue_6306132C4760710A12E70CDC072A9533" 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_C03EACBCCBF83D1BE0FE34B5B5F22476" 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_1B7362135E290D0CC1CE34B5B5F022F4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems_C03EACBCCBF83D1BE0FE34B5B5F22476" xlink:to="loc_us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable_1B7362135E290D0CC1CE34B5B5F022F4" 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_01916EF8128F7121D3D334B5B5F0FA79" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable_1B7362135E290D0CC1CE34B5B5F022F4" xlink:to="loc_us-gaap_IncomeStatementLocationAxis_01916EF8128F7121D3D334B5B5F0FA79" 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_67DB42CDD76778ACBCFE34B5B5F1416F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_01916EF8128F7121D3D334B5B5F0FA79" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F_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_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_IncomeStatementLocationAxis_01916EF8128F7121D3D334B5B5F0FA79" xlink:to="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CostOfOperatingLeasesAndIncentivesMember" xlink:label="loc_run_CostOfOperatingLeasesAndIncentivesMember_099351D0DC78ED89FB9D34B5B5F1EE27" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:to="loc_run_CostOfOperatingLeasesAndIncentivesMember_099351D0DC78ED89FB9D34B5B5F1EE27" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CostOfSolarEnergySystemsAndProductSalesMember" xlink:label="loc_run_CostOfSolarEnergySystemsAndProductSalesMember_22FD0ED7430BA63CFF6A34B5B5F13FF5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:to="loc_run_CostOfSolarEnergySystemsAndProductSalesMember_22FD0ED7430BA63CFF6A34B5B5F13FF5" 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_BCDC9EFB60D92EFBC5BE34B5B5F2A869" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:to="loc_us-gaap_SellingAndMarketingExpenseMember_BCDC9EFB60D92EFBC5BE34B5B5F2A869" 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_18D20B94FF89FB9E275734B5B5F25C8D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:to="loc_us-gaap_ResearchAndDevelopmentExpenseMember_18D20B94FF89FB9E275734B5B5F25C8D" 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_3140E8968A4589786DE734B5B5F21D7F" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_IncomeStatementLocationDomain_67DB42CDD76778ACBCFE34B5B5F1416F" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpenseMember_3140E8968A4589786DE734B5B5F21D7F" 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_52452C4723D1483DE9BA34B5B5F21BAA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems_C03EACBCCBF83D1BE0FE34B5B5F22476" xlink:to="loc_us-gaap_AllocatedShareBasedCompensationExpense_52452C4723D1483DE9BA34B5B5F21BAA" 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/StockholdersEquity" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockholdersEquityAdditionalInformationDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_808D8EC2B3F3BBD2F4761E18658B138F" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_E79454925EBBBEB3803D1E18658B174E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_808D8EC2B3F3BBD2F4761E18658B138F" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_E79454925EBBBEB3803D1E18658B174E" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementClassOfStockAxis" xlink:label="loc_us-gaap_StatementClassOfStockAxis_EAA52EF1E58A318FBCC21E18658B72F4" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_E79454925EBBBEB3803D1E18658B174E" xlink:to="loc_us-gaap_StatementClassOfStockAxis_EAA52EF1E58A318FBCC21E18658B72F4" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BB4DD152B53995DF638A1E18658B80ED_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementClassOfStockAxis_EAA52EF1E58A318FBCC21E18658B72F4" xlink:to="loc_us-gaap_ClassOfStockDomain_BB4DD152B53995DF638A1E18658B80ED_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockDomain" xlink:label="loc_us-gaap_ClassOfStockDomain_BB4DD152B53995DF638A1E18658B80ED" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementClassOfStockAxis_EAA52EF1E58A318FBCC21E18658B72F4" xlink:to="loc_us-gaap_ClassOfStockDomain_BB4DD152B53995DF638A1E18658B80ED" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ConvertiblePreferredStockMember" xlink:label="loc_us-gaap_ConvertiblePreferredStockMember_A49011930D7E6B1F19B61E18658B082B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockDomain_BB4DD152B53995DF638A1E18658B80ED" xlink:to="loc_us-gaap_ConvertiblePreferredStockMember_A49011930D7E6B1F19B61E18658B082B" 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_3DDE1AD6D92FCF0EFD591E18658B6620" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_808D8EC2B3F3BBD2F4761E18658B138F" xlink:to="loc_us-gaap_PreferredStockSharesIssued_3DDE1AD6D92FCF0EFD591E18658B6620" 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_0BDC34A16E68C282033C1E18658B9923" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_808D8EC2B3F3BBD2F4761E18658B138F" xlink:to="loc_us-gaap_PreferredStockSharesOutstanding_0BDC34A16E68C282033C1E18658B9923" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DividendsPreferredStock" xlink:label="loc_us-gaap_DividendsPreferredStock_3BE9DC8DC20D5FED04051E18658BCA1D" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_808D8EC2B3F3BBD2F4761E18658B138F" xlink:to="loc_us-gaap_DividendsPreferredStock_3BE9DC8DC20D5FED04051E18658BCA1D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DividendsCommonStockStock" xlink:label="loc_us-gaap_DividendsCommonStockStock_EB6FC53A4E5B63E177421E18658B3915" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_808D8EC2B3F3BBD2F4761E18658B138F" xlink:to="loc_us-gaap_DividendsCommonStockStock_EB6FC53A4E5B63E177421E18658B3915" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockholdersEquityScheduleOfReserveShareOfCommonStockForIssuanceDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ClassOfStockLineItems" xlink:label="loc_us-gaap_ClassOfStockLineItems_C25B2CD2EA3489B2E3300CDC076404C7" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfStockByClassTable" xlink:label="loc_us-gaap_ScheduleOfStockByClassTable_96F867E0A755CFDED35D0CDC07624475" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_ClassOfStockLineItems_C25B2CD2EA3489B2E3300CDC076404C7" xlink:to="loc_us-gaap_ScheduleOfStockByClassTable_96F867E0A755CFDED35D0CDC07624475" 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_0198EB6E874BD49617E40CDC0762F131" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_96F867E0A755CFDED35D0CDC07624475" xlink:to="loc_us-gaap_PlanNameAxis_0198EB6E874BD49617E40CDC0762F131" 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_05020B9E5304508941B70CDC076207FE_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PlanNameAxis_0198EB6E874BD49617E40CDC0762F131" xlink:to="loc_us-gaap_PlanNameDomain_05020B9E5304508941B70CDC076207FE_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_05020B9E5304508941B70CDC076207FE" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PlanNameAxis_0198EB6E874BD49617E40CDC0762F131" xlink:to="loc_us-gaap_PlanNameDomain_05020B9E5304508941B70CDC076207FE" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TwoThousandFifteenEquityIncentivePlanMember" xlink:label="loc_run_TwoThousandFifteenEquityIncentivePlanMember_A582BFC80CA89C5CF3980CDC0762F236" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_05020B9E5304508941B70CDC076207FE" xlink:to="loc_run_TwoThousandFifteenEquityIncentivePlanMember_A582BFC80CA89C5CF3980CDC0762F236" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_TwentyFifteenEmployeeStockPurchasePlanMember" xlink:label="loc_run_TwentyFifteenEmployeeStockPurchasePlanMember_29AA0795A548BBEC03D90CDC0763816C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PlanNameDomain_05020B9E5304508941B70CDC076207FE" xlink:to="loc_run_TwentyFifteenEmployeeStockPurchasePlanMember_29AA0795A548BBEC03D90CDC0763816C" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AwardTypeAxis" xlink:label="loc_us-gaap_AwardTypeAxis_DEB8D3AAAD2C664981E00CDC0763C944" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfStockByClassTable_96F867E0A755CFDED35D0CDC07624475" xlink:to="loc_us-gaap_AwardTypeAxis_DEB8D3AAAD2C664981E00CDC0763C944" 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_CCAF34F4E372725204180CDC0763CCAC_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AwardTypeAxis_DEB8D3AAAD2C664981E00CDC0763C944" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_CCAF34F4E372725204180CDC0763CCAC_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_CCAF34F4E372725204180CDC0763CCAC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AwardTypeAxis_DEB8D3AAAD2C664981E00CDC0763C944" xlink:to="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_CCAF34F4E372725204180CDC0763CCAC" 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_92E526548FEA5704202F0CDC0763A4CA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_CCAF34F4E372725204180CDC0763CCAC" xlink:to="loc_us-gaap_EmployeeStockOptionMember_92E526548FEA5704202F0CDC0763A4CA" 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_E94FA24BD4DEED5645EA0CDC07641635" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain_CCAF34F4E372725204180CDC0763CCAC" xlink:to="loc_us-gaap_RestrictedStockUnitsRSUMember_E94FA24BD4DEED5645EA0CDC07641635" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CommonStockCapitalSharesReservedForFutureIssuance" xlink:label="loc_us-gaap_CommonStockCapitalSharesReservedForFutureIssuance_8586815DABA372F71A8F0CDC07647321" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassOfStockLineItems_C25B2CD2EA3489B2E3300CDC076404C7" xlink:to="loc_us-gaap_CommonStockCapitalSharesReservedForFutureIssuance_8586815DABA372F71A8F0CDC07647321" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/StockholdersEquityTables" 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/SummaryOfSignificantAccountingPoliciesAccountsReceivableNetDetails" xlink:type="extended" />
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAdditionalInformationDetails" xlink:type="extended">
    <link:loc xlink:href="run-20181231.xsd#run_SummaryOfSignificantAccountingPoliciesLineItems" xlink:label="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:type="locator" />
    <link:loc xlink:href="run-20181231.xsd#run_SummaryOfSignificantAccountingPoliciesTable" xlink:label="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" 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_28C06C42F8C485446B34321C4B958E0F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:to="loc_us-gaap_StatementScenarioAxis_28C06C42F8C485446B34321C4B958E0F" 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_CEF45C68F30DB1212651321C4B95BA18_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_28C06C42F8C485446B34321C4B958E0F" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_CEF45C68F30DB1212651321C4B95BA18_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_CEF45C68F30DB1212651321C4B95BA18" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_28C06C42F8C485446B34321C4B958E0F" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_CEF45C68F30DB1212651321C4B95BA18" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScenarioAdjustmentMember" xlink:label="loc_us-gaap_ScenarioAdjustmentMember_8092227E2B4C328334C0321C4B95742D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_CEF45C68F30DB1212651321C4B95BA18" xlink:to="loc_us-gaap_ScenarioAdjustmentMember_8092227E2B4C328334C0321C4B95742D" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_StatementEquityComponentsAxis" xlink:label="loc_us-gaap_StatementEquityComponentsAxis_BD4E9B2E31AB9E81B7F2321C4B9584EA" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_BD4E9B2E31AB9E81B7F2321C4B9584EA" 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_4743DE9C004825AAE03A321C4B958A08_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_BD4E9B2E31AB9E81B7F2321C4B9584EA" xlink:to="loc_us-gaap_EquityComponentDomain_4743DE9C004825AAE03A321C4B958A08_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_4743DE9C004825AAE03A321C4B958A08" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_BD4E9B2E31AB9E81B7F2321C4B9584EA" xlink:to="loc_us-gaap_EquityComponentDomain_4743DE9C004825AAE03A321C4B958A08" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RetainedEarningsMember" xlink:label="loc_us-gaap_RetainedEarningsMember_C1EDA92C170621EB3CC2321C4B99CC84" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_4743DE9C004825AAE03A321C4B958A08" xlink:to="loc_us-gaap_RetainedEarningsMember_C1EDA92C170621EB3CC2321C4B99CC84" xlink:type="arc" />
    <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_8DADA3FDD3728EBE1A50321C4B990152" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:to="loc_us-gaap_ProductOrServiceAxis_8DADA3FDD3728EBE1A50321C4B990152" 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_4E9B8F8DAA2AA0F0DAD9321C4B9948A8_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_8DADA3FDD3728EBE1A50321C4B990152" xlink:to="loc_us-gaap_ProductsAndServicesDomain_4E9B8F8DAA2AA0F0DAD9321C4B9948A8_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_4E9B8F8DAA2AA0F0DAD9321C4B9948A8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_8DADA3FDD3728EBE1A50321C4B990152" xlink:to="loc_us-gaap_ProductsAndServicesDomain_4E9B8F8DAA2AA0F0DAD9321C4B9948A8" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SolarEnergySystemsMember" xlink:label="loc_run_SolarEnergySystemsMember_565DC3BA26BFA3D3AA65321C4B990E21" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_4E9B8F8DAA2AA0F0DAD9321C4B9948A8" xlink:to="loc_run_SolarEnergySystemsMember_565DC3BA26BFA3D3AA65321C4B990E21" xlink:type="arc" />
    <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_ED4492B4A6D4D6357D2C321C4B997824" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_ED4492B4A6D4D6357D2C321C4B997824" 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_878F3979CA90993E92C2321C4B99B7B7_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_ED4492B4A6D4D6357D2C321C4B997824" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_878F3979CA90993E92C2321C4B99B7B7_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_878F3979CA90993E92C2321C4B99B7B7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_ED4492B4A6D4D6357D2C321C4B997824" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_878F3979CA90993E92C2321C4B99B7B7" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InvertersMember" xlink:label="loc_run_InvertersMember_1BDE906B52EAADE70DF8321C4B998EB3" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_878F3979CA90993E92C2321C4B99B7B7" xlink:to="loc_run_InvertersMember_1BDE906B52EAADE70DF8321C4B998EB3" 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_95AB65EA0E01BE37AE52321C4B993EF1" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:to="loc_us-gaap_RangeAxis_95AB65EA0E01BE37AE52321C4B993EF1" 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_C620F1B6CFC24B02CB26321C4B99634B_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_95AB65EA0E01BE37AE52321C4B993EF1" xlink:to="loc_us-gaap_RangeMember_C620F1B6CFC24B02CB26321C4B99634B_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_C620F1B6CFC24B02CB26321C4B99634B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_95AB65EA0E01BE37AE52321C4B993EF1" xlink:to="loc_us-gaap_RangeMember_C620F1B6CFC24B02CB26321C4B99634B" 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_AD72B7923CBBFEEC4F07321C4B995875" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_C620F1B6CFC24B02CB26321C4B99634B" xlink:to="loc_us-gaap_MinimumMember_AD72B7923CBBFEEC4F07321C4B995875" 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_BD547D8E7DF54B389729325AF7A82D81" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_C620F1B6CFC24B02CB26321C4B99634B" xlink:to="loc_us-gaap_MaximumMember_BD547D8E7DF54B389729325AF7A82D81" 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_612D168EA92DD1829697321C4B99C6FE" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesTable_00CF94F99DC261701927321C4B95A3A6" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_612D168EA92DD1829697321C4B99C6FE" 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_9768E9BEC98B129B062E321C4B995627_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_612D168EA92DD1829697321C4B99C6FE" xlink:to="loc_us-gaap_TypeOfAdoptionMember_9768E9BEC98B129B062E321C4B995627_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_9768E9BEC98B129B062E321C4B995627" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_612D168EA92DD1829697321C4B99C6FE" xlink:to="loc_us-gaap_TypeOfAdoptionMember_9768E9BEC98B129B062E321C4B995627" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountingStandardsUpdate201616Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201616Member_2BCD33FBC244045CC8CD321C4B99540A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_9768E9BEC98B129B062E321C4B995627" xlink:to="loc_us-gaap_AccountingStandardsUpdate201616Member_2BCD33FBC244045CC8CD321C4B99540A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AccountingStandardsUpdate201609Member" xlink:label="loc_us-gaap_AccountingStandardsUpdate201609Member_1B9DE64F1370AB305DB4321C4B99E211" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_9768E9BEC98B129B062E321C4B995627" xlink:to="loc_us-gaap_AccountingStandardsUpdate201609Member_1B9DE64F1370AB305DB4321C4B99E211" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_NumberOfOperatingSegments" xlink:label="loc_us-gaap_NumberOfOperatingSegments_08722564D406091EBD91321C4B99B0EF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_NumberOfOperatingSegments_08722564D406091EBD91321C4B99B0EF" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_NumberOfBusinessActivities" xlink:label="loc_run_NumberOfBusinessActivities_D465178C7B12ACC81EE2321C4B99D280" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_run_NumberOfBusinessActivities_D465178C7B12ACC81EE2321C4B99D280" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProvisionForDoubtfulAccounts" xlink:label="loc_us-gaap_ProvisionForDoubtfulAccounts_168323EE9757627F22DD321C4B9959B1" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_ProvisionForDoubtfulAccounts_168323EE9757627F22DD321C4B9959B1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AllowanceForDoubtfulAccountsReceivableWriteOffs" xlink:label="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableWriteOffs_67D2C5BA5A7A85CA7221321C4B9DF4B3" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_AllowanceForDoubtfulAccountsReceivableWriteOffs_67D2C5BA5A7A85CA7221321C4B9DF4B3" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PublicUtilitiesPropertyPlantAndEquipmentEquipmentUsefulLife" xlink:label="loc_us-gaap_PublicUtilitiesPropertyPlantAndEquipmentEquipmentUsefulLife_345798403F7AD5AC9139321C4B9DD42E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_PublicUtilitiesPropertyPlantAndEquipmentEquipmentUsefulLife_345798403F7AD5AC9139321C4B9DD42E" 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_3A174C8446452CF832AF325A62F03A66" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract_3A174C8446452CF832AF325A62F03A66" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CustomerAgreementsInitialSetUpDiscountPercent" xlink:label="loc_run_CustomerAgreementsInitialSetUpDiscountPercent_63BE4A39919D23633C57325CDCB2F91E" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_run_CustomerAgreementsInitialSetUpDiscountPercent_63BE4A39919D23633C57325CDCB2F91E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CapitalizedAdditionalCostsAssociatedWithSoftware" xlink:label="loc_run_CapitalizedAdditionalCostsAssociatedWithSoftware_770FFF865FF53529E3C4321C4B9D6CE0" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_run_CapitalizedAdditionalCostsAssociatedWithSoftware_770FFF865FF53529E3C4321C4B9D6CE0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PrepaidTaxes" xlink:label="loc_us-gaap_PrepaidTaxes_EF666941F863CA213DB2321C4B9D4668" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_PrepaidTaxes_EF666941F863CA213DB2321C4B9D4668" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredTaxAssetsGross" xlink:label="loc_us-gaap_DeferredTaxAssetsGross_4DBE89457C0F65F400DE321C4B9D7D51" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_DeferredTaxAssetsGross_4DBE89457C0F65F400DE321C4B9D7D51" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption" xlink:label="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_E4442AA5DBEE2DD212FE321C4B9D1D98" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_us-gaap_CumulativeEffectOfNewAccountingPrincipleInPeriodOfAdoption_E4442AA5DBEE2DD212FE321C4B9D1D98" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_InventoriesAcquired" xlink:label="loc_run_InventoriesAcquired_F5E3258EC4A603AE92C1321C4B9D2669" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_SummaryOfSignificantAccountingPoliciesLineItems_503641B207DCA79C728E321C4B999232" xlink:to="loc_run_InventoriesAcquired_F5E3258EC4A603AE92C1321C4B9D2669" xlink:type="arc" />
  </link:definitionLink>
  <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_641A32FA45C328014B830CDC085071BE" 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_82A4F2427C308BCEA9EB0CDC084E16AD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_82A4F2427C308BCEA9EB0CDC084E16AD" 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_5F2483357C5722C8A7280CDC084FDBFD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_82A4F2427C308BCEA9EB0CDC084E16AD" xlink:to="loc_us-gaap_StatementScenarioAxis_5F2483357C5722C8A7280CDC084FDBFD" 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_C7F16F27FF3C882BF6450CDC084F22DF_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_5F2483357C5722C8A7280CDC084FDBFD" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_C7F16F27FF3C882BF6450CDC084F22DF_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_C7F16F27FF3C882BF6450CDC084F22DF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_5F2483357C5722C8A7280CDC084FDBFD" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_C7F16F27FF3C882BF6450CDC084F22DF" 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_AA4D91E574E10E6869F10CDC084F9250" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_C7F16F27FF3C882BF6450CDC084F22DF" xlink:to="loc_us-gaap_ScenarioPreviouslyReportedMember_AA4D91E574E10E6869F10CDC084F9250" 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_9768CC36AD9CB5ED26170CDC08507925" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_C7F16F27FF3C882BF6450CDC084F22DF" xlink:to="loc_us-gaap_RestatementAdjustmentMember_9768CC36AD9CB5ED26170CDC08507925" 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_7B18E2372BE1335883400CDC08509FE1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_82A4F2427C308BCEA9EB0CDC084E16AD" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7B18E2372BE1335883400CDC08509FE1" 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_EA53D1DEF3F6547B13620CDC0850196E_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7B18E2372BE1335883400CDC08509FE1" xlink:to="loc_us-gaap_TypeOfAdoptionMember_EA53D1DEF3F6547B13620CDC0850196E_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_EA53D1DEF3F6547B13620CDC0850196E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_7B18E2372BE1335883400CDC08509FE1" xlink:to="loc_us-gaap_TypeOfAdoptionMember_EA53D1DEF3F6547B13620CDC0850196E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member" xlink:label="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_CE2DE1EA2926843126700CDC08508310" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_EA53D1DEF3F6547B13620CDC0850196E" xlink:to="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_CE2DE1EA2926843126700CDC08508310" 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_31B3E3F5171D035E23A10CDC0851FDEA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_31B3E3F5171D035E23A10CDC0851FDEA" 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_821011F6DD46F9975BF20CDC0851C2B1" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_821011F6DD46F9975BF20CDC0851C2B1" 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_D22764FD01BD916A62A50CDC08514166" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_D22764FD01BD916A62A50CDC08514166" 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_D942BF31726215F67E720CDC085141E7" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_D942BF31726215F67E720CDC085141E7" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiabilityCurrent" xlink:label="loc_us-gaap_ContractWithCustomerLiabilityCurrent_66D6B25A9A4EC05AE5D10CDC085151C1" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_ContractWithCustomerLiabilityCurrent_66D6B25A9A4EC05AE5D10CDC085151C1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredGrantCurrentPortion" xlink:label="loc_run_DeferredGrantCurrentPortion_CAD3870F7D8ABA2C89F40CDC08519E48" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_run_DeferredGrantCurrentPortion_CAD3870F7D8ABA2C89F40CDC08519E48" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_LeasePassThroughFinancingObligationCurrentPortion" xlink:label="loc_run_LeasePassThroughFinancingObligationCurrentPortion_F46B817FF51AC58109B50CDC0852F7D1" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_run_LeasePassThroughFinancingObligationCurrentPortion_F46B817FF51AC58109B50CDC0852F7D1" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiabilityNoncurrent" xlink:label="loc_us-gaap_ContractWithCustomerLiabilityNoncurrent_0DE59C1459405199AAE00CDC085231E1" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_ContractWithCustomerLiabilityNoncurrent_0DE59C1459405199AAE00CDC085231E1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredGrantIncomeNoncurrent" xlink:label="loc_run_DeferredGrantIncomeNoncurrent_8CF10D857054BE9CAF680CDC08521247" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_run_DeferredGrantIncomeNoncurrent_8CF10D857054BE9CAF680CDC08521247" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_LeasePassThroughFinancingObligationNetOfCurrentPortion" xlink:label="loc_run_LeasePassThroughFinancingObligationNetOfCurrentPortion_7ECDAA0B5EE181EDE2160CDC0852A50F" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_run_LeasePassThroughFinancingObligationNetOfCurrentPortion_7ECDAA0B5EE181EDE2160CDC0852A50F" 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_026693A2E4F46B20E9DE0CDC0852A7F0" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_026693A2E4F46B20E9DE0CDC0852A7F0" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DeferredIncomeTaxLiabilitiesNet" xlink:label="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_2F7B4B611F880648C7370CDC0852EBE1" xlink:type="locator" />
    <link:definitionArc order="12" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_2F7B4B611F880648C7370CDC0852EBE1" 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_373ED59F23DBD6E97A3A0CDC08532821" xlink:type="locator" />
    <link:definitionArc order="13" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_RedeemableNoncontrollingInterestEquityCarryingAmount_373ED59F23DBD6E97A3A0CDC08532821" 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_723C26BA72CC7C272A890CDC08531E20" xlink:type="locator" />
    <link:definitionArc order="14" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_AdditionalPaidInCapital_723C26BA72CC7C272A890CDC08531E20" 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_9AF7B4165F31AF1E67990CDC085348FC" xlink:type="locator" />
    <link:definitionArc order="15" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_9AF7B4165F31AF1E67990CDC085348FC" 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_6DB641530A664071519D0CDC08539534" xlink:type="locator" />
    <link:definitionArc order="16" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_641A32FA45C328014B830CDC085071BE" xlink:to="loc_us-gaap_MinorityInterest_6DB641530A664071519D0CDC08539534" 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_D552B38A7780ABBDBFB50CDC0841D8D4" 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_73416D2BE51D25A8F4140CDC083FEF63" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_73416D2BE51D25A8F4140CDC083FEF63" 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_C377C5768C2306E629550CDC083FD04F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_73416D2BE51D25A8F4140CDC083FEF63" xlink:to="loc_us-gaap_StatementScenarioAxis_C377C5768C2306E629550CDC083FD04F" 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_ADA3298FE0865CFE3DE90CDC083F9D42_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_C377C5768C2306E629550CDC083FD04F" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_ADA3298FE0865CFE3DE90CDC083F9D42_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_ADA3298FE0865CFE3DE90CDC083F9D42" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_C377C5768C2306E629550CDC083FD04F" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_ADA3298FE0865CFE3DE90CDC083F9D42" 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_2A63CAA8F4FA5DBC46150CDC083FFAFF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_ADA3298FE0865CFE3DE90CDC083F9D42" xlink:to="loc_us-gaap_ScenarioPreviouslyReportedMember_2A63CAA8F4FA5DBC46150CDC083FFAFF" 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_1E88DAC6F701A3562D310CDC0840448D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_ADA3298FE0865CFE3DE90CDC083F9D42" xlink:to="loc_us-gaap_RestatementAdjustmentMember_1E88DAC6F701A3562D310CDC0840448D" 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_DE8B08579AE3D84B442E0CDC08406018" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_73416D2BE51D25A8F4140CDC083FEF63" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_DE8B08579AE3D84B442E0CDC08406018" 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_FD22C25059C694E846770CDC0840A928_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_DE8B08579AE3D84B442E0CDC08406018" xlink:to="loc_us-gaap_TypeOfAdoptionMember_FD22C25059C694E846770CDC0840A928_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_FD22C25059C694E846770CDC0840A928" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_DE8B08579AE3D84B442E0CDC08406018" xlink:to="loc_us-gaap_TypeOfAdoptionMember_FD22C25059C694E846770CDC0840A928" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AccountingStandardsUpdate201409AccountingStandardsUpdate201602AccountingStandardsUpdate201618Member" xlink:label="loc_run_AccountingStandardsUpdate201409AccountingStandardsUpdate201602AccountingStandardsUpdate201618Member_636327D99EB6952160B10CDC0840C369" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_FD22C25059C694E846770CDC0840A928" xlink:to="loc_run_AccountingStandardsUpdate201409AccountingStandardsUpdate201602AccountingStandardsUpdate201618Member_636327D99EB6952160B10CDC0840C369" 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_A80CEFE17D49D6B6E5C30CDC08410BCA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_ProfitLoss_A80CEFE17D49D6B6E5C30CDC08410BCA" 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_1B35726268F9FDD835400CDC0841DA1E" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivitiesContinuingOperations_1B35726268F9FDD835400CDC0841DA1E" 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_0411C1824251FF5F4C3A0CDC0841ED8E" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivitiesContinuingOperations_0411C1824251FF5F4C3A0CDC0841ED8E" 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_4D897072B34B15734CEA0CDC0841ADEF" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivitiesContinuingOperations_4D897072B34B15734CEA0CDC0841ADEF" 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_477592AA71CF4E4A29DC0CDC08423AEA" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_477592AA71CF4E4A29DC0CDC08423AEA" 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_93A5C7B74E60B2C84F8B0CDC08423EC4" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_D552B38A7780ABBDBFB50CDC0841D8D4" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_93A5C7B74E60B2C84F8B0CDC08423EC4" 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_C0FA124410147517E6B43581C44FB818" 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_DE0D268DFF4C46E1EC2C3581C44C8BFD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_DE0D268DFF4C46E1EC2C3581C44C8BFD" 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_CFD6FD93E1E9B30DA0F13581C44C5BE1" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_DE0D268DFF4C46E1EC2C3581C44C8BFD" xlink:to="loc_us-gaap_StatementScenarioAxis_CFD6FD93E1E9B30DA0F13581C44C5BE1" 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_DCB9E38543EE36F374CD3581C44CB573_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementScenarioAxis_CFD6FD93E1E9B30DA0F13581C44C5BE1" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_DCB9E38543EE36F374CD3581C44CB573_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_DCB9E38543EE36F374CD3581C44CB573" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementScenarioAxis_CFD6FD93E1E9B30DA0F13581C44C5BE1" xlink:to="loc_us-gaap_ScenarioUnspecifiedDomain_DCB9E38543EE36F374CD3581C44CB573" 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_7C0818979DEBD9D9CF623581C44DF5E7" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_DCB9E38543EE36F374CD3581C44CB573" xlink:to="loc_us-gaap_ScenarioPreviouslyReportedMember_7C0818979DEBD9D9CF623581C44DF5E7" 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_3B13A59C59DE1EC2C8F53581C44D9FC2" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ScenarioUnspecifiedDomain_DCB9E38543EE36F374CD3581C44CB573" xlink:to="loc_us-gaap_RestatementAdjustmentMember_3B13A59C59DE1EC2C8F53581C44D9FC2" 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_4817D0496FDBAD63542C3581C44D5556" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_DE0D268DFF4C46E1EC2C3581C44C8BFD" xlink:to="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_4817D0496FDBAD63542C3581C44D5556" 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_402C966423924FC482093581C44DA403_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_4817D0496FDBAD63542C3581C44D5556" xlink:to="loc_us-gaap_TypeOfAdoptionMember_402C966423924FC482093581C44DA403_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_402C966423924FC482093581C44DA403" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_AdjustmentsForNewAccountingPronouncementsAxis_4817D0496FDBAD63542C3581C44D5556" xlink:to="loc_us-gaap_TypeOfAdoptionMember_402C966423924FC482093581C44DA403" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member" xlink:label="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_B3CA09A015F7C68F65E53581C44E4325" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_TypeOfAdoptionMember_402C966423924FC482093581C44DA403" xlink:to="loc_run_AccountingStandardsUpdate201409andAccountingStandardsUpdate201602Member_B3CA09A015F7C68F65E53581C44E4325" xlink:type="arc" />
    <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_6CF8666E9F801A52AC243581C44E7CDB" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable_DE0D268DFF4C46E1EC2C3581C44C8BFD" xlink:to="loc_us-gaap_ProductOrServiceAxis_6CF8666E9F801A52AC243581C44E7CDB" 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_81538ABC219BA690D5393581C44EC121_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_6CF8666E9F801A52AC243581C44E7CDB" xlink:to="loc_us-gaap_ProductsAndServicesDomain_81538ABC219BA690D5393581C44EC121_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_81538ABC219BA690D5393581C44EC121" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_6CF8666E9F801A52AC243581C44E7CDB" xlink:to="loc_us-gaap_ProductsAndServicesDomain_81538ABC219BA690D5393581C44EC121" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ServiceMember" xlink:label="loc_run_ServiceMember_7CA3D99B413494B849D73581C44E9400" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_81538ABC219BA690D5393581C44EC121" xlink:to="loc_run_ServiceMember_7CA3D99B413494B849D73581C44E9400" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_399B4028B82B9C1378C63581C44F9504" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_399B4028B82B9C1378C63581C44F9504" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CostOfRevenueForOperatingLeasesAndIncentives" xlink:label="loc_run_CostOfRevenueForOperatingLeasesAndIncentives_CAB7C9B2E3CBDC4EA2543581C44F7797" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_run_CostOfRevenueForOperatingLeasesAndIncentives_CAB7C9B2E3CBDC4EA2543581C44F7797" 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_893E02ACF700768A77F53581C44F5B14" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_SellingAndMarketingExpense_893E02ACF700768A77F53581C44F5B14" 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_1BF234D505BCAF770B4E3581C44FE2DE" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_1BF234D505BCAF770B4E3581C44FE2DE" 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_8CFCA17F952A47911B543581C4507ABD" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_InterestIncomeExpenseNonoperatingNet_8CFCA17F952A47911B543581C4507ABD" 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_09531D6A2E317C1D24C63581C4505EED" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_09531D6A2E317C1D24C63581C4505EED" 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_5B8BFCAA037D09289A4F3581C450DBD4" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_ProfitLoss_5B8BFCAA037D09289A4F3581C450DBD4" 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_8980D99662D2E763FAF43581C45052A5" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_NetIncomeLossAttributableToNoncontrollingInterest_8980D99662D2E763FAF43581C45052A5" 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_412FE657B37E4F0CCF003581C450B75A" xlink:type="locator" />
    <link:definitionArc order="9" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_NetIncomeLoss_412FE657B37E4F0CCF003581C450B75A" 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_8A324E2C2FF7C3AE71313581C4501A71" xlink:type="locator" />
    <link:definitionArc order="10" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_EarningsPerShareBasic_8A324E2C2FF7C3AE71313581C4501A71" 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_A6B37DA781555441AA5E3581C451D174" xlink:type="locator" />
    <link:definitionArc order="11" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems_C0FA124410147517E6B43581C44FB818" xlink:to="loc_us-gaap_EarningsPerShareDiluted_A6B37DA781555441AA5E3581C451D174" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesAmortizedFiniteLivedIntangibleAssetsEstimatedUsefulLivesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsLineItems" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8220AA646981427D4ED70CDC0860890A" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable" xlink:label="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_FB9E24A482BF9CB781620CDC085EC89D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8220AA646981427D4ED70CDC0860890A" xlink:to="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_FB9E24A482BF9CB781620CDC085EC89D" xlink:type="arc" xbrldt:closed="true" xbrldt:contextElement="segment" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_002BA46555F087659F100CDC085E0B51" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_FB9E24A482BF9CB781620CDC085EC89D" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_002BA46555F087659F100CDC085E0B51" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_002BA46555F087659F100CDC085E0B51" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A_default" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis_002BA46555F087659F100CDC085E0B51" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_CustomerRelationshipsMember" xlink:label="loc_us-gaap_CustomerRelationshipsMember_D5F1CAD3AC87747A06BC0CDC085F0FCA" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A" xlink:to="loc_us-gaap_CustomerRelationshipsMember_D5F1CAD3AC87747A06BC0CDC085F0FCA" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_DevelopedTechnologyRightsMember" xlink:label="loc_us-gaap_DevelopedTechnologyRightsMember_38F8A852EBE614DD0EBD0CDC085F10F5" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A" xlink:to="loc_us-gaap_DevelopedTechnologyRightsMember_38F8A852EBE614DD0EBD0CDC085F10F5" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_TradeNamesMember" xlink:label="loc_us-gaap_TradeNamesMember_C34AE786726D20BD1D9E0CDC085F3F5F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsMajorClassNameDomain_687C5C4E0FFC728758DF0CDC085FEE4A" xlink:to="loc_us-gaap_TradeNamesMember_C34AE786726D20BD1D9E0CDC085F3F5F" 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_13C83CE90E295621D1E60CDC0860D44A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfFiniteLivedIntangibleAssetsTable_FB9E24A482BF9CB781620CDC085EC89D" xlink:to="loc_us-gaap_RangeAxis_13C83CE90E295621D1E60CDC0860D44A" 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_FCA1B92AF1DD7D0FAF360CDC0860EB04_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_13C83CE90E295621D1E60CDC0860D44A" xlink:to="loc_us-gaap_RangeMember_FCA1B92AF1DD7D0FAF360CDC0860EB04_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_FCA1B92AF1DD7D0FAF360CDC0860EB04" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_13C83CE90E295621D1E60CDC0860D44A" xlink:to="loc_us-gaap_RangeMember_FCA1B92AF1DD7D0FAF360CDC0860EB04" 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_1EE872323D6A86B027E90CDC08608AB8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_FCA1B92AF1DD7D0FAF360CDC0860EB04" xlink:to="loc_us-gaap_MinimumMember_1EE872323D6A86B027E90CDC08608AB8" 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_9B9844A6269759BEA41B0CDC08601E13" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_FCA1B92AF1DD7D0FAF360CDC0860EB04" xlink:to="loc_us-gaap_MaximumMember_9B9844A6269759BEA41B0CDC08601E13" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FiniteLivedIntangibleAssetUsefulLife" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_1BF742B85343118D9A5A0CDC0861FA9C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsLineItems_8220AA646981427D4ED70CDC0860890A" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetUsefulLife_1BF742B85343118D9A5A0CDC0861FA9C" 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_1D0D7F168115371C85BB30CE72B2AE98" 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_3CE86B31F5F50E1B71CE30CE72B0865E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_us-gaap_DeferredRevenueArrangementByTypeTable_3CE86B31F5F50E1B71CE30CE72B0865E" 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_7E95C61F1B2C6907B04B30CE72B07EDC" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DeferredRevenueArrangementByTypeTable_3CE86B31F5F50E1B71CE30CE72B0865E" xlink:to="loc_us-gaap_DeferredRevenueArrangementTypeAxis_7E95C61F1B2C6907B04B30CE72B07EDC" 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_4D45B9DBA49D8E33C09430CE72B0A363_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeAxis_7E95C61F1B2C6907B04B30CE72B07EDC" xlink:to="loc_us-gaap_DeferredRevenueArrangementTypeDomain_4D45B9DBA49D8E33C09430CE72B0A363_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_4D45B9DBA49D8E33C09430CE72B0A363" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeAxis_7E95C61F1B2C6907B04B30CE72B07EDC" xlink:to="loc_us-gaap_DeferredRevenueArrangementTypeDomain_4D45B9DBA49D8E33C09430CE72B0A363" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PaymentsUnderCustomerAgreementsMember" xlink:label="loc_run_PaymentsUnderCustomerAgreementsMember_4B43FF71EA6F904D945430CE72B04BB8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeDomain_4D45B9DBA49D8E33C09430CE72B0A363" xlink:to="loc_run_PaymentsUnderCustomerAgreementsMember_4B43FF71EA6F904D945430CE72B04BB8" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SRECContractsMember" xlink:label="loc_run_SRECContractsMember_F1F2B226EE39C882A57730CE72B11B36" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementTypeDomain_4D45B9DBA49D8E33C09430CE72B0A363" xlink:to="loc_run_SRECContractsMember_F1F2B226EE39C882A57730CE72B11B36" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredRevenueStatusAxis" xlink:label="loc_run_DeferredRevenueStatusAxis_A7B2BE61B83A2C376AC530CE72B143E3" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DeferredRevenueArrangementByTypeTable_3CE86B31F5F50E1B71CE30CE72B0865E" xlink:to="loc_run_DeferredRevenueStatusAxis_A7B2BE61B83A2C376AC530CE72B143E3" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredRevenueStatusDomain" xlink:label="loc_run_DeferredRevenueStatusDomain_2EAF4AFE35CC7900744430CE72B1792F_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_run_DeferredRevenueStatusAxis_A7B2BE61B83A2C376AC530CE72B143E3" xlink:to="loc_run_DeferredRevenueStatusDomain_2EAF4AFE35CC7900744430CE72B1792F_default" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredRevenueStatusDomain" xlink:label="loc_run_DeferredRevenueStatusDomain_2EAF4AFE35CC7900744430CE72B1792F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_run_DeferredRevenueStatusAxis_A7B2BE61B83A2C376AC530CE72B143E3" xlink:to="loc_run_DeferredRevenueStatusDomain_2EAF4AFE35CC7900744430CE72B1792F" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PaymentsReceivedMember" xlink:label="loc_run_PaymentsReceivedMember_BFE412ECF8693D027BCD30CE72B189E5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_DeferredRevenueStatusDomain_2EAF4AFE35CC7900744430CE72B1792F" xlink:to="loc_run_PaymentsReceivedMember_BFE412ECF8693D027BCD30CE72B189E5" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_FinancingMember" xlink:label="loc_run_FinancingMember_2821CFAE9C3821D39D1B30CE72B15C30" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_DeferredRevenueStatusDomain_2EAF4AFE35CC7900744430CE72B1792F" xlink:to="loc_run_FinancingMember_2821CFAE9C3821D39D1B30CE72B15C30" 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_12D6F0A252E45672D8BF30CE72B2CA4B" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DeferredRevenueArrangementByTypeTable_3CE86B31F5F50E1B71CE30CE72B0865E" xlink:to="loc_us-gaap_RangeAxis_12D6F0A252E45672D8BF30CE72B2CA4B" 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_9478912002F06B85CA8A30CE72B2D714_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_RangeAxis_12D6F0A252E45672D8BF30CE72B2CA4B" xlink:to="loc_us-gaap_RangeMember_9478912002F06B85CA8A30CE72B2D714_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_9478912002F06B85CA8A30CE72B2D714" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_RangeAxis_12D6F0A252E45672D8BF30CE72B2CA4B" xlink:to="loc_us-gaap_RangeMember_9478912002F06B85CA8A30CE72B2D714" 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_94DAA5F83BDD57C8357330CE72B26785" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_9478912002F06B85CA8A30CE72B2D714" xlink:to="loc_us-gaap_MinimumMember_94DAA5F83BDD57C8357330CE72B26785" 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_123810CB8E4300D91E1330CE72B2998C" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_RangeMember_9478912002F06B85CA8A30CE72B2D714" xlink:to="loc_us-gaap_MaximumMember_123810CB8E4300D91E1330CE72B2998C" xlink:type="arc" />
    <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_2ED5ACAADBCBDEB82FD031342AA2F84D" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_DeferredRevenueArrangementByTypeTable_3CE86B31F5F50E1B71CE30CE72B0865E" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_2ED5ACAADBCBDEB82FD031342AA2F84D" 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_91FB2BA05CBEAA31766B31342AA37765_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_2ED5ACAADBCBDEB82FD031342AA2F84D" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_91FB2BA05CBEAA31766B31342AA37765_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_91FB2BA05CBEAA31766B31342AA37765" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_2ED5ACAADBCBDEB82FD031342AA2F84D" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_91FB2BA05CBEAA31766B31342AA37765" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ResidentialSolarSystemsMember" xlink:label="loc_run_ResidentialSolarSystemsMember_CCB43125190BCE4E062431352757D797" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_91FB2BA05CBEAA31766B31342AA37765" xlink:to="loc_run_ResidentialSolarSystemsMember_CCB43125190BCE4E062431352757D797" 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_18010E679D963816DF6530CE72B3692A" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_us-gaap_LessorLeasingArrangementsOperatingLeasesTermOfContract_18010E679D963816DF6530CE72B3692A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiability" xlink:label="loc_us-gaap_ContractWithCustomerLiability_76BDC143FF9547F9097430CE72B3AD91" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_us-gaap_ContractWithCustomerLiability_76BDC143FF9547F9097430CE72B3AD91" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiabilityRevenueRecognized" xlink:label="loc_us-gaap_ContractWithCustomerLiabilityRevenueRecognized_D65AE5AFECA512D952E130CE72B3E944" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_us-gaap_ContractWithCustomerLiabilityRevenueRecognized_D65AE5AFECA512D952E130CE72B3E944" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ContractwithCustomerAmountNotYetRecognized" xlink:label="loc_run_ContractwithCustomerAmountNotYetRecognized_5FACB216E0BF7F4519AB30CE72B3ED7B" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_run_ContractwithCustomerAmountNotYetRecognized_5FACB216E0BF7F4519AB30CE72B3ED7B" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ContractWithCustomerRevenueExpectedtoRecognizeOverNextTwelveMonthsPercent" xlink:label="loc_run_ContractWithCustomerRevenueExpectedtoRecognizeOverNextTwelveMonthsPercent_B60A09B69FA304EEDF4F30CE72B3707A" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_run_ContractWithCustomerRevenueExpectedtoRecognizeOverNextTwelveMonthsPercent_B60A09B69FA304EEDF4F30CE72B3707A" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_RevenueRemainingPerformanceObligationExpectedTimingofSatisfactionPeriodPrior" xlink:label="loc_run_RevenueRemainingPerformanceObligationExpectedTimingofSatisfactionPeriodPrior_5685131D86BAECD715BB30CE72B3FF00" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_run_RevenueRemainingPerformanceObligationExpectedTimingofSatisfactionPeriodPrior_5685131D86BAECD715BB30CE72B3FF00" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_PropertyPlantandEquipmentAverageAge" xlink:label="loc_run_PropertyPlantandEquipmentAverageAge_F60E63D73E77DBADE91731360474CFC6" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_run_PropertyPlantandEquipmentAverageAge_F60E63D73E77DBADE91731360474CFC6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionPeriod" xlink:label="loc_us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionPeriod_E1817AB0B80B57CD35A530CE72B4C33D" xlink:type="locator" />
    <link:definitionArc order="8" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_DeferredRevenueArrangementLineItems_1D0D7F168115371C85BB30CE72B2AE98" xlink:to="loc_us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionPeriod_E1817AB0B80B57CD35A530CE72B4C33D" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/SummaryOfSignificantAccountingPoliciesDepreciatedPropertyAndEquipmentNetEstimatedUsefulLivesDetails" xlink:type="extended">
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentLineItems" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentLineItems_FF257DE815D1A916631F30CE72BF38F2" xlink:type="locator" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ScheduleOfPropertyPlantAndEquipmentTable" xlink:label="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_19F138086DD8B355216330CE72BE5247" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_FF257DE815D1A916631F30CE72BF38F2" xlink:to="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_19F138086DD8B355216330CE72BE5247" 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_E2FA33AF33884CA51FF430CE72BE2D96" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfPropertyPlantAndEquipmentTable_19F138086DD8B355216330CE72BE5247" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_E2FA33AF33884CA51FF430CE72BE2D96" 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_FC6B5AB53E02FEC6568A30CE72BE2D17_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_E2FA33AF33884CA51FF430CE72BE2D96" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_FC6B5AB53E02FEC6568A30CE72BE2D17_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_FC6B5AB53E02FEC6568A30CE72BE2D17" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentByTypeAxis_E2FA33AF33884CA51FF430CE72BE2D96" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_FC6B5AB53E02FEC6568A30CE72BE2D17" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_LeaseholdImprovementsMember" xlink:label="loc_us-gaap_LeaseholdImprovementsMember_E3360ED67CF10E3AF18630CE72BF8E87" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_FC6B5AB53E02FEC6568A30CE72BE2D17" xlink:to="loc_us-gaap_LeaseholdImprovementsMember_E3360ED67CF10E3AF18630CE72BF8E87" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_FurnitureAndFixturesMember" xlink:label="loc_us-gaap_FurnitureAndFixturesMember_67611B062E8A79742B0030CE72BFB534" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_FC6B5AB53E02FEC6568A30CE72BE2D17" xlink:to="loc_us-gaap_FurnitureAndFixturesMember_67611B062E8A79742B0030CE72BFB534" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ComputerHardwareAndSoftwareMember" xlink:label="loc_run_ComputerHardwareAndSoftwareMember_4820A7B357C0A768BA6430CE72BFB460" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_FC6B5AB53E02FEC6568A30CE72BE2D17" xlink:to="loc_run_ComputerHardwareAndSoftwareMember_4820A7B357C0A768BA6430CE72BFB460" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_MachineryAndEquipmentMember" xlink:label="loc_us-gaap_MachineryAndEquipmentMember_BDDC48590947EB85904B30CE72BFE0FC" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentTypeDomain_FC6B5AB53E02FEC6568A30CE72BE2D17" xlink:to="loc_us-gaap_MachineryAndEquipmentMember_BDDC48590947EB85904B30CE72BFE0FC" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_PropertyPlantAndEquipmentUsefulLife" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_01C79BD5EA07CD8EC95530CE72C0AA39" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentLineItems_FF257DE815D1A916631F30CE72BF38F2" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentUsefulLife_01C79BD5EA07CD8EC95530CE72C0AA39" 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_8189A2A6D65711C186233581C4BBE904" 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_E50D11D467A5BEA788CA3581C4B92154" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_8189A2A6D65711C186233581C4BBE904" xlink:to="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_E50D11D467A5BEA788CA3581C4B92154" 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_2552A11EA264463AE5CD3581C4B93E7D" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfEntityWideRevenueByMajorCustomersByReportingSegmentsTable_E50D11D467A5BEA788CA3581C4B92154" xlink:to="loc_us-gaap_ProductOrServiceAxis_2552A11EA264463AE5CD3581C4B93E7D" 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_26B75443E73191E83FE73581C4B999A6_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_ProductOrServiceAxis_2552A11EA264463AE5CD3581C4B93E7D" xlink:to="loc_us-gaap_ProductsAndServicesDomain_26B75443E73191E83FE73581C4B999A6_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_26B75443E73191E83FE73581C4B999A6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_ProductOrServiceAxis_2552A11EA264463AE5CD3581C4B93E7D" xlink:to="loc_us-gaap_ProductsAndServicesDomain_26B75443E73191E83FE73581C4B999A6" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ServiceMember" xlink:label="loc_run_ServiceMember_9B106FB3F2A15B154A4E3581C4BA7FCF" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_26B75443E73191E83FE73581C4B999A6" xlink:to="loc_run_ServiceMember_9B106FB3F2A15B154A4E3581C4BA7FCF" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_CustomerAgreementsMember" xlink:label="loc_run_CustomerAgreementsMember_299A1A5CEE9D49E9A0DC3581C4BAE334" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_ServiceMember_9B106FB3F2A15B154A4E3581C4BA7FCF" xlink:to="loc_run_CustomerAgreementsMember_299A1A5CEE9D49E9A0DC3581C4BAE334" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_IncentivesMember" xlink:label="loc_run_IncentivesMember_8F2772207A2DFE0751533581C4BABA3A" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_run_ServiceMember_9B106FB3F2A15B154A4E3581C4BA7FCF" xlink:to="loc_run_IncentivesMember_8F2772207A2DFE0751533581C4BABA3A" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ProductMember" xlink:label="loc_us-gaap_ProductMember_196C2EE8546FB4DC3CE83581C4BAB328" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductsAndServicesDomain_26B75443E73191E83FE73581C4B999A6" xlink:to="loc_us-gaap_ProductMember_196C2EE8546FB4DC3CE83581C4BAB328" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_SolarEnergySystemsMember" xlink:label="loc_run_SolarEnergySystemsMember_A64B27DD40C26789684E3581C4BA8BB6" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductMember_196C2EE8546FB4DC3CE83581C4BAB328" xlink:to="loc_run_SolarEnergySystemsMember_A64B27DD40C26789684E3581C4BA8BB6" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_ManufacturedProductOtherMember" xlink:label="loc_run_ManufacturedProductOtherMember_C9923ABD9008F5D3FC2E3581C4BBE755" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ProductMember_196C2EE8546FB4DC3CE83581C4BAB328" xlink:to="loc_run_ManufacturedProductOtherMember_C9923ABD9008F5D3FC2E3581C4BBE755" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_C86DA5911A660B4333273581C4BBB6E5" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_8189A2A6D65711C186233581C4BBE904" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_C86DA5911A660B4333273581C4BBB6E5" 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_E335CB24FAC0715232A13581C4BBFA43" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EntityWideRevenueMajorCustomerLineItems_8189A2A6D65711C186233581C4BBE904" xlink:to="loc_us-gaap_Revenues_E335CB24FAC0715232A13581C4BBFA43" 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_2F05A30CB505ACBFFEFB0CDC077A3C1F" 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_AC6C1193D337FB547D630CDC07783616" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/all" xlink:from="loc_us-gaap_VariableInterestEntityLineItems_2F05A30CB505ACBFFEFB0CDC077A3C1F" xlink:to="loc_us-gaap_ScheduleOfVariableInterestEntitiesTable_AC6C1193D337FB547D630CDC07783616" 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_A7DB0DF9A6745FAF4D020CDC07780860" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfVariableInterestEntitiesTable_AC6C1193D337FB547D630CDC07783616" xlink:to="loc_us-gaap_StatementEquityComponentsAxis_A7DB0DF9A6745FAF4D020CDC07780860" 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_12535BDECCF4E3E7AF740CDC07786545_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_A7DB0DF9A6745FAF4D020CDC07780860" xlink:to="loc_us-gaap_EquityComponentDomain_12535BDECCF4E3E7AF740CDC07786545_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_12535BDECCF4E3E7AF740CDC07786545" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_StatementEquityComponentsAxis_A7DB0DF9A6745FAF4D020CDC07780860" xlink:to="loc_us-gaap_EquityComponentDomain_12535BDECCF4E3E7AF740CDC07786545" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_AdditionalPaidInCapitalMember" xlink:label="loc_us-gaap_AdditionalPaidInCapitalMember_38A4710D9A888509B3B80CDC07796B7C" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_EquityComponentDomain_12535BDECCF4E3E7AF740CDC07786545" xlink:to="loc_us-gaap_AdditionalPaidInCapitalMember_38A4710D9A888509B3B80CDC07796B7C" xlink:type="arc" />
    <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_82B86CFFA0C424D0E96E0CDC07796BFB" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/hypercube-dimension" xlink:from="loc_us-gaap_ScheduleOfVariableInterestEntitiesTable_AC6C1193D337FB547D630CDC07783616" xlink:to="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_82B86CFFA0C424D0E96E0CDC07796BFB" 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_FC8C1AD21F20CC7DC5F20CDC077977D0_default" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-default" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_82B86CFFA0C424D0E96E0CDC07796BFB" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_FC8C1AD21F20CC7DC5F20CDC077977D0_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_FC8C1AD21F20CC7DC5F20CDC077977D0" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/dimension-domain" xlink:from="loc_us-gaap_VariableInterestEntitiesByClassificationOfEntityAxis_82B86CFFA0C424D0E96E0CDC07796BFB" xlink:to="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_FC8C1AD21F20CC7DC5F20CDC077977D0" 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_A8429A2EF473D7AC1B1F0CDC0779CB2F" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_ClassificationOfVariableInterestEntityDomain_FC8C1AD21F20CC7DC5F20CDC077977D0" xlink:to="loc_us-gaap_VariableInterestEntityPrimaryBeneficiaryMember_A8429A2EF473D7AC1B1F0CDC0779CB2F" 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_DF534BEB48B480CB964F0CDC077AB85E" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableInterestEntityLineItems_2F05A30CB505ACBFFEFB0CDC077A3C1F" xlink:to="loc_us-gaap_AssetsAbstract_DF534BEB48B480CB964F0CDC077AB85E" 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_CEA5CFD9FC50A129DD8E0CDC077A8EE8" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_DF534BEB48B480CB964F0CDC077AB85E" xlink:to="loc_us-gaap_AssetsCurrentAbstract_CEA5CFD9FC50A129DD8E0CDC077A8EE8" 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_47355719E34BC4A3F6CC0CDC077A3D2B" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_CEA5CFD9FC50A129DD8E0CDC077A8EE8" xlink:to="loc_us-gaap_Cash_47355719E34BC4A3F6CC0CDC077A3D2B" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_RestrictedCashCurrent" xlink:label="loc_us-gaap_RestrictedCashCurrent_88EEFDCCBD8B7A5B01620CDC077B74EE" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_CEA5CFD9FC50A129DD8E0CDC077A8EE8" xlink:to="loc_us-gaap_RestrictedCashCurrent_88EEFDCCBD8B7A5B01620CDC077B74EE" 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_2D02701505E8D137C8DE0CDC077BBA96" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_CEA5CFD9FC50A129DD8E0CDC077A8EE8" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_2D02701505E8D137C8DE0CDC077BBA96" 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_8AE42D22AB6B1D4FCA960CDC077BB40E" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_CEA5CFD9FC50A129DD8E0CDC077A8EE8" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_8AE42D22AB6B1D4FCA960CDC077BB40E" 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_2115F817958F593169500CDC077BC54F" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsCurrentAbstract_CEA5CFD9FC50A129DD8E0CDC077A8EE8" xlink:to="loc_us-gaap_AssetsCurrent_2115F817958F593169500CDC077BC54F" 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_BEAC88CB8E37B95DE31B0CDC077B628D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_DF534BEB48B480CB964F0CDC077AB85E" xlink:to="loc_us-gaap_PropertySubjectToOrAvailableForOperatingLeaseNet_BEAC88CB8E37B95DE31B0CDC077B628D" 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_DCED964C7B15545B996B0CDC077BE00F" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_DF534BEB48B480CB964F0CDC077AB85E" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_DCED964C7B15545B996B0CDC077BE00F" 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_015C543A06DA8F832C990CDC077C74F7" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_AssetsAbstract_DF534BEB48B480CB964F0CDC077AB85E" xlink:to="loc_us-gaap_Assets_015C543A06DA8F832C990CDC077C74F7" 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_732347B663EB614196C10CDC077CDACF" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_VariableInterestEntityLineItems_2F05A30CB505ACBFFEFB0CDC077A3C1F" xlink:to="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" 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_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" xlink:to="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" 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_AAC07A528DEF6EAE9F370CDC077CF4DD" xlink:type="locator" />
    <link:definitionArc order="1" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_us-gaap_AccountsPayableCurrent_AAC07A528DEF6EAE9F370CDC077CF4DD" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests" xlink:label="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_081F1CD174CA9E3177380CDC077C637D" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_run_DistributionsPayableToNoncontrollingInterestsAndRedeemableNoncontrollingInterests_081F1CD174CA9E3177380CDC077C637D" 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_E34C77B5F5EB63A481FC0CDC077D3FD6" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_us-gaap_AccruedLiabilitiesAndOtherLiabilities_E34C77B5F5EB63A481FC0CDC077D3FD6" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiabilityCurrent" xlink:label="loc_us-gaap_ContractWithCustomerLiabilityCurrent_FC7EAF65A778AEBF42000CDC077D7BF1" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_us-gaap_ContractWithCustomerLiabilityCurrent_FC7EAF65A778AEBF42000CDC077D7BF1" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredGrantCurrentPortion" xlink:label="loc_run_DeferredGrantCurrentPortion_1B0659D2F46C15080F300CDC077DF38E" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_run_DeferredGrantCurrentPortion_1B0659D2F46C15080F300CDC077DF38E" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_NonRecourseDebtCurrent" xlink:label="loc_run_NonRecourseDebtCurrent_62783889B05C55AB79AA0CDC077D730F" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_run_NonRecourseDebtCurrent_62783889B05C55AB79AA0CDC077D730F" 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_66061072AB9826A2E7490CDC077DCC46" xlink:type="locator" />
    <link:definitionArc order="7" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesCurrentAbstract_CF6DD60A2FCFE05B52400CDC077C0C62" xlink:to="loc_us-gaap_LiabilitiesCurrent_66061072AB9826A2E7490CDC077DCC46" xlink:type="arc" />
    <link:loc xlink:href="http://xbrl.fasb.org/us-gaap/2017/elts/us-gaap-2017-01-31.xsd#us-gaap_ContractWithCustomerLiabilityNoncurrent" xlink:label="loc_us-gaap_ContractWithCustomerLiabilityNoncurrent_C11191A972D68BFA2C5D0CDC077DE83B" xlink:type="locator" />
    <link:definitionArc order="2" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" xlink:to="loc_us-gaap_ContractWithCustomerLiabilityNoncurrent_C11191A972D68BFA2C5D0CDC077DE83B" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_DeferredGrantIncomeNoncurrent" xlink:label="loc_run_DeferredGrantIncomeNoncurrent_4EAE54902A808F36101B0CDC077EDE02" xlink:type="locator" />
    <link:definitionArc order="3" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" xlink:to="loc_run_DeferredGrantIncomeNoncurrent_4EAE54902A808F36101B0CDC077EDE02" xlink:type="arc" />
    <link:loc xlink:href="run-20181231.xsd#run_NonRecourseDebtNoncurrent" xlink:label="loc_run_NonRecourseDebtNoncurrent_EA4EF7F80CFAAA99B8000CDC077E41D0" xlink:type="locator" />
    <link:definitionArc order="4" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" xlink:to="loc_run_NonRecourseDebtNoncurrent_EA4EF7F80CFAAA99B8000CDC077E41D0" 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_360A3D91AC2110A192A80CDC077EBD48" xlink:type="locator" />
    <link:definitionArc order="5" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_360A3D91AC2110A192A80CDC077EBD48" 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_C80457D1E831ED5B265A0CDC077EC042" xlink:type="locator" />
    <link:definitionArc order="6" xlink:arcrole="http://xbrl.org/int/dim/arcrole/domain-member" xlink:from="loc_us-gaap_LiabilitiesAbstract_732347B663EB614196C10CDC077CDACF" xlink:to="loc_us-gaap_Liabilities_C80457D1E831ED5B265A0CDC077EC042" xlink:type="arc" />
  </link:definitionLink>
  <link:definitionLink xlink:role="http://www.sunrun.com/role/VieArrangementsTables" xlink:type="extended" />
</link:linkbase>


