EX-23 4 l24080aexv23.htm EX-23 EX-23
 

Exhibit 23
Consent of Independent Registered Public Accounting Firm
We consent to the use of our reports dated February 22, 2007, with respect to the consolidated financial statements of United Bankshares, Inc., United Bankshares, Inc. management’s report on internal control over financial reporting, and the effectiveness of internal control over financial reporting of United Bankshares, Inc., included in this Annual Report (Form 10-K) of United Bankshares, Inc. for the year ended December 31, 2006.
We also consent to the incorporation by reference in the Registration Statement (Form S-8 No. 333-138192) pertaining to the 2006 Stock Option Plan of United Bankshares, Inc., Registration Statement (Form S-8 No. 333-106528) pertaining to the 2001 Incentive Stock Option Plan of United Bankshares, Inc., and Registration Statement (Form S-8, No. 333-24241) pertaining to the 1996 Incentive Stock Option Plan of United Bankshares, Inc. of our reports dated February 22, 2007 with respect to the consolidated financial statements of United Bankshares, Inc., United Bankshares, Inc. management’s report on internal control over financial reporting, and the effectiveness of internal control over financial reporting of United Bankshares, Inc., included in the Annual Report (Form 10-K) for the year ended December 31, 2006.
         
     
  /s/ Ernst & Young LLP    
Charleston, WV
February 22, 2007

97