Exhibit 23.1
Consent of Independent Registered Public Accounting Firm
We consent to the incorporation by reference in the following Registration Statements:
| (1) | Registration Statements (Form S-3 Nos. 333-258723 and 333-281335) of Generation Bio Co., | 
| (2) | Registration Statements (Form S-8 Nos. 333-254429, 333-262980, 333-269203, 333-277704 and 333-284123) pertaining to the 2020 Stock Incentive Plan and 2020 Employee Stock Purchase Plan of Generation Bio Co., and | 
| (3) | Registration Statement (Form S-8 No. 333-239116) pertaining to the 2017 Stock Incentive Plan, 2020 Stock Incentive Plan, and 2020 Employee Stock Purchase Plan of Generation Bio Co.; | 
of our report dated March 13, 2025, with respect to the consolidated financial statements of Generation Bio Co. included in this Annual Report (Form 10-K) of Generation Bio Co. for the year ended December 31, 2024.
/s/ Ernst & Young LLP
Boston, Massachusetts
March 13, 2025
|  |  |  |