EX-23.1 3 a2163739zex-23_1.htm EXHIBIT 23.1
QuickLinks -- Click here to rapidly navigate through this document

Exhibit 23.1


Consent Of Independent Registered Public Accounting Firm

        We hereby consent to the reference to our firm under the caption "Experts" in this Amendment No. 1 to Registration Statement No. 333-39341 of Mid Penn Bancorp, Inc., filed with the Securities and Exchange Commission on Form S-3, relating to the registration of securities issuable under the terms of the Mid Penn Bancorp, Inc. Amended and Restated Dividend Reinvestment Plan. We also consent to the incorporation by reference therein of our reports dated February 9, 2005, with respect to the consolidated financial statements of Mid Penn Bancorp, Inc. and subsidiaries and management's assessment of the effectiveness of internal controls over financial reporting as of December 31, 2004, which reports are included in Mid Penn Bancorp, Inc.'s Annual Report on Form 10-K for the year ended December 31, 2004, filed with the Securities and Exchange Commission. Our report on management's assessment of the effectiveness of internal control over financial reporting as of December 31, 2004, expressed an unqualified opinion on management's assessment of internal control over financial reporting and an adverse opinion on the effectiveness of internal control over financial reporting.

/s/ Parente Randolph, LLC

Williamsport, Pennsylvania
October 5, 2005




QuickLinks

Consent Of Independent Registered Public Accounting Firm