EXHIBIT 23 CONSENT OF INDEPENDENT REGISTERED PUBLIC ACCOUNTING FIRM The Board of Directors Sterling Bancorp: We consent to the incorporation by reference in the Registration Statements on Form S-8 (No. 333-97009) and Form S-3 (No. 333-82296) of Sterling Bancorp of our report dated March 29, 2005, with respect to the consolidated balance sheets of Sterling Bancorp and subsidiaries as of December 31, 2004 and 2003, and the related consolidated statements of income, comprehensive income, changes in shareholders' equity, and cash flows for each of the years in the three-year period ended December 31, 2004, and the consolidated statements of condition of Sterling National Bank and subsidiaries as of December 31, 2004 and 2003, and our report dated April 28, 2005 with respect to management's assessment of the effectiveness of internal control over financial reporting as of December 31, 2004 and the effectiveness of internal control over financial reporting as of December 31, 2004, which reports appear in the December 31, 2004 annual report on Form 10-K, as amended by Amendment No. 1 on Form 10-K/A, of Sterling Bancorp. Our report dated April 28, 2005, on management's assessment of the effectiveness of internal control over financial reporting and the effectiveness of internal control over financial reporting as of December 31, 2004, expresses our opinion that Sterling Bancorp did not maintain effective internal control over financial reporting as of December 31, 2004, because of the effect of a material weakness on the achievement of the objectives of the control criteria and contains an explanatory paragraph that states that the Company did not employ sufficient personnel with adequate technical skills relative to accounting for Company-owned split-dollar life insurance policies on the lives of certain officers of the Company. Our March 29, 2005 report refers to the restatement of the Company's 2003 and 2002 consolidated financial statements, as more fully described in Note 2 to the consolidated financial statements. /s/ KPMG LLP New York, New York April 28, 2005 PAGE 8