EXHIBIT 23.1 CONSENT OF ERNST & YOUNG LLP, INDEPENDENT AUDITORS We consent to the incorporation by reference in the Registration Statement on Form S-3 (No. 333-49285) and the Registration Statements on Forms S-8 (No. 333-84113, No. 333-04839 and No. 333-34681) pertaining to the 1996 Employee Stock Purchase Plan, the 1996 Non-Employee Directors' Stock Option Plan and the 1996 Equity Incentive Plan of Onyx Pharmaceuticals, Inc. of our report dated February 18, 2000, with respect to the financial statements of Onyx Pharmaceuticals, Inc. included in this Annual Report (Form 10-K) for the year ended December 31, 1999. /s/ERNST & YOUNG LLP Palo Alto, California March 27, 2000