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

    <schemaVersion>X0609</schemaVersion>

    <documentType>4/A</documentType>

    <periodOfReport>2026-02-27</periodOfReport>

    <dateOfOriginalSubmission>2026-03-03</dateOfOriginalSubmission>

    <issuer>
        <issuerCik>0001056943</issuerCik>
        <issuerName>PEOPLES FINANCIAL SERVICES CORP.</issuerName>
        <issuerTradingSymbol>PFIS</issuerTradingSymbol>
        <issuerForeignTradingSymbol></issuerForeignTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001491833</rptOwnerCik>
            <rptOwnerName>TULANEY THOMAS P</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerNonUSAddressFlag>false</rptOwnerNonUSAddressFlag>
            <rptOwnerStreet1>C/O PEOPLES SECURITY BANK &amp; TRUST CO</rptOwnerStreet1>
            <rptOwnerStreet2>30 E D PREATE DRIVE</rptOwnerStreet2>
            <rptOwnerCity>MOOSIC</rptOwnerCity>
            <rptOwnerState>PA</rptOwnerState>
            <rptOwnerZipCode>18507</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isOfficer>1</isOfficer>
            <officerTitle>PRESIDENT</officerTitle>
        </reportingOwnerRelationship>
    </reportingOwner>

    <aff10b5One>0</aff10b5One>

    <nonDerivativeTable>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2026-02-27</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>A</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>1880</value>
                    <footnoteId id="F2"/>
                </transactionShares>
                <transactionPricePerShare>
                    <value>0</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>A</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>22369</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2026-02-27</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>F</transactionCode>
                <equitySwapInvolved>0</equitySwapInvolved>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>633</value>
                    <footnoteId id="F2"/>
                </transactionShares>
                <transactionPricePerShare>
                    <value>53.60</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>21736</value>
                    <footnoteId id="F1"/>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeHolding>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>19519.4883</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>I</value>
                </directOrIndirectOwnership>
                <natureOfOwnership>
                    <value>By IRA</value>
                </natureOfOwnership>
            </ownershipNature>
        </nonDerivativeHolding>
    </nonDerivativeTable>

    <derivativeTable>
        <derivativeHolding>
            <securityTitle>
                <value>Restricted Stock Unit</value>
            </securityTitle>
            <conversionOrExercisePrice>
                <footnoteId id="F3"/>
            </conversionOrExercisePrice>
            <exerciseDate>
                <footnoteId id="F4"/>
            </exerciseDate>
            <expirationDate>
                <footnoteId id="F4"/>
            </expirationDate>
            <underlyingSecurity>
                <underlyingSecurityTitle>
                    <value>Common Stock</value>
                </underlyingSecurityTitle>
                <underlyingSecurityShares>
                    <value>1075</value>
                </underlyingSecurityShares>
            </underlyingSecurity>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>1075</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </derivativeHolding>
    </derivativeTable>

    <footnotes>
        <footnote id="F1">This amount includes 607 shares of time based restricted common stock solely owned by Mr. Tulaney and 21,129 shares held jointly with his spouse.  This amended Form 4 corrects the amounts erroneously reported on Mr. Tulaney's Form 4 filed March 3, 2026.</footnote>
        <footnote id="F2">On March 3, 2026, the reporting person filed a Form 4 which inadvertently reported the vesting of 2,818 performance based stock awards and 1,121 shares withheld for taxes. As reported in this amendment, 1,880 performance based stock awards vested and 633 shares were withheld for taxes.</footnote>
        <footnote id="F3">Each restricted stock unit represents a contingent right to receive one share of PFIS common stock.</footnote>
        <footnote id="F4">The restricted stock units vest in three equal annual installments beginning March 11, 2026.</footnote>
    </footnotes>

    <ownerSignature>
        <signatureName>/s/ Stephanie A. Westington, CPA, As Attorney in Fact for Thomas P. Tulaney</signatureName>
        <signatureDate>2026-04-07</signatureDate>
    </ownerSignature>
</ownershipDocument>
