EX-5.1 2 a51opinionq22025.htm EX-5.1 Document

Exhibit 5.1
June 23, 2025
X4 Pharmaceuticals, Inc.
61 North Beacon Street, 4th Floor
Boston, Massachusetts 02134

Re: Securities Registered under Registration Statement on Form S-3

We have acted as counsel to X4 Pharmaceuticals, Inc., a Delaware corporation (the “Company”) in connection with the prospectus supplement (the “Prospectus Supplement”) filed on June 23, 2025 by the Company with the Securities and Exchange Commission (the “Commission”) pursuant to Rule 424 under the Securities Act of 1933, as amended (the “Securities Act”). The Prospectus Supplement relates to the offering by the Company of (i) 137,099 shares (the “Commitment Shares”) of the Company’s common stock, par value $0.001, of the Company (the “Common Stock”) and (ii) subject to certain conditions, up to $40,000,000 in shares of Common Stock (the “Purchase Shares” and, together with the Commitment Shares, the “Shares”), in each case covered by the Registration Statement on Form S-3 (File No. 333-273961) (as amended or supplemented, the “Registration Statement”) filed on August 14, 2023 with the Commission pursuant to the Securities Act relating to the registration of the offer by the Company of up to $300,000,000 of any combination of securities of the types specified therein. The Registration Statement was declared effective by the Commission on August 24, 2023. We are delivering this supplemental opinion letter in connection with the filing of the Prospectus Supplement. The Shares are being sold to Lincoln Park Capital Fund, LLC (the “Purchaser”) pursuant to a Purchase Agreement entered into between the Company and the Purchaser on June 23, 2025 (the “Purchase Agreement”).

We have reviewed such documents and made such examination of law as we have deemed appropriate to give the opinion set forth below. We have relied, without independent verification, on certificates of public officials and, as to matters of fact material to the opinion set forth below, on a certificate of an officer of the Company.

For purposes of our opinions set forth below, we have assumed that the following requirements (the “Approval and Issuance Requirements”) are satisfied with respect to each issuance and sale of Purchase Shares: (i) approval of required notices to be delivered by the Company pursuant to the Purchase Agreement by the Company’s board of directors (including a duly authorized committee thereof, the “Board of Directors”) or other person or body to which the Board of Directors has delegated the authority to approve such notices delivered by the Company pursuant to the Purchase Agreement (an “Authorized Person”), and (ii) that Purchase Shares are issued and sold (w) in accordance with the Purchase Agreement, (x) for a price per share equal to or greater than the minimum price (which price is no less than the par value per share of the Common Stock) of the Purchase Shares authorized by Board of Directors or an Authorized Person prior to the date of issuance (the “Minimum Price”), (y) within the time period during which Purchase Shares may be issued authorized by Board of Directors and (z) in accordance with any conditions imposed by the Board of Directors or an Authorized Person on the issuance and sale of Purchase Shares by the Company. For purposes of our opinions set forth below, we have also assumed that, when any Purchase Shares are issued, the total number of those Shares, together with the number of shares of Common Stock issued, subscribed for, or otherwise committed to be issued, does not exceed the number of shares of Common Stock authorized by the Certificate of Incorporation..

The opinions set forth below is limited to the Delaware General Corporation Law.

Based on the foregoing, and subject to the additional qualifications set forth below, we are of the opinion that:




1.The Commitment Shares have been duly authorized and, when delivered by the Company in accordance with the Purchase Agreement, will be validly issued, fully paid and nonassessable.

2.The Purchase Shares, when authorized, paid for and delivered in accordance with the Purchase Agreement and the Approval and Issuance Requirements, will be duly authorized, validly issued, fully paid and nonassessable.

This opinion letter and the opinion it contains shall be interpreted in accordance with the Core Opinion Principles as published in 74 Business Lawyer 815 (Summer 2019).

We hereby consent to the inclusion of this opinion as Exhibit 5.1 to the Company’s Current Report on Form 8-K relating to the Registration Statement and the Purchase Agreement and to the references to our firm under the caption “Legal Matters” in the Registration Statement. In giving our consent, we do not admit that we are in the category of persons whose consent is required under Section 7 of the Securities Act or the rules and regulations thereunder.


Very truly yours,

/s/ Goodwin Procter LLP

GOODWIN PROCTER LLP