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

    <schemaVersion>X0306</schemaVersion>

    <documentType>4</documentType>

    <periodOfReport>2020-11-12</periodOfReport>

    <notSubjectToSection16>0</notSubjectToSection16>

    <issuer>
        <issuerCik>0000731012</issuerCik>
        <issuerName>HEALTHCARE SERVICES GROUP INC</issuerName>
        <issuerTradingSymbol>HCSG</issuerTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001521830</rptOwnerCik>
            <rptOwnerName>McBryan Michael E</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>3220 TILLMAN DRIVE</rptOwnerStreet1>
            <rptOwnerStreet2>SUITE 300</rptOwnerStreet2>
            <rptOwnerCity>BENSALEM</rptOwnerCity>
            <rptOwnerState>PA</rptOwnerState>
            <rptOwnerZipCode>19020</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>0</isDirector>
            <isOfficer>1</isOfficer>
            <isTenPercentOwner>0</isTenPercentOwner>
            <isOther>0</isOther>
            <officerTitle>EVP &amp; Chief Revenue Officer</officerTitle>
            <otherText></otherText>
        </reportingOwnerRelationship>
    </reportingOwner>

    <nonDerivativeTable>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2020-11-12</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>M</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>15000</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>16.11</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>A</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>39328</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2020-11-12</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>S</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>15000</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>23.60</value>
                    <footnoteId id="F1"/>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>24328</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
    </nonDerivativeTable>

    <derivativeTable>
        <derivativeTransaction>
            <securityTitle>
                <value>Stock Option (right to buy)</value>
            </securityTitle>
            <conversionOrExercisePrice>
                <value>16.11</value>
            </conversionOrExercisePrice>
            <transactionDate>
                <value>2020-11-12</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>M</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>15000</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>0</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <exerciseDate>
                <footnoteId id="F2"/>
            </exerciseDate>
            <expirationDate>
                <value>2021-01-06</value>
            </expirationDate>
            <underlyingSecurity>
                <underlyingSecurityTitle>
                    <value>Common Stock</value>
                </underlyingSecurityTitle>
                <underlyingSecurityShares>
                    <value>15000.0</value>
                </underlyingSecurityShares>
            </underlyingSecurity>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>0</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </derivativeTransaction>
    </derivativeTable>

    <footnotes>
        <footnote id="F1">This transaction was executed in multiple trades at prices ranging from $22.99 to $24.53. The price reported above reflects the weighted average sale price. The reporting person hereby undertakes to provide upon request to the SEC staff, Healthcare Services Group, Inc. or any security holder of Healthcare Services Group, Inc. full information regarding the number of shares and prices at which the transaction was effected.</footnote>
        <footnote id="F2">These options shall vest and become exercisable at the rate of 20% annually, commencing on the first anniversary of the January 6, 2011 grant date.</footnote>
    </footnotes>

    <remarks></remarks>

    <ownerSignature>
        <signatureName>/s/ John C. Shea</signatureName>
        <signatureDate>2020-11-16</signatureDate>
    </ownerSignature>
</ownershipDocument>
[{"type": "4", "sequence": "1", "filename": "wf-form4_160556480324259.xml", "description": "FORM 4", "secsgml_size_bytes": 7121}]
X0306
4
2020-11-12
0
0000731012
HEALTHCARE SERVICES GROUP INC
HCSG
0001521830
McBryan Michael E
3220 TILLMAN DRIVE
SUITE 300
BENSALEM
PA
19020
0
1
0
0
EVP & Chief Revenue Officer
Common Stock
2020-11-12
4
M
0
15000
16.11
A
39328
D
Common Stock
2020-11-12
4
S
0
15000
23.60
D
24328
D
Stock Option (right to buy)
16.11
2020-11-12
4
M
0
15000
0
D
2021-01-06
Common Stock
15000.0
0
D
This transaction was executed in multiple trades at prices ranging from $22.99 to $24.53. The price reported above reflects the weighted average sale price. The reporting person hereby undertakes to provide upon request to the SEC staff, Healthcare Services Group, Inc. or any security holder of Healthcare Services Group, Inc. full information regarding the number of shares and prices at which the transaction was effected.
These options shall vest and become exercisable at the rate of 20% annually, commencing on the first anniversary of the January 6, 2011 grant date.
/s/ John C. Shea
2020-11-16