<?xml version="1.0" encoding="us-ascii"?><InstanceReport xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><Version>2.4.0.8</Version><ReportLongName>0020 - Disclosure - 13. CONVERTIBLE NOTES PAYABLE</ReportLongName><DisplayLabelColumn>true</DisplayLabelColumn><ShowElementNames>false</ShowElementNames><RoundingOption /><HasEmbeddedReports>false</HasEmbeddedReports><Columns><Column FlagID="0"><Id>1</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><CurrencyCode /><FootnoteIndexer /><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios><MCU><KeyName /><CurrencySymbol /><contextRef><ContextID>From2012-10-01to2013-06-30</ContextID><EntitySchema>http://www.sec.gov/CIK</EntitySchema><EntityValue>0001074828</EntityValue><PeriodDisplayName /><PeriodType>duration</PeriodType><PeriodStartDate>2012-10-01T00:00:00</PeriodStartDate><PeriodEndDate>2013-06-30T00:00:00</PeriodEndDate><Segments /><Scenarios /></contextRef><UPS /><CurrencyCode /><OriginalCurrencyCode /></MCU><CurrencySymbol /><Labels><Label Key="CalendarSupplement" Id="0" Label="9 Months Ended" /><Label Key="Calendar" Id="1" Label="Jun. 30, 2013" /></Labels></Column><Column FlagID="0"><Id>2</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><CurrencyCode /><FootnoteIndexer /><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios><MCU><KeyName /><CurrencySymbol /><contextRef><ContextID>From2011-10-01to2012-09-30</ContextID><EntitySchema>http://www.sec.gov/CIK</EntitySchema><EntityValue>0001074828</EntityValue><PeriodDisplayName /><PeriodType>duration</PeriodType><PeriodStartDate>2011-10-01T00:00:00</PeriodStartDate><PeriodEndDate>2012-09-30T00:00:00</PeriodEndDate><Segments /><Scenarios /></contextRef><UPS /><CurrencyCode /><OriginalCurrencyCode /></MCU><CurrencySymbol /><Labels><Label Key="CalendarSupplement" Id="0" Label="12 Months Ended" /><Label Key="Calendar" Id="1" Label="Sep. 30, 2012" /></Labels></Column></Columns><Rows><Row FlagID="0"><Id>1</Id><IsAbstractGroupTitle>true</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><Level>1</Level><ElementName>VSUL_NotesToFinancialStatementsAbstract</ElementName><ElementPrefix>VSUL_</ElementPrefix><IsBaseElement>false</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsCalendarTitle>false</IsCalendarTitle><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><FootnoteIndexer /><Cells><Cell FlagID="0" ContextID="" UnitID=""><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText /><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell><Cell FlagID="0" ContextID="" UnitID=""><Id>2</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText /><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell></Cells><ElementDataType>xbrli:stringItemType</ElementDataType><SimpleDataType>string</SimpleDataType><IsTotalLabel>false</IsTotalLabel><UnitID>0</UnitID><Label>Notes to Financial Statements</Label></Row><Row FlagID="0"><Id>2</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>
</LabelSeparator><Level>2</Level><ElementName>us-gaap_DebtDisclosureTextBlock</ElementName><ElementPrefix>us-gaap_</ElementPrefix><IsBaseElement>true</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsCalendarTitle>false</IsCalendarTitle><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><FootnoteIndexer /><Cells><Cell FlagID="0" ContextID="From2012-10-01to2013-06-30" UnitID=""><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText>&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&lt;i&gt;Agreements with Gemini Master Fund, Ltd.
and Ascendiant Capital Partners, LLC&lt;/i&gt;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;On May 31, 2013, the Company paid $250,000 plus
interest of $35,175 under the Amendment to Warrant Purchase Agreement with Gemini dated January 23, 2013. The Company has acquired
the warrant from Gemini and cancelled it.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify; text-indent: 0.5in"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;On June 26, 2013, the Company acquired all additional
investment rights (&amp;#147;AIR&amp;#148;) between the Company and Gemini under the AIR Agreement dated January 23, 2013 with the payment
of $850,000 and interest of $17,349.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify; text-indent: 0.5in"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;The Company&amp;#146;s equity line of credit with
Ascendiant remains outstanding, with available credit of $2,516,859. The Company has no current intention to utilize this line
of credit, which expires August 29, 2013.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify; text-indent: 0.5in"&gt;&amp;#160;&lt;/p&gt;</NonNumbericText><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell><Cell FlagID="0" ContextID="From2011-10-01to2012-09-30" UnitID=""><Id>2</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText>&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;On May 19, 2011, the Company entered into a Securities Purchase Agreement
(&amp;#147;Agreement&amp;#148;) with Gemini Master Fund, Ltd. (&amp;#147;Gemini&amp;#148;) and Ascendiant Capital Partners, LLC&amp;#160;(&amp;#147;Ascendiant&amp;#148;)
(Gemini and Ascendiant are collectively referred to as the &amp;#147;Investors&amp;#148;), pursuant to which the Company issued $1.2
million in principal amount of 10% convertible debentures (the &amp;#147;Original Debentures&amp;#148;) which were due May 1, 2012.&amp;#160;&amp;#160;The
due date of the Original Debentures was extended to September 30, 2012 pursuant to a First Amendment to the Agreement on March
12, 2012, and further extended to September 30, 2013 pursuant to a Second Amendment to the Agreement on August 16, 2012. In addition,
the Company issued 5-year warrants to the Investors to collectively purchase 2,400,000 shares of our common stock. The purchase
price for the debentures was 83.3% of the face amount, resulting in the Company receiving $1.0 million, less legal fees, placement
agent fees and expenses as set forth below. The Agreement includes an additional investment right granted to the Investors, pursuant
to which the Investors have the right at any time until September 30, 2013, to purchase up to $1.2 million in principal amount
of additional debentures (the &amp;#147;Additional Debentures&amp;#148;) on the same terms and conditions as the Original Debentures,
except that the conversion price on the Additional Debentures may have a higher floor.&amp;#160;&amp;#160;The conversion price on both
the Original Debentures and the Additional Debentures are subject to a potential downward adjustment for any equity sales subsequent
to the date of issuance. In conjunction with the purchase of the Additional Debentures, the Investors also have the right to purchase
additional warrants. The full terms of the transactions with Gemini and Ascendiant are set forth in the transaction agreements,
copies of which are filed with this 10-K as Exhibits 10.1 through 10.10.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;On August 28, 2012, the Company entered into a Warrant Purchase Agreement
with Gemini and acquired the Gemini Warrant covering the purchase of up to 1.8 million shares, subject to adjustment, by paying
$250,000 on August 28, 2012 and agreeing to pay $250,000 on or before November 30, 2012. &amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;As of September 30, 2012, Gemini has $600,000 and Ascendiant has
$150,000 remaining in principal amount of Original Debentures outstanding plus accrued interest thereon that is convertible into
common shares. Ascendiant also has a warrant for the purchase of up to 600,000 shares of our common stock at an original exercise
price of $.35 per share, which exercise price is subject to adjustment and which has been adjusted downward as of the date hereof.&amp;#160;&amp;#160;See
Exhibit 10.6 filed herewith. In addition, the additional investment and participation rights as defined in the Agreement granted
to the Investors were extended from September 30, 2012 to September 30, 2013.&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;The Company paid legal fees and expenses in
the amount of $12,500. Visualant also paid $80,000 or 8.0% of the cash received and issued a five-year warrant for 192,000 shares
in placement agent fees to Ascendiant Capital Markets LLC.&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;The Company filed a registration statement on Form S-1, which was
declared effective on August 29, 2011, to register 15,340,361 shares of its common stock, including (i) up to 5,400,000 shares
of our common stock for Gemini issuable on&amp;#160;conversion and the exercise of a warrant issued to Gemini and (ii) up to 1,992,000
shares of our common stock for Ascendiant issuable on conversion of debt and&amp;#160;the&amp;#160;exercise of a warrant issued to Ascendiant.&amp;#160;&amp;#160;As
of September 30, 2012, 7,036,975 shares of the Company&amp;#146;s common stock have been issued to Gemini upon conversion of $300,000
of the convertible debentures and interest of $20,780 at an average of $0.05 per share.&amp;#160;&amp;#160;As of September 30, 2012, 3,373,425
shares of the Company&amp;#146;s common stock have been issued to Ascendiant upon conversion of $150,000 of the convertible debentures
and interest of $18,671 at an average of $0.05 per share.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;During the year ended September 30, 2012, the Company modified its
outstanding debentures with an aggregate principal value of $1,200,000. The maturity date has been extended to September 30, 2013,
the Investors have converted principal and interest as outlined above at $0.05 and the Company paid a premium to the debenture
holders in the form of redeeming the outstanding warrants for $500,000. The fair value of the warrants was calculated using the
Black-Scholes-Merton option valuation model. The following assumptions were used to determine the fair value of the Warrants using
the Black-Scholes valuation model: a term of five years, risk-free rate of 3.92%, volatility of 100%, and dividend yield of zero.
Interest expense has been recorded for the loss of $500,000 related to the modification of the debentures.&amp;#160;&amp;#160;The difference
between the conversion price and the fair market value of the common stock on the commitment date resulted in a beneficial conversion
feature recorded of $216,000. Total interest expense recognized, including the beneficial conversion feature was $313,534 during
the year ended September 30, 2012.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;The conversion of the convertible notes payable
and the related warrants will likely result in a substantial dilution of the value of the common shares for all shareholders.&amp;#160;&amp;#160;&amp;#160;&lt;/p&gt;</NonNumbericText><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell></Cells><ElementDataType>nonnum:textBlockItemType</ElementDataType><SimpleDataType>na</SimpleDataType><ElementDefenition>The entire disclosure for information about short-term and long-term debt arrangements, which includes amounts of borrowings under each line of credit, note payable, commercial paper issue, bonds indenture, debenture issue, own-share lending arrangements and any other contractual agreement to repay funds, and about the underlying arrangements, rationale for a classification as long-term, including repayment terms, interest rates, collateral provided, restrictions on use of assets and activities, whether or not in compliance with debt covenants, and other matters important to users of the financial statements, such as the effects of refinancing and noncompliance with debt covenants.</ElementDefenition><ElementReferences>Reference 1: http://www.xbrl.org/2003/role/presentationRef
 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 505

 -SubTopic 10

 -Section 50

 -Paragraph 3

 -URI http://asc.fasb.org/extlink&amp;oid=6928386&amp;loc=d3e21475-112644



Reference 2: http://www.xbrl.org/2003/role/presentationRef

 -Publisher SEC

 -Name Regulation S-X (SX)

 -Number 210

 -Section 02

 -Paragraph 19, 20, 22

 -Article 5



Reference 3: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 210

 -SubTopic 10

 -Section S99

 -Paragraph 1

 -Subparagraph (SX 210.5-02.19,20,22)

 -URI http://asc.fasb.org/extlink&amp;oid=6877327&amp;loc=d3e13212-122682



</ElementReferences><IsTotalLabel>false</IsTotalLabel><UnitID>0</UnitID><Label>13. CONVERTIBLE NOTES PAYABLE</Label></Row></Rows><Footnotes /><IsEquityReport>false</IsEquityReport><ReportName>13. CONVERTIBLE NOTES PAYABLE</ReportName><MonetaryRoundingLevel>UnKnown</MonetaryRoundingLevel><SharesRoundingLevel>UnKnown</SharesRoundingLevel><PerShareRoundingLevel>UnKnown</PerShareRoundingLevel><ExchangeRateRoundingLevel>UnKnown</ExchangeRateRoundingLevel><HasCustomUnits>true</HasCustomUnits><IsEmbedReport>false</IsEmbedReport><IsMultiCurrency>false</IsMultiCurrency><ReportType>Notes</ReportType><RoleURI>http://visualant.net/role/ConvertibleNotesPayable</RoleURI><NumberOfCols>2</NumberOfCols><NumberOfRows>2</NumberOfRows></InstanceReport>
