The government said in a court filing it was seeking civil money penalties from S&P and McGraw Hill.
"Considerations regarding fees, market share, profits, and relationships with issuers improperly influenced S&P's rating criteria and models," the government said.
Shares of McGraw-Hill plunged 13.8% on Monday after the company said it was expecting the lawsuit, marking their biggest one-day percentage decline since the 1987 stock market crash, according to Reuters data.
The news also caused shares of Moody's Corp, whose Moody's Investors Service unit is S&P's main rival, to slide 10.7%.
It is unclear why regulators may now be focusing on S&P rather than Moody's or Fimalac SA's Fitch Ratings.
More From This Section
S&P, Moody's and Fitch have long faced criticism from investors, politicians and regulators for assigning high ratings to thousands of subprime and other mortgage securities that quickly turned sour.
"This lawsuit is significant because it could augur future government action or, even worse for the agencies, more litigation by investors," said Jeffrey Manns, a law professor at George Washington University in Washington, D.C.
A civil case involves a lower burden of proof than a criminal case would, and could make it easier for investigators to uncover potential "smoking guns" through subpoenas, he added.
The New York Times reported that talks between the Justice Department and S&P broke down last week after the government sought a settlement of more than $1 billion.
No merit to lawsuit, says S&P
S&P said the expected Justice Department lawsuit focuses on its ratings in 2007 of various US collateralized debt obligations.
The rating agency had previously disclosed a probe by the US Securities and Exchange Commission into its ratings for a $1.6 billion CDO known as Delphinus CDO 2007-1. It was not immediately clear whether that CDO is a focus of the case.
"A DOJ lawsuit would be entirely without factual or legal merit," S&P said in a statement. "The DOJ would be wrong in contending that S&P ratings were motivated by commercial considerations and not issued in good faith."
In a variety of lawsuits brought by investors, S&P has maintained that its ratings constitute opinions protected by the free speech clause of the US Constitution.
Justice Department spokeswoman Adora Andy and Moody's spokesman Michael Adler declined to comment. Fitch spokesman Daniel Noonan said, "We are unable to comment on the S&P matter as it does not involve us, other than to say we have no reason to believe Fitch is a target of any such action."
Several state attorney generals led by Connecticut's George Jepsen are expected to join the case, said the person familiar with the matter, who was not authorised to speak publicly.
Previous lawsuits from Connecticut and Illinois accused S&P of violating consumer fraud laws by stating its ratings were objective, even though it ignored increasing risks of the securities in order to cater to the investment banks that provided the firm with revenue.
A spokeswoman for Jepsen declined to comment. The Wall Street Journal first reported the pending charges.
The attorney general in New York is continuing a separate probe of the rating firm, a person familiar with that inquiry said.
In Monday trading on the New York Stock Exchange, McGraw-Hill shares closed down $8.04 at $50.30, and Moody's shares dropped $5.90 to $49.45.
One potential winner in the news of the pending lawsuit is David Einhorn, who runs the $8 billion hedge fund Greenlight Capital. Einhorn told Reuters in 2010 that he began shorting McGraw-Hill and Moody's in 2007, and had no aversion maintaining those bearish positions in the years to come. Greenlight declined to comment on Monday.
"Key enablers" of meltdown
The ratings agencies have long been scrutinised, in part because they are paid by issuers for ratings, a standard industry practice that has nonetheless raised concern about potential conflicts of interest.
In January 2011, the Financial Crisis Inquiry Commission called the agencies "essential cogs in the wheel of financial destruction" and "key enablers of the financial meltdown."
McGraw-Hill had acknowledged last July that the Justice Department and SEC were probing potential violations by S&P tied to its ratings of structured products, and that it was in talks to try to avert a lawsuit.
Last July, Mizuho Financial Group Inc agreed to a $127.5 million settlement to resolve SEC allegations that a US unit obtained false credit ratings for the Delphinus CDO.
The following month, a Manhattan federal judge refused to dismiss a lawsuit brought by Abu Dhabi Commercial Bank, King County in Washington state, and other investors against S&P, Moody's and Morgan Stanley over losses in Cheyne, a structured investment vehicle.
Cheyne went bankrupt in August 2007. A trial is scheduled to begin on May 6, court records show.
In its statement, S&P said it "deeply regrets" how its CDO ratings failed to anticipate the fast-deteriorating mortgage market conditions, and that it has since spent $400 million to help bolster the quality of its ratings.
"The lawsuit itself may prove less significant than the message it sends," said Manns, the law professor. "Filing a high-profile lawsuit against S&P tells the rating industry at large that the government is serious about holding rating agencies responsible, and that they must be much more careful."
The case is in re: USA vs McGraw Hill Cos and Standard & Poor's, Case No. 13-00779, US District Court, Central District of California.