SECTION 1. SHORT TITLE.

    This Act may be cited as the ``American Renewable Fuel and Job 
Creation Act of 2017''.

SEC. 2. REFORM AND EXTENSION OF BIODIESEL TAX INCENTIVES.

    (a) Income Tax Credit.--
            (1) In general.--So much of section 40A of the Internal 
        Revenue Code as precedes subsection (c) is amended to read as 
        follows:

``SEC. 40A. BIODIESEL FUELS CREDIT.

    ``(a) In General.--For purposes of section 38, the biodiesel fuels 
credit determined under this section for the taxable year is $1.00 for 
each gallon of biodiesel produced by the taxpayer which during the 
taxable year--
            ``(1) is sold by the taxpayer to another person--
                    ``(A) for use by such other person's trade or 
                business as a fuel or in the production of a qualified 
                biodiesel mixture (other than casual off-farm 
                production), or
                    ``(B) who sells such biodiesel at retail to another 
                person and places such biodiesel in the fuel tank of 
                such other person, or
            ``(2) is used by such taxpayer for any purpose described in 
        paragraph (1).
    ``(b) Increased Credit for Small Producers.--
            ``(1) In general.--In the case of any eligible small 
        biodiesel producer, subsection (a) shall be applied by 
        increasing the dollar amount contained therein by 10 cents.
            ``(2) Limitation.--Paragraph (1) shall only apply with 
        respect to the first 15,000,000 gallons of biodiesel produced 
        by any eligible small biodiesel producer during any taxable 
        year.''.
            (2) Definitions and special rules.--Section 40A(d) of such 
        Code is amended by striking all that follows paragraph (1) and 
        inserting the following:
            ``(2) Qualified biodiesel mixture; biodiesel mixture.--
                    ``(A) Qualified biodiesel mixture.--
                            ``(i) In general.--The term `qualified 
                        biodiesel mixture' means a biodiesel mixture 
                        which is--
                                    ``(I) sold by the producer of such 
                                mixture to any person for use as a 
                                fuel, or
                                    ``(II) used by the producer of such 
                                mixture as a fuel.
                            ``(ii) Sale or use must be in trade or 
                        business, etc.--A biodiesel mixture shall not 
                        be treated as a qualified biodiesel mixture 
                        unless the sale or use described in clause (i) 
                        is in a trade or business of the person 
                        producing the biodiesel mixture.
                    ``(B) Biodiesel mixture.--The term `biodiesel 
                mixture' means a mixture which consists of biodiesel 
                and diesel fuel (as defined in section 4083(a)(3)), 
                determined without regard to any use of kerosene.
            ``(3) Biodiesel not used for a qualified purpose.--If--
                    ``(A) any credit was determined with respect to any 
                biodiesel under this section, and
                    ``(B) any person uses such biodiesel for a purpose 
                not described in subsection (a),
        then there is hereby imposed on such person a tax equal to the 
        product of the rate applicable under subsection (a) and the 
        number of gallons of such biodiesel.
            ``(4) Pass-thru in the case of estates and trusts.--Under 
        regulations prescribed by the Secretary, rules similar to the 
        rules of subsection (d) of section 52 shall apply.
            ``(5) Limitation to biodiesel with connection to the united 
        states.--
                    ``(A) In general.--No credit shall be determined 
                under subsection (a) with respect to biodiesel unless 
                such biodiesel is produced in the United States from 
                qualified feedstocks. For purposes of this paragraph, 
                the term `United States' includes any possession of the 
                United States.
                    ``(B) Qualified feedstocks.--For purposes of 
                subparagraph (A), the term `qualified feedstock' means 
                any feedstock which is allowable for a fuel that is 
                assigned a D code of 4 under section 80.1426(f) of 
                title 40, Code of Federal Regulations.''.
            (3) Rules for small biodiesel producers.--
                    (A) In general.--Section 40A(e) of such Code is 
                amended--
                            (i) by striking ``agri-biodiesel'' each 
                        place it appears in paragraphs (1) and (5)(A) 
                        and inserting ``biodiesel'',
                            (ii) by striking ``subsection (b)(4)(C)'' 
                        each place it appears in paragraphs (2) and (3) 
                        and inserting ``subsection (b)(2)'', and
                            (iii) by striking ``subsection (a)(3)'' 
                        each place it appears in paragraphs (5)(A), 
                        (6)(A)(i), and (6)(B)(i) and inserting 
                        ``subsection (b)''.
                    (B) The heading for subsection (e) of section 40A 
                of such Code is amended by striking ``Agri-biodiesel'' 
                and inserting ``Biodiesel''.
                    (C) The headings for paragraphs (1) and (6) of 
                section 40A(e) of such Code are each amended by 
                striking ``agri-biodiesel'' and inserting 
                ``biodiesel''.
            (4) Renewable diesel.--
                    (A) In general.--Paragraph (3) of section 40A(f) of 
                such Code is amended to read as follows:
            ``(3) Renewable diesel defined.--
                    ``(A) In general.--The term `renewable diesel' 
                means liquid fuel derived from biomass which--
                            ``(i) is not a mono-alkyl ester,
                            ``(ii) can be used in engines designed to 
                        operate on conventional diesel fuel, and
                            ``(iii) meets the requirements for any 
                        Grade No. 1-D fuel or Grade No. 2-D fuel 
                        covered under the American Society for Testing 
                        and Materials specification D-975-13a.
                    ``(B) Exceptions.--Such term shall not include--
                            ``(i) any liquid with respect to which a 
                        credit may be determined under section 40,
                            ``(ii) any fuel derived from coprocessing 
                        biomass with a feedstock which is not biomass, 
                        or
                            ``(iii) any fuel that is not chemically 
                        equivalent to petroleum diesel fuels that can 
                        meet fuel quality specifications applicable to 
                        diesel fuel, gasoline, or aviation fuel.
                    ``(C) Biomass.--For purposes of this paragraph, the 
                term `biomass' has the meaning given such term by 
                section 45K(c)(3).''.
                    (B) Conforming amendments.--Section 40A(f) of such 
                Code is amended--
                            (i) by striking ``Subsection (b)(4)'' in 
                        paragraph (2) and inserting ``Subsection (b)'', 
                        and
                            (ii) by striking paragraph (4) and 
                        inserting the following:
            ``(4) Certain aviation fuel.--Except as provided paragraph 
        (3)(B), the term `renewable diesel' shall include fuel derived 
        from biomass which meets the requirements of a Department of 
        Defense specification for military jet fuel or an American 
        Society for Testing and Materials specification for aviation 
        turbine fuel.''.
            (5) Extension.--Subsection (g) of section 40A of such Code 
        is amended by striking ``December 31, 2016'' and inserting 
        ``December 31, 2020''.
            (6) Clerical amendment.--The table of sections for subpart 
        D of part IV of subchapter A of chapter 1 of such Code is 
        amended by striking the item relating to section 40A and 
        inserting the following new item:

``Sec. 40A. Biodiesel fuels credit.''.
    (b) Excise Tax Credit.--
            (1) Reform.--Subsection (c) of section 6426 of the Internal 
        Revenue Code of 1986 is amended to read as follows:
    ``(c) Biodiesel Production Credit.--
            ``(1) In general.--For purposes of this section, the 
        biodiesel production credit is $1.00 for each gallon of 
        biodiesel produced by the taxpayer and which--
                    ``(A) is sold by such taxpayer to another person--
                            ``(i) for use by such other person's trade 
                        or business as a fuel or in the production of a 
                        qualified biodiesel mixture (other than casual 
                        off-farm production), or
                            ``(ii) who sells such biodiesel at retail 
                        to another person and places such biodiesel in 
                        the fuel tank of such other person, or
                    ``(B) is used by such taxpayer for any purpose 
                described in subparagraph (A).
            ``(2) Definitions.--Any term used in this subsection which 
        is also used in section 40A shall have the meaning given such 
        term by section 40A.
            ``(3) Termination.--This subsection shall not apply to any 
        sale, use, or removal after December 31, 2020.''.
            (2) Producer registration requirement.--Subsection (a) of 
        section 6426 of such Code is amended by striking ``subsections 
        (d) and (e)'' in the flush sentence at the end and inserting 
        ``subsections (c), (d), and (e)''.
            (3) Recapture.--
                    (A) In general.--Subsection (f) of section 6426 of 
                such Code is amended--
                            (i) by striking ``or biodiesel'' each place 
                        it appears in subparagraphs (A) and (B)(i) of 
                        paragraph (1),
                            (ii) by striking ``or biodiesel mixture'' 
                        in paragraph (1)(A), and
                            (iii) by redesignating paragraph (2) as 
                        paragraph (3) and by inserting after paragraph 
                        (1) the following new paragraph:
            ``(2) Biodiesel.--If any credit was determined under this 
        section or paid pursuant to section 6427(e) with respect to the 
        production of any biodiesel and any person uses such biodiesel 
        for a purpose not described in subsection (c)(1), then there is 
        hereby imposed on such person a tax equal to $1 for each gallon 
        of such biodiesel.''.
                    (B) Conforming amendments.--
                            (i) Paragraph (3) of section 6426(f) of 
                        such Code, as redesignated by subparagraph 
                        (A)(iii), is amended by inserting ``or (2)'' 
                        after ``paragraph (1)''.
                            (ii) The heading for paragraph (1) of 
                        section 6426(f) of such Code is amended by 
                        striking ``Imposition of tax'' and inserting 
                        ``In general''.
            (4) Limitation.--Section 6426(i) of such Code is amended--
                    (A) in paragraph (2)--
                            (i) by striking ``biodiesel or'', and
                            (ii) by striking ``Biodiesel and'' in the 
                        heading, and
                    (B) by inserting after paragraph (2) the following 
                new paragraph:
            ``(3) Biodiesel.--No credit shall be determined under 
        subsection (a) with respect to biodiesel unless such biodiesel 
        is produced in the United States from qualified feedstocks (as 
        defined in section 40A(d)(5)(B)).''.
            (5) Clerical amendments.--
                    (A) The heading of section 6426 of such Code is 
                amended by striking ``alcohol fuel, biodiesel, and 
                alternative fuel mixtures'' and inserting ``alcohol 
                fuel mixtures, biodiesel production, and alternative 
                fuel mixtures''.
                    (B) The item relating to section 6426 in the table 
                of sections for subchapter B of chapter 65 of such Code 
                is amended by striking ``alcohol fuel, biodiesel, and 
                alternative fuel mixtures'' and inserting ``alcohol 
                fuel mixtures, biodiesel production, and alternative 
                fuel mixtures''.
    (c) Excise Payments.--Subsection (e) of section 6427 of the 
Internal Revenue Code of 1986 is amended--
            (1) by striking ``or the biodiesel mixture credit'' in 
        paragraph (1),
            (2) by redesignating paragraphs (3) through (6) as 
        paragraphs (4) through (7), respectively, and by inserting 
        after paragraph (2) the following new paragraph:
            ``(3) Biodiesel production credit.--If any person produces 
        biodiesel and sells or uses such biodiesel as provided in 
        section 6426(c)(1), the Secretary shall pay (without interest) 
        to such person an amount equal to the biodiesel production 
        credit with respect to such biodiesel.'',
            (3) by striking ``paragraph (1) or (2)'' each place it 
        appears in paragraphs (4) and (6), as redesignated by paragraph 
        (2), and inserting ``paragraph (1), (2), or (3)'',
            (4) by striking ``alternative fuel'' each place it appears 
        in paragraphs (4) and (6), as redesignated by paragraph (2), 
        and inserting ``fuel'', and
            (5) in paragraph (7)(B), as redesignated by paragraph (2)--
                    (A) by striking ``biodiesel mixture (as defined in 
                section 6426(c)(3))'' and inserting ``biodiesel (within 
                the meaning of section 40A)'', and
                    (B) by striking ``December 31, 2016'' and inserting 
                ``December 31, 2020''.
    (d) Guidance.--Not later than 30 days after the date of the 
enactment of this Act, the Secretary of the Treasury, or the 
Secretary's delegate, shall issue preliminary guidance with respect to 
the amendments made by this section.
    (e) Effective Date.--The amendments made by this section shall 
apply to fuel sold or used after December 31, 2016.
    (f) Special Rule for 2017.--Notwithstanding any other provision of 
law, in the case of any biodiesel mixture credit properly determined 
under section 6426(c) of the Internal Revenue Code of 1986 for period 
beginning after December 31, 2016, and ending before the date of the 
enactment of this Act, such credit shall be allowed, and any refund or 
payment attributable to such credit (including any payment under 
section 6427(e) of such Code) shall be made, only in such manner as the 
Secretary of the Treasury (or the Secretary's delegate) shall provide. 
Such Secretary shall issue guidance within 30 days after the date of 
the enactment of this Act providing for a one-time submission of claims 
covering periods described in the preceding sentence. Such guidance 
shall provide for a 180-day period for the submission of such claims 
(in such manner as prescribed by such Secretary) to begin not later 
than 30 days after such guidance is issued. Such claims shall be paid 
by such Secretary not later than 60 days after receipt. If such 
Secretary has not paid pursuant to a claim filed under this subsection 
within 60 days after the date of the filing of such claim, the claim 
shall be paid with interest from such date determined by using the 
overpayment rate and method under section 6621 of such Code.
Output: American Renewable Fuel and Job Creation Act of 2017  This bill amends the Internal Revenue Code to modify and extend: (1) the income tax credit for biodiesel and renewable diesel used as fuel, and (2) the excise tax credit for biodiesel fuel mixtures.  The bill: (1) makes the credits available to domestic producers of the fuels rather than the policy under current law of providing a mixture credit to the blender of the fuel, (2) increases the income tax credit for certain small biodiesel producers, and (3) extends the credits through 2020.