EXHIBIT 5.1 May 7, 1999 AdForce, Inc. 10590 North Tantau Avenue Cupertino, California 95014 Gentlemen/Ladies: At your request, we have examined the Registration Statement on Form S-8 (the "REGISTRATION STATEMENT") to be filed by you with the Securities and Exchange Commission (the "COMMISSION") on or about May 7, 1999 in connection with the registration under the Securities Act of 1933, as amended, of an aggregate of 5,470,110 shares of your Common Stock (the "STOCK") subject to issuance by you upon the exercise of: (1) options to purchase up to 2,003,989 shares of Stock granted under the Company's 1997 Stock Plan (the "1997 PLAN"); (2) options to purchase 6,598 shares of Stock granted by you under the StarPoint Software, Inc. 1996 Stock Plan (the "STARPOINT PLAN"); (3) options to purchase up to 2,249,523 shares of Stock granted or to be granted under the Company's 1999 Equity Incentive Plan (the "1999 OPTION PLAN"); (4) options to purchase up to 200,000 shares of Stock granted or to be granted under the Company's 1999 Directors Stock Option Plan (the "1999 DIRECTORS PLAN"); (5) purchase rights for up to 300,000 shares of Stock granted or to be granted under the Company's 1999 Employee Stock Purchase Plan (the "1999 PURCHASE PLAN"); and (6) options to purchase up to 710,000 shares of Stock granted pursuant to non-plan option agreements (the "NON-PLAN AGREEMENTS"). The plans referred to in clauses (1) through (6) above are collectively referred to in this letter as the "PLANS." In rendering this opinion, we have examined the following: (1) your registration statement on Form S-1 (File No. 333-73231) filed with, and declared effective by, the Commission on May 7, 1999, together with the Exhibits filed as a part thereof, including without limitation, each of the Plans and related stock option grant or purchase and exercise agreements; (2) your registration statement on Form 8-A (File No. 000-25497), filed with the Commission on May 4, 1999, together with the order of effectiveness issued by the Commission therefor on May 7, 1999; (3) the Registration Statement, together with the Exhibits filed as a part thereof; (4) the Prospectuses prepared in connection with the Registration Statement; (5) the minutes of meetings and actions by written consent of the stockholders and Board of Directors that are contained in your minute books and the minute books of your predecessor, Imgis, Inc., a California corporation ("IMGIS CALIFORNIA"), that are in our possession; AdForce, Inc. May 7, 1999 Page 2 (6) the stock records that you have provided to us (consisting of a list of stockholders of even date herewith and a list of option and warrant holders of even date herewith respecting your capital and of any rights to purchase capital stock, which you have represented to us are true and complete as of their dates); and (7) a Management Certificate addressed to us and dated of even date herewith executed by the Company containing certain factual and other representations. We have also confirmed the continued effectiveness of your registration under the Securities Exchange Act of 1934, as amended, by telephone call to the offices of the Commission and have confirmed your eligibility to use Form S-8. In our examination of documents for purposes of this opinion, we have assumed, and express no opinion as to, the genuineness of all signatures on original documents, the authenticity of all documents submitted to us as originals, the conformity to originals of all documents submitted to us as copies, the legal capacity of all natural persons executing the same, the lack of any undisclosed terminations, modifications, waivers or amendments to any documents reviewed by us and the due authorization, execution and delivery of all documents where due authorization, execution and delivery are prerequisites to the effectiveness thereof. As to matters of fact relevant to this opinion, we have relied solely upon our examination of the documents referred to above and have assumed the current accuracy and completeness of the information obtained from public officials and records referred to above. We have made no independent investigation or other attempt to verify the accuracy of any of such information or to determine the existence or non-existence of any other factual matters; HOWEVER, we are not aware of any facts that would cause us to believe that the opinion expressed herein is not accurate. We are admitted to practice law in the State of California, and we express no opinion herein with respect to the application or effect of the laws of any jurisdiction other than the existing laws of the United States of America and the State of California and (without reference to case law or secondary sources) the existing Delaware General Corporation Law. In connection with our opinion expressed below, we have assumed that, at or prior to the time of the delivery of any shares of Stock, the Registration Statement will have become effective under the Securities Act of 1933, as amended, that the registration will apply to such shares of Stock and will not have been modified or rescinded and that there will not have occurred any change in law affecting the validity or enforceability of such shares of Stock. Based upon the foregoing, it is our opinion that the 5,470,110 shares of Stock that may be issued and sold by you upon the exercise of: (1) stock options granted under the 1997 Plan; (2) stock options granted under the StarPoint Plan; (3) stock options granted or to be granted under the 1999 Option Plan; (4) stock options granted or to be granted under the 1999 Directors AdForce, Inc. May 7, 1999 Page 3 Plan; (5) purchase rights granted or to be granted under the 1999 Purchase Plan; and (6) stock options granted under Non-Plan Agreements, when issued and sold in accordance with the applicable plan and stock option grant and exercise agreements or stock purchase agreements entered into or to be entered into thereunder, and in the manner referred to in the relevant Prospectus associated with the Registration Statement, will be validly issued, fully paid and nonassessable. We consent to the use of this opinion as an exhibit to the Registration Statement and further consent to all references to us, if any, in the Registration Statement, the Prospectus constituting a part thereof and any amendments thereto. This opinion speaks only as of its date and we assume no obligation to update this opinion should circumstances change after the date hereof. This opinion is intended solely for the your use as an exhibit to the Registration Statement for the purpose of the above sale of the Stock and is not to be relied upon for any other purpose. Very truly yours, /s/ FENWICK & WEST LLP