Exhibit 23.1

Consent of Ernst & Young LLP, Independent Registered Public Accounting Firm

We consent to the reference to our firm under the caption “Experts” and to the use of our report dated September 6, 2023, with respect to the financial statements of Lenz Therapeutics, Inc. included in Amendment No. 3 to the Registration Statement (Form S-4/A No. 333-275919) and related proxy statement/prospectus of Graphite Bio, Inc. dated February 9, 2024, for the registration of shares of its common stock.

/s/ Ernst & Young LLP

San Diego, California

February 9, 2024