<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2026"
  xmlns:link="http://www.xbrl.org/2003/linkbase"
  xmlns:xbrldi="http://xbrl.org/2006/xbrldi"
  xmlns:xlink="http://www.w3.org/1999/xlink">
    <link:schemaRef xlink:href="oxlc-20261023.xsd" xlink:type="simple"/>
    <context id="c0">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0001495222</identifier>
        </entity>
        <period>
            <startDate>2026-10-23</startDate>
            <endDate>2026-10-23</endDate>
        </period>
    </context>
    <context id="c1">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0001495222</identifier>
            <segment>
                <xbrldi:explicitMember dimension="dei:EntityAddressesAddressTypeAxis">dei:BusinessContactMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2026-10-23</startDate>
            <endDate>2026-10-23</endDate>
        </period>
    </context>
    <dei:EntityRegistrantName contextRef="c0" id="ixv-1401">OXFORD LANE CAPITAL CORP.</dei:EntityRegistrantName>
    <dei:EntityAddressAddressLine1 contextRef="c0" id="ixv-1402">8 Sound Shore Drive</dei:EntityAddressAddressLine1>
    <dei:EntityAddressAddressLine2 contextRef="c0" id="ixv-1403">Suite 255</dei:EntityAddressAddressLine2>
    <dei:EntityAddressCityOrTown contextRef="c0" id="ixv-1404">Greenwich</dei:EntityAddressCityOrTown>
    <dei:EntityAddressStateOrProvince contextRef="c0" id="ixv-1405">CT</dei:EntityAddressStateOrProvince>
    <dei:EntityAddressPostalZipCode contextRef="c0" id="ixv-1406">06830</dei:EntityAddressPostalZipCode>
    <dei:CityAreaCode contextRef="c0" id="ixv-1407">(203)</dei:CityAreaCode>
    <dei:LocalPhoneNumber contextRef="c0" id="ixv-1408">983-5275</dei:LocalPhoneNumber>
    <dei:ContactPersonnelName contextRef="c1" id="ixv-1409">Jonathan H. Cohen</dei:ContactPersonnelName>
    <dei:EntityAddressAddressLine1 contextRef="c1" id="ixv-1410">8 Sound Shore Drive</dei:EntityAddressAddressLine1>
    <dei:EntityAddressAddressLine2 contextRef="c1" id="ixv-1411">Suite 255</dei:EntityAddressAddressLine2>
    <dei:EntityAddressCityOrTown contextRef="c1" id="ixv-1412">Greenwich</dei:EntityAddressCityOrTown>
    <dei:EntityAddressStateOrProvince contextRef="c1" id="ixv-1413">CT</dei:EntityAddressStateOrProvince>
    <dei:EntityAddressPostalZipCode contextRef="c1" id="ixv-1414">06830</dei:EntityAddressPostalZipCode>
    <dei:NoSubstantiveChanges462c contextRef="c0" id="ixv-207">false</dei:NoSubstantiveChanges462c>
    <dei:ExhibitsOnly462d contextRef="c0" id="ixv-215">true</dei:ExhibitsOnly462d>
    <dei:EntityEmergingGrowthCompany contextRef="c0" id="ixv-265">false</dei:EntityEmergingGrowthCompany>
    <dei:AmendmentDescription contextRef="c0" id="ixv-1415">This Post-Effective Amendment No. 4 to the Registration
Statement on Form N-2 (File Nos. 333-283109 and 811-22432) of Oxford Lane Capital Corp. (the &#x201c;Registration Statement&#x201d;) is
being filed pursuant to Rule 462(d) under the Securities Act of 1933, as amended (the &#x201c;Securities Act&#x201d;), solely for the purpose
of filing exhibits to the Registration Statement. Accordingly, this Post-Effective Amendment No. 4 consists only of a facing page, this
explanatory note and Part C of the Registration Statement on Form N-2 setting forth the exhibits to the Registration Statement. This Post-Effective
Amendment No. 4 does not modify any other part of the Registration Statement. Pursuant to Rule 462(d) under the Securities Act, this Post-Effective
Amendment No. 4 shall become effective immediately upon filing with the Securities and Exchange Commission. The contents of the Registration
Statement are hereby incorporated by reference.</dei:AmendmentDescription>
    <dei:DocumentType contextRef="c0" id="hidden-fact-0">POS EX</dei:DocumentType>
    <dei:EntityWellKnownSeasonedIssuer contextRef="c0" id="hidden-fact-1">Yes</dei:EntityWellKnownSeasonedIssuer>
    <dei:EntityCentralIndexKey contextRef="c0" id="ixv-1420">0001495222</dei:EntityCentralIndexKey>
    <dei:AmendmentFlag contextRef="c0" id="ixv-1421">true</dei:AmendmentFlag>
</xbrl>
