The Long Island Lighting Co. agreed Thursday to let the state take over the $5.3 billion Shoreham nuclear plant, which will then be closed without ever producing commercial power because of fears Long Island could never be evacuated in the event of a disaster.

The Shoreham plant will become the first in the nation to be completed and abandoned without producing commercial power under an "agreement in principle" that provides for ownership of the plant to be transferred to a state agency, officials said."The governor has said that Shore-ham will be acquired, closed and decommissioned," said Harold Holzer, spokesman for state economic development director Vincent Tese, the state's chief negotiator in the intense negotiations.

The state agreed to abandon any attempt to take over LILCO, allowing it to continue to operate as a privately owned utility.

The Shoreham plant was opposed by Gov. Mario Cuomo and many Long Island officials who feared it would be impossible to evacuate Long Island in the event of a nuclear emergency.

"Negotiators for both sides have agreed to begin immediately to draft formal documents containing the full terms of this historic agreement," negotiators said in a joint statement early Thursday.

LILCO and state officials said fine points of the agreement will be worked out over the next few days.

The principal terms of the agreement included transferring the troubled nuclear plant to the Long Island Power Authority or another state agency and taking measures to guarantee "adequate and affordable energy to the people of Long Island," the statement said.

In addition, it called for the "issuance of investment-grade ratings by independent rating agencies and the approval of the definitive agreement by the New York State Public Service Commission," it said.

A LILCO spokesman said the investment-grade ratings were sought to restore the utility to financial health but said negotiators had yet to agree on what steps would be taken to make certain the ratings would be issued.

Also pending was agreement on exactly which side was responsible for assuring affordable power on Long Island, said Jim Lois, a LILCO spokesman.

The consensus was announced following tense negotiations that broke off briefly at the midnight deadline for agreement set by Cuomo but resumed shortly thereafter.