The wheels just might be falling off for Dov Charney (above) and American Apparel, which looks like it’s careening toward bankruptcy. Photo:

American Apparel is at risk of becoming American history.

The cash-strapped clothing chain warned yesterday that there is “substantial doubt” as to whether it can continue as a “going concern” — accounting jargon that points to a possible bankruptcy filing.

Shares of the racy retailer — whose CEO Dov Charney has stirred controversy for his libertine lifestyle — lost 26 percent of their value yesterday after the company said it may breach a key credit agreement at the end of next month as sales and profits continue to dwindle.

The retailer is in talks to obtain new financing to shore up its struggling operations, which have been hit by slackening demand for its hipster fashions, as well as an immigration crackdown last year that forced the company to dismiss 1,500 undocumented workers at its factory in Los Angeles.

Yesterday, American Apparel warned in a securities filing that it “may not have sufficient liquidity necessary to sustain operations for the next 12 months.”

One source close to the situation said American Apparel’s prospects for new financing are “mixed” as the credit markets remain tight but added that funding is still “available at a price.”

The retailer is struggling in part because of the punishing interest rate it’s paying on a $91 million loan from Lion Capital, which hiked the rate to 17 percent from 15 percent in June. The British-based investment firm has locked horns with Charney repeatedly as it has kept a tight lid on spending.

To make matters worse, American Apparel also disclosed yesterday that in July it received a subpoena from the Manhattan US Attorney’s Office, which is investigating the resignation of the company’s former auditor, Deloitte & Touche. The Securities and Exchange Commission is also asking questions about the accounting firm’s departure. Last month, Deloitte said American Apparel’s 2009 financial statements may not be reliable.

Although Deloitte warned the retailer of “the possibility of collusion of improper management” in a letter four months earlier, officials note that the letter was part of boilerplate phrasing used by Deloitte that called such risks “inherent” to the practice of accounting.

Last year’s immigration crackdown was a startling slap in the face for American Apparel, which for years has lobbied for immigrant workers’ rights in its “Legalize L.A.” campaign.

“If it weren’t for the immigration bust by the Obama administration, the company would have been OK this year,” according to a source close to American Apparel.

For the quarter ended June 30, American Apparel said it expects to report a loss of as much as $7 million, as same-store sales fell 16 percent.