Exhibit 5 January 31, 2006 KeySpan Corporation One MetroTech Center Brooklyn, NY 11201 Ladies and Gentlemen: I am Executive Vice President and General Counsel of KeySpan Corporation, a New York corporation (the "Company"). I have acted in such capacity in connection with the Company's Registration Statement on Form S-3 (the "Registration Statement") filed with the Securities and Exchange Commission under the Securities Act of 1933, as amended, for the registration of 5,000,000 shares of the Company's Common Stock, $0.01 par value per share (the "Common Stock"), issuable pursuant to the KeySpan Investor Program (the "Program"). The Common Stock represents authorized and unissued shares of the Company's Common Stock. Where, in this opinion, I refer to actions I have taken, such references include actions taken by attorneys on my staff and working under my supervision. I have participated in and am familiar with the corporate proceedings of the Company relating to the preparation of the Registration Statement, providing for the registration of the Common Stock for offering and sale on a delayed or continuous basis under the Act and Rule 415 promulgated thereunder. In connection with the foregoing, I have researched such questions of law and examined the originals or copies of the Registration Statement and such corporate records, agreements or other instruments of the Company and other instruments and documents as I have deemed relevant and necessary in connection with the opinions hereinafter expressed. As to various questions of fact material to such opinions, I have, where relevant facts were not independently established by me, relied upon statements of other officers of the Company, whom I believe to be responsible. Based upon the foregoing, and subject to the assumptions, qualifications and limitations set forth herein, it is my opinion that: , the Company has taken all necessary corporate action to authorize the issuance of the Common Stock; , the shares of Common Stock to be issued pursuant to the Program are validly authorized and when issued and delivered in accordance with the terms of the Program, the shares of Common Stock so issued will be validly issued, fully paid and non-assessable. The foregoing opinion is delivered to you in connection with the Registration Statement and may not be relied upon by any other person or for any other purpose. The opinions expressed above are subject to the qualification that I am a member of the Bar of the State of New York and such opinions are limited to the laws of the State of New York, the laws of the United States of America and, to the extent relevant to the opinion expressed above, the Business Corporation Law of the State of New York. I hereby consent to the reference to me under the caption "Legal Opinions" in the Prospectus included in the Registration Statement and to the filing of this opinion as Exhibit 5 to the Registration Statement, as amended. The foregoing, however, shall not constitute an admission by me that I am an expert as provided for in Section 7 and 11 of the Act. I wish to call to your attention to the fact that I am the owner of or have the option to acquire approximately 142,236 shares of our Common Stock of the Company. Very truly yours, /s/ John J. Bishar, Jr.