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

    <schemaVersion>X0508</schemaVersion>

    <documentType>4</documentType>

    <periodOfReport>2023-11-10</periodOfReport>

    <notSubjectToSection16>true</notSubjectToSection16>

    <issuer>
        <issuerCik>0001865174</issuerCik>
        <issuerName>Goldman Sachs Middle Market Lending Corp. II</issuerName>
        <issuerTradingSymbol>NONE</issuerTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001806913</rptOwnerCik>
            <rptOwnerName>Pessah David</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>200 WEST STREET</rptOwnerStreet1>
            <rptOwnerStreet2></rptOwnerStreet2>
            <rptOwnerCity>NEW YORK</rptOwnerCity>
            <rptOwnerState>NY</rptOwnerState>
            <rptOwnerZipCode>10282</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isOfficer>true</isOfficer>
            <officerTitle>See Remarks</officerTitle>
        </reportingOwnerRelationship>
    </reportingOwner>

    <aff10b5One>false</aff10b5One>

    <remarks>Effective at the close of business on November 10, 2023, the reporting person no longer serves as Chief Financial Officer, Treasurer and Principal Accounting Officer of Goldman Sachs Middle Market Lending Corp. II.</remarks>

    <ownerSignature>
        <signatureName>/s/ Edward Meehan, Attorney-in-fact</signatureName>
        <signatureDate>2023-11-16</signatureDate>
    </ownerSignature>
</ownershipDocument>
