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

    <schemaVersion>X0305</schemaVersion>

    <documentType>4</documentType>

    <periodOfReport>2012-04-19</periodOfReport>

    <notSubjectToSection16>0</notSubjectToSection16>

    <issuer>
        <issuerCik>0001158324</issuerCik>
        <issuerName>COGENT COMMUNICATIONS GROUP INC</issuerName>
        <issuerTradingSymbol>CCOI</issuerTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001166979</rptOwnerCik>
            <rptOwnerName>BEURY ROBERT N JR</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>1015 31ST ST., NW</rptOwnerStreet1>
            <rptOwnerStreet2></rptOwnerStreet2>
            <rptOwnerCity>WASHINGTON</rptOwnerCity>
            <rptOwnerState>DC</rptOwnerState>
            <rptOwnerZipCode>20007</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>0</isDirector>
            <isOfficer>1</isOfficer>
            <isTenPercentOwner>0</isTenPercentOwner>
            <isOther>0</isOther>
            <officerTitle>VP &amp; Chief Legal Officer</officerTitle>
            <otherText></otherText>
        </reportingOwnerRelationship>
    </reportingOwner>

    <nonDerivativeTable>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>common stock</value>
            </securityTitle>
            <transactionDate>
                <value>2012-04-19</value>
                <footnoteId id="F1"/>
            </transactionDate>
            <deemedExecutionDate></deemedExecutionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>A</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>48000</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>0</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>A</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>75340</value>
                    <footnoteId id="F2"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
    </nonDerivativeTable>

    <derivativeTable></derivativeTable>

    <footnotes>
        <footnote id="F1">On April 19, 2012 the board of directors made an award of 48,000 shares of restricted stock to Mr. Beury. A block of 5,000 shares will vest on May 1, 2013 and 1,000 shares will vest on the first day of each month thereafter until fully vested on December 1, 2016.  The stock will fully vest on an earlier date if a change of control occurs.</footnote>
        <footnote id="F2">A portion of these securities is not vested.</footnote>
    </footnotes>

    <remarks></remarks>

    <ownerSignature>
        <signatureName>Robert N. Beury, Jr.</signatureName>
        <signatureDate>2012-04-20</signatureDate>
    </ownerSignature>
</ownershipDocument>
