1 Exhibit 23.1 CONSENT OF INDEPENDENT REGISTERED PUBLIC ACCOUNTING FIRM We consent to the incorporation by reference in Registration Statement on Form S-3 of Pyramid Oil Company of our report dated March 31, 2010, except for Note 2 dated September 10, 2010, relating to our audit of the financial statements which is incorporated in this Annual Report on Form 10-K/A of Pyramid Oil Company for the year ended December 31, 2009. SingerLewak LLP Los Angeles, California September 10, 2010