Efforts to fix the home foreclosure problems through Fannie Mae and Freddie Mac have driven up the cost of the bailout of those two firms. Bailout tracker

Bank failures

Brand name bankruptcies

Fortune Recovery Index The government is engaged in a far-reaching - and expensive - effort to rescue the economy. Here's how you can keep tabs on the bailouts. More Quick Vote Who will benefit most from the Obama administration's proposed financial regulations? Consumers

Banks

Regulators or View results

NEW YORK (CNNMoney.com) -- The first big government bailout of the financial crisis -- the takeover of mortgage finance giants Fannie Mae and Freddie Mac -- is poised to be the most expensive and complicated to complete.

Since Congress essentially wrote a blank check to the Treasury Department in July 2008 to do what needed to be done to inject capital into the two firms, Fannie (FNM, Fortune 500) has received $34.2 billion of direct government support while Freddie (FRE, Fortune 500) has received $51.7 billion.

While that's lower than the $117.5 billion poured into insurer AIG (AIG, Fortune 500) by the Federal Reserve and the $200 billion given to the nation's largest banks through the Troubled Asset Relief Program, or TARP, the current cost of the Fannie and Freddie bailouts dwarfs original estimates from a year ago

When Congress was debating the bailout of Fannie and Freddie last July, the official estimate from the Congressional Budget Office was that a bailout would most likely cost taxpayers $25 billion, with only a 5% chance of the price tag reaching $100 billion between them.

In addition, both Fannie and Freddie are likely to need billions of dollars more after they report second quarter results in the coming weeks. Experts believe the cost will only continue to rise in the next year.

"We're assuming they each will cross the $100 billion mark fairly soon. They could be hitting the $200 billion barrier by the end of next year," said Bose George, mortgage analyst at Keefe, Bruyette & Woods, an investment bank specializing in financial services firms.

The direct government aid has helped keep the two troubled firms solvent. The amount of any additional aid will be determined by their ongoing losses and reserves for future losses on the trillions of dollars in mortgage loans they own or guarantee.

Fannie and Freddie were originally created to help ensure that financing for homes would be available and affordable to more consumers. The two firms buy mortgages from banks and other lenders and bundle them together into securities. They then either hold those securities or sell them to them to investors with a guarantee that they will be paid the money owed by homeowners.

But as more homeowners continue to default on mortgages, the two firms will likely book additional losses well into next year.

Neither firm has given an estimate as to how high losses will reach. But the original limit of $100 billion in losses set in place when the government put Fannie and Freddie into conservatorship, essentially a form of bankruptcy, last September was quickly raised early this year to $200 billion each because of concerns about looming losses.

In return for pumping taxpayer dollars into the two firms, Treasury received preferred stock, which is designed to give the government a healthy 10% to 12% dividend. But few expect that Fannie or Freddie will be able to pay that dividend, let alone return the money handed to the firms to cover their losses..

Even James Lockhart, director of the Federal Housing Finance Agency, the government body that has overseen the two firms since they were placed into conservatorship, said it will be a challenge for Fannie and Freddie to make their scheduled payments.

"Obviously the 10% dividend is a high rate," he said, but added that this is probably below what private market investors would demand to own preferred shares in the two companies.

Lockhart also agrees with experts who believe that the government will eventually have to write down at least a portion of the money that has been sunk into Fannie and Freddie. He would not estimate how much, saying it will depend upon housing prices in the future.

But Lockhart maintained that the loss of taxpayer money is worth it in the long run because Fannie and Freddie have continued to be vital parts of the housing market during the credit crunch.

"They really have been the backbone of the housing market throughout this period," he said. "The money spent, we can at least say has gone to a good cause -- keeping the housing market much more stable than it would have been [without the bailout]."

And it's precisely for this reason that experts think the ultimate bailout cost will climb much higher. The money allocated for Fannie and Freddie is being used not to simply return the firms to profitability, but to try and fix the broader housing market's problems.

Using Fannie and Freddie for housing policy

Both the Bush administration and the Obama administration have used government control of Fannie and Freddie to implement various policies to try to address rising home foreclosures and falling prices. The firms are a key part of the Obama administration's efforts to refinance mortgages of at-risk home owners, in some cases making loans for up to 125% of the home's current market value.

"The way to think of the cost is not as a loan," said Phillip Swagel, a professor at Georgetown's business school who was the assistant secretary for economic policy in the final months of the Bush administration. "It's really a way of spending taxpayer money for policy purposes."

In contrast, other companies receiving federal bailout dollars, such as automakers General Motors and Chrysler, money-losing banks and AIG, were given the charge by Treasury Department officials to stem their financial bleeding so they could eventually be returned to full ownership by the private markets.

But unlike the rapid six week bankruptcy process at GM and Chrysler, the conservatorships at Fannie and Freddie won't be coming to a conclusion any time soon. Even as it laid out its plans to reform the nation's financial regulatory system last month, the Obama administration said it would not put forward a permanent plan to fix the mortgage finance firms until February 2010.

After that, it's uncertain how long it will take to get the necessary approval from Congress for any changes to the current structure of Fannie and Freddie. There is a case for maintaining the status quo since Congress and the Obama administration have been able to use the two firms to deal with broader problems in the housing market.

What's clear is that there will continue to be a need for companies like Fannie and Freddie to keep mortgage costs relatively affordable by packaging loans into securities, placing a guarantee on them, and selling them to investors.

Some experts believe that this business can become very profitable again, especially if Fannie and Freddie maintain tight underwriting standards from now on.

Fannie and Freddie "may own the securitization game for the next decade," said Jaret Seiberg, analyst with Concept Capital's Washington Research Group. "They'll have a duopoly, a smaller portfolio and a profitable business model."

But before any of that happens, taxpayers will likely take an even bigger hit on the Fannie and Freddie bailouts first.

Talkback: Should the government spend more taxpayer money to keep Fannie Mae and Freddie Mac afloat? Share your comments below.