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

    <schemaVersion>X0508</schemaVersion>

    <documentType>4</documentType>

    <periodOfReport>2024-03-10</periodOfReport>

    <issuer>
        <issuerCik>0001258602</issuerCik>
        <issuerName>NELNET INC</issuerName>
        <issuerTradingSymbol>NNI</issuerTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001269813</rptOwnerCik>
            <rptOwnerName>NOORDHOEK JEFFREY R</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>121 SOUTH 13TH STREET</rptOwnerStreet1>
            <rptOwnerStreet2>SUITE 100</rptOwnerStreet2>
            <rptOwnerCity>LINCOLN</rptOwnerCity>
            <rptOwnerState>NE</rptOwnerState>
            <rptOwnerZipCode>68508</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isOfficer>true</isOfficer>
            <officerTitle>Chief Executive Officer</officerTitle>
        </reportingOwnerRelationship>
    </reportingOwner>

    <aff10b5One>false</aff10b5One>

    <nonDerivativeTable>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Class A Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2024-03-10</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>F</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>791</value>
                    <footnoteId id="F1"/>
                </transactionShares>
                <transactionPricePerShare>
                    <value>88.63</value>
                    <footnoteId id="F2"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>104026</value>
                    <footnoteId id="F3"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Class A Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2024-03-10</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>F</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>356</value>
                    <footnoteId id="F1"/>
                </transactionShares>
                <transactionPricePerShare>
                    <value>88.63</value>
                    <footnoteId id="F2"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>103670</value>
                    <footnoteId id="F3"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Class A Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2024-03-10</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>F</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>322</value>
                    <footnoteId id="F1"/>
                </transactionShares>
                <transactionPricePerShare>
                    <value>88.63</value>
                    <footnoteId id="F2"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>103348</value>
                    <footnoteId id="F3"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeHolding>
            <securityTitle>
                <value>Class A Common Stock</value>
            </securityTitle>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>311008</value>
                    <footnoteId id="F4"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>By trust</value>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeHolding>
        <nonDerivativeHolding>
            <securityTitle>
                <value>Class A Common Stock</value>
            </securityTitle>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>126462</value>
                    <footnoteId id="F5"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>By trust</value>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeHolding>
        <nonDerivativeHolding>
            <securityTitle>
                <value>Class A Common Stock</value>
            </securityTitle>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>11861</value>
                    <footnoteId id="F6"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>By trust</value>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeHolding>
    </nonDerivativeTable>

    <footnotes>
        <footnote id="F1">These shares were tax-withheld by the issuer to satisfy the reporting person's tax obligation resulting from the vesting of a previously reported grant of shares pursuant to Rule 16b-3(d).</footnote>
        <footnote id="F2">Per share value assigned by the issuer to the tax withholding shares under the tax withholding arrangement, and based on the market closing price of the shares on March 8, 2024.</footnote>
        <footnote id="F3">Includes 5,123 shares issued pursuant to the issuer's Employee Share Purchase Plan, which number of shares reflects the acquisition of a total of 14 shares under the issuer's Employee Share Purchase Plan since March 14, 2023. Also includes 773 shares distributed to the reporting person by The Noordhoek Charitable Remainder Unitrust I on December 29, 2023 as discussed in footnote (6) below.</footnote>
        <footnote id="F4">Shares held by The Jeffrey R. Noordhoek Amended and Restated Revocable Trust, dated August 9, 2016, which is a revocable trust with respect to which the reporting person is the trustee and settlor, and the reporting person, his spouse and children are beneficiaries.</footnote>
        <footnote id="F5">Shares held by the Jeffrey Noordhoek Post Annuity Irrevocable Trust dated August 29, 2003, of which the reporting person's spouse and children are initial beneficiaries. The reporting person continues to report beneficial ownership of all the shares held by the trust, but disclaims beneficial ownership of the shares held by the trust except to the extent of his pecuniary interest therein.</footnote>
        <footnote id="F6">Shares held by The Noordhoek Charitable Remainder Unitrust I (of which the reporting person is the sole noncharitable beneficiary), which reflect an annual distribution and transfer from the trust to the reporting person of 773 shares on December 29, 2023. The reporting person continues to report beneficial ownership of all the shares held by the trust, but disclaims beneficial ownership of the shares held by the trust except to the extent of his pecuniary interest therein.</footnote>
    </footnotes>

    <ownerSignature>
        <signatureName>/s/ Audra Hoffschneider, Attorney-in-Fact for Jeffrey R. Noordhoek</signatureName>
        <signatureDate>2024-03-12</signatureDate>
    </ownerSignature>
</ownershipDocument>
