1 Exhibit 5 & 23(a) [CMS ENERGY CORPORATION LETTERHEAD] MICHAEL D. VAN HEMERT, ESQ. ASSISTANT GENERAL COUNSEL April 7, 1999 CMS Energy Corporation Fairlane Plaza South, Suite 1100 330 Town Center Drive Dearborn, MI 48126 Ladies and Gentlemen: I am the Assistant General Counsel of CMS Energy Corporation, a Michigan corporation (the "Company"), and have acted as such in connection with the Registration Statement on Form S-3 (the "Registration Statement") being filed by the Company with the Securities and Exchange Commission (the "Commission") under the Securities Act of 1933, as amended (the "Securities Act") relating to the registration of $375,000,000 aggregate principal amount of unsecured senior or subordinated debt securities (the "Debt Securities"). Capitalized terms not otherwise defined herein have the respective meanings specified in the Registration Statement. In rendering this opinion, I have examined and relied upon a copy of the Registration Statement. I have also examined, or have arranged for the examination by an attorney or attorneys under my general supervision, originals, or copies of originals certified to my satisfaction, of such agreements, documents, certificates and other statements of governmental officials and other instruments, and have examined such questions of law and have satisfied myself as to such matters of fact, as I have considered relevant and necessary as a basis for this opinion. I have assumed the authenticity of the documents submitted to me as originals, the genuineness of all signatures, the legal capacity of all natural persons and the conformity with the original documents of any copies thereof submitted to me for examination. Based on the foregoing, it is my opinion that: 1. The Company is duly incorporated and validly existing under the laws of the State of Michigan. 2 Page 2 2. The Company has the corporate power and authority to sell the Senior Debt Securities pursuant to the Indenture dated September 15, 1992, as supplemented, between the Company and NBD Bank, as trustee (the "Senior Debt Indenture") and the Subordinated Debt Securities pursuant to the Indenture dated June 1, 1997, as supplemented, between the Company and The Bank of New York, as trustee (the "Subordinated Debt Indenture") (the Senior Debt Indenture and Subordinated Debt Indenture, collectively, the "Indentures"). 3. The Debt Securities will be legally issued and binding obligations of the Company (except to the extent enforceability may be limited by applicable bankruptcy, insolvency, reorganization, moratorium, fraudulent transfer or other similar laws affecting the enforcement of creditors' rights generally and by the effect of general principles of equity, regardless of whether enforceability is considered in a proceeding in equity or at law) when: (i) the Registration Statement, as finally amended (including any necessary post-effective amendments), shall have become effective under the Securities Act and the Indentures (including any necessary supplemental indentures) shall have been qualified under the Trust Indenture Act of 1939, as amended, and duly executed and delivered by the Company and the Trusteess; (ii) an appropriate Prospectus Supplement with respect to the particular Debt Securities then being sold by the Company shall have been filed with the Commission pursuant to Rule 424 under the Securities Act; (iii) the Company's Board of Directors or a duly authorized committee thereof shall have duly adopted final resolutions authorizing the issuance and sale of the Company as contemplated by the Registration Statement and the particular Indenture; and (iv) the supplemental Indenture under which the particular Debt Securities are to be issued has been duly authorized, executed and delivered, and the particular Debt Securities then being sold by the Company shall have been duly executed and authenticated as provided in the particular Indenture and such resolutions, and shall have been duly delivered to the purchasers thereof against payment of the agreed consideration therefor. For purposes of this opinion, I have assumed that there will be no changes in the laws currently applicable to the Company and that such laws will be the only laws applicable to the Company. 3 Page 3 I do not find it necessary for the purposes of this opinion to cover, and accordingly I express no opinion as to, the application of the securities or blue sky laws of the various states to the sale of the Debt Securities. I am a member of the bar of the State of Michigan and I express no opinion as to the laws of any jurisdiction other than the State of Michigan and the federal law of the United States of Michigan. I hereby consent to the filing of this opinion as an exhibit to the Company's Registration Statement on Form S-3 relating to the Debt Securities and to all references to me included in or made a part of the Registration Statement. Very truly yours, /s/ Michael D. Van Hemert Michael D. Van Hemert