| | | | | | | | |
| | EXHIBIT 5.1
Wilson Sonsini Goodrich & Rosati Professional Corporation 650 Page Mill Road Palo Alto, California 94304-1050 o: 650.493.9300 f: 650.493.6811 |
June 23, 2026
C3.ai, Inc.
1400 Seaport Blvd
Redwood City, CA 94063
Re: Registration Statement on Form S-8
Ladies and Gentlemen:
We have examined the Registration Statement on Form S-8 (the “Registration Statement”) to be filed by C3.ai, Inc., a Delaware corporation, with the Securities and Exchange Commission on or about the date hereof, in connection with the registration under the Securities Act of 1933, as amended, of an aggregate of 11,840,581 shares of its Class A common stock, par value $0.001 per share (the “Shares”), consisting of: (i) 10,360,509 shares of Class A common stock reserved for issuance under the C3.ai, Inc. 2020 Equity Incentive Plan, as amended (the “Incentive Plan”) and (ii) 1,480,072 shares of Class A common stock reserved for issuance under the C3.ai, Inc. 2020 Employee Stock Purchase Plan (together with the Incentive Plan, the “Plans”).
It is our opinion that the Shares, when issued and sold in the manner referred to in the Plans and pursuant to the agreements that accompany the Plans, will be legally and 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 the use of our name wherever appearing in the Registration Statement and any amendments thereto.
Very truly yours,
/s/ Wilson Sonsini Goodrich & Rosati, P.C.
WILSON SONSINI GOODRICH & ROSATI
Professional Corporation
AUSTIN BOSTON BOULDER BRUSSELS CENTURY CITY HONG KONG LONDON LOS ANGELES NEW YORK
PALO ALTO SALT LAKE CITY SAN DIEGO SAN FRANCISCO SEATTLE SHANGHAI WASHINGTON, DC WILMINGTON, DE