HARTFORD, Conn. — Three of the nation’s leading credit rating firms will give Connecticut a $900,000 discount on future services to settle claims that they gave artificially low credit ratings to its cities and towns, the state’s attorney general said Friday.

State officials who filed the lawsuits against Moody’s Investors Service Inc., Standard & Poor’s, and Fitch Inc. in July 2008 alleged the low ratings ultimately cost taxpayers millions of dollars in unnecessary insurance and higher interest payments.

The office of Attorney General George Jepsen said the rating agencies denied violating any laws but agreed to the settlements to avoid litigation.

Spokespersons for the agencies said they were pleased to have the issue resolved.

The suits alleged the agencies established a dual ratings system that gave lower credit ratings to bonds issued by states, municipalities and other public entities than corporate debt, even though the agencies’ own studies found public bonds were more likely to be paid back.