<?xml version="1.0"?>
<ownershipDocument>

    <schemaVersion>X0306</schemaVersion>

    <documentType>4</documentType>

    <periodOfReport>2019-01-23</periodOfReport>

    <notSubjectToSection16>0</notSubjectToSection16>

    <issuer>
        <issuerCik>0000277948</issuerCik>
        <issuerName>CSX CORP</issuerName>
        <issuerTradingSymbol>CSX</issuerTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001695459</rptOwnerCik>
            <rptOwnerName>Mantle Ridge LP</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>900 THIRD AVENUE, 11TH FLOOR</rptOwnerStreet1>
            <rptOwnerStreet2></rptOwnerStreet2>
            <rptOwnerCity>NEW YORK</rptOwnerCity>
            <rptOwnerState>NY</rptOwnerState>
            <rptOwnerZipCode>10022</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>1</isDirector>
            <isOfficer>0</isOfficer>
            <isTenPercentOwner>0</isTenPercentOwner>
            <isOther>0</isOther>
            <officerTitle></officerTitle>
            <otherText></otherText>
        </reportingOwnerRelationship>
    </reportingOwner>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001695460</rptOwnerCik>
            <rptOwnerName>MR Argent Advisor LLC</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>900 THIRD AVENUE, 11TH FLOOR</rptOwnerStreet1>
            <rptOwnerStreet2></rptOwnerStreet2>
            <rptOwnerCity>NEW YORK</rptOwnerCity>
            <rptOwnerState>NY</rptOwnerState>
            <rptOwnerZipCode>10022</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>1</isDirector>
            <isOfficer>0</isOfficer>
            <isTenPercentOwner>0</isTenPercentOwner>
            <isOther>0</isOther>
            <officerTitle></officerTitle>
            <otherText></otherText>
        </reportingOwnerRelationship>
    </reportingOwner>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001695465</rptOwnerCik>
            <rptOwnerName>MR Argent GP LLC</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>900 3RD AVENUE, 11TH FLOOR</rptOwnerStreet1>
            <rptOwnerStreet2></rptOwnerStreet2>
            <rptOwnerCity>NEW YORK</rptOwnerCity>
            <rptOwnerState>NY</rptOwnerState>
            <rptOwnerZipCode>10022</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>1</isDirector>
            <isOfficer>0</isOfficer>
            <isTenPercentOwner>0</isTenPercentOwner>
            <isOther>0</isOther>
            <officerTitle></officerTitle>
            <otherText></otherText>
        </reportingOwnerRelationship>
    </reportingOwner>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001413084</rptOwnerCik>
            <rptOwnerName>Hilal Paul C</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>900 THIRD AVENUE, 11TH FLOOR</rptOwnerStreet1>
            <rptOwnerStreet2></rptOwnerStreet2>
            <rptOwnerCity>NEW YORK</rptOwnerCity>
            <rptOwnerState>NY</rptOwnerState>
            <rptOwnerZipCode>10022</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>1</isDirector>
            <isOfficer>0</isOfficer>
            <isTenPercentOwner>0</isTenPercentOwner>
            <isOther>0</isOther>
            <officerTitle></officerTitle>
            <otherText></otherText>
        </reportingOwnerRelationship>
    </reportingOwner>

    <nonDerivativeTable>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2019-01-23</value>
            </transactionDate>
            <deemedExecutionDate></deemedExecutionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>S</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>147908</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>65.83</value>
                    <footnoteId id="F1"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>42617193</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>See footnotes</value>
                    <footnoteId id="F2"/>
                    <footnoteId id="F3"/>
                    <footnoteId id="F4"/>
                    <footnoteId id="F5"/>
                    <footnoteId id="F6"/>
                    <footnoteId id="F7"/>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2019-01-23</value>
            </transactionDate>
            <deemedExecutionDate></deemedExecutionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>S</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>573910</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>64.83</value>
                    <footnoteId id="F8"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>42043283</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>See footnotes</value>
                    <footnoteId id="F2"/>
                    <footnoteId id="F3"/>
                    <footnoteId id="F4"/>
                    <footnoteId id="F5"/>
                    <footnoteId id="F6"/>
                    <footnoteId id="F7"/>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2019-01-23</value>
            </transactionDate>
            <deemedExecutionDate></deemedExecutionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>S</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>8500</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>64.23</value>
                    <footnoteId id="F9"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>42034783</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>See footnotes</value>
                    <footnoteId id="F2"/>
                    <footnoteId id="F3"/>
                    <footnoteId id="F4"/>
                    <footnoteId id="F5"/>
                    <footnoteId id="F6"/>
                    <footnoteId id="F7"/>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2019-01-24</value>
            </transactionDate>
            <deemedExecutionDate></deemedExecutionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>S</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>1200000</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>65.00</value>
                    <footnoteId id="F10"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>40834783</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>See footnotes</value>
                    <footnoteId id="F2"/>
                    <footnoteId id="F3"/>
                    <footnoteId id="F4"/>
                    <footnoteId id="F5"/>
                    <footnoteId id="F6"/>
                    <footnoteId id="F7"/>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
    </nonDerivativeTable>

    <derivativeTable></derivativeTable>

    <footnotes>
        <footnote id="F1">The price reported in Column 4 is a weighted average price. These shares were sold in multiple transactions through broker-dealers at prices ranging from $66.24 to $65.25. Mantle Ridge LP, a Delaware limited partnership (&quot;Mantle Ridge&quot;), and the other reporting persons undertake to provide CSX Corporation (the &quot;Issuer&quot;), any security holder of the Issuer, or the staff of the Securities and Exchange Commission, upon request, full information regarding the number of shares sold at each separate price within the ranges set forth in footnotes 1, 8, 9 and 10 to this Form 4.</footnote>
        <footnote id="F2">In addition to Mantle Ridge LP, a Delaware limited partnership (&quot;Mantle Ridge&quot;), this Form 4 is being filed jointly by MR Argent Advisor LLC, a Delaware limited liability company (&quot;MR Argent&quot;), MR Argent GP LLC, a Delaware limited liability company (&quot;Fund GP&quot;), and Paul C. Hilal, a citizen of the United States of America (collectively, the &quot;Reporting Persons&quot;), each of whom has the same business address as Mantle Ridge and may be deemed to have a pecuniary interest in the securities reported on this Form 4 (the &quot;Subject Securities&quot;).</footnote>
        <footnote id="F3">Seven shares of the Issuer are held by a wholly owned and wholly controlled special purpose subsidiary of Mantle Ridge.</footnote>
        <footnote id="F4">MR Argent, a wholly owned subsidiary of Mantle Ridge, advises the accounts of MR Argent Fund CE LP, a Delaware limited partnership, and MR Argent Offshore Fund AB LP, MR Argent Offshore Fund BB LP, MR Argent Offshore Fund CB 01 LP, MR Argent Offshore Fund CB 02 LP, MR Argent Offshore Fund CB 03 LP, MR Argent Offshore Fund CB 04 LP, MR Argent Offshore CB 05 LP and MR Argent Offshore CB 07 LP, each a Cayman Islands exempted limited partnership, and, if applicable, their subsidiaries, which are Cayman Islands exempted companies (all such funds and their subsidiaries together, the &quot;Mantle Ridge Funds&quot;).</footnote>
        <footnote id="F5">MR Argent, as the investment adviser to the Mantle Ridge Funds, and Mantle Ridge, as the sole member of MR Argent, each may be deemed to be the beneficial owner of the Subject Securities for purposes of Rule 16a-1(a) under the Securities Exchange Act of 1934. As the general partner of the Mantle Ridge Funds, Fund GP may be deemed to be the beneficial owner of the Subject Securities for purposes of Rule 16a-1(a). By virtue of Paul C. Hilal's position as ultimately controlling MR Argent, Mantle Ridge and MR GP HoldCo LLC, the sole member of the Fund GP, Paul C. Hilal may be deemed to be the beneficial owner of the Subject Securities for purposes of Rule 16a-1(a). Each of the Reporting Persons disclaims any beneficial ownership of any of the Subject Securities, except to the extent of any pecuniary interest therein.</footnote>
        <footnote id="F6">Paul C. Hilal is a member of the board of directors of the Issuer, and as a result, each of the Reporting Persons are directors by deputization for purposes of Section 16 of the Securities Exchange Act of 1934.</footnote>
        <footnote id="F7">Mantle Ridge and the other reporting persons have sold the shares reported in this Form 4 in order to accommodate a return of capital to two limited partners of the Mantle Ridge Funds.  Mantle Ridge and the other reporting persons expect to sell an additional 2,780,000 shares to complete that return of capital and thereafter have no current plans to sell shares of the Issuer, although they reserve the right to do so in their discretion.</footnote>
        <footnote id="F8">The price reported in Column 4 is a weighted average price. These shares were sold in multiple transactions through broker-dealers at prices ranging from $65.24 to $64.25.</footnote>
        <footnote id="F9">The price reported in Column 4 is a weighted average price. These shares were sold in multiple transactions through broker-dealers at prices ranging from $64.24 to $64.22.</footnote>
        <footnote id="F10">The price reported in Column 4 is a weighted average price. These shares were sold in multiple transactions through broker-dealers at prices ranging from $65.61 to $64.65.</footnote>
    </footnotes>

    <ownerSignature>
        <signatureName>MANTLE RIDGE LP By: Mantle Ridge GP LLC, its managing member By: PCH MR Advisor Holdings LLC, its managing member By: /s/ Paul C. Hilal Paul C. Hilal, Sole Member</signatureName>
        <signatureDate>2019-01-25</signatureDate>
    </ownerSignature>

    <ownerSignature>
        <signatureName>MR ARGENT ADVISOR LLC By: Mantle Ridge LP, its sole member By: Mantle Ridge GP LLC, its managing member By: PCH MR Advisor Holdings LLC, its managing Member By: /s/ Paul C. Hilal Paul C. Hilal, Sole Member</signatureName>
        <signatureDate>2019-01-25</signatureDate>
    </ownerSignature>

    <ownerSignature>
        <signatureName>MR ARGENT GP LLC By: MR GP HoldCo LLC, its managing member By: MR GP HoldCo MM LLC, its managing member By: PCH MR GP Holdings LLC, its managing member By: /s/ Paul C. Hilal Paul C. Hilal, Sole Member</signatureName>
        <signatureDate>2019-01-25</signatureDate>
    </ownerSignature>

    <ownerSignature>
        <signatureName>/s/ Paul C. Hilal Paul C. Hilal</signatureName>
        <signatureDate>2019-01-25</signatureDate>
    </ownerSignature>
</ownershipDocument>
