The answer offered by @MD-Tech is unfortunately profoundly wrong on a number of its core assertions. I will first correct these assertions (and offer references while doing so) and then very briefly offer a few points that should put the 2008 crisis in the proper perspective.
TL;DR: Government guarantees on mortgages didn't play any role in the crisis; CDOs and CDS played a role in keeping the mortgage pipeline running as long as it did but private-label MBS were the security that played the central role in the crisis; and the actual reason that mortgage losses almost destroyed the global economy is that private-label MBS had been heavily funded using repo, which transformed mortgage debt essentially into a form of money, and when the market went south, it led to a run on wholesale bank funding that amounted to a massive contraction of the broader money supply.
First, the errors:
Error One: Implicit Government Guarantees
In the (first?) Clinton and Bush administrations there was a political will (rightly or wrongly; it isn't important) to help people buy their own homes. This applied particularly to low income families who previously had not been able to buy, in many cases for generations. To do this bills were passed to offer subprime loans with the implicit backing of the US government.
This assertion is untrue. No bills were passed in the 1990s to offer subprime loans with the implicit backing of the US government, and government-backed loan channels (including implicit backing) actually lost significant market share prior to the crisis. You might be thinking about the Community Reinvestment Act, which was blamed by some conservatives for the crisis, but this view is not held in high regard by economists. The Financial Crisis Inquiry Commission Final Report has this to say on the matter (p. xxvii):
The Commission concludes the CRA was not a significant factor in subprime lending or the crisis. Many subprime lenders were not subject to the CRA. Research indicates only 6% of high-cost loans—a proxy for subprime loans—had any connection to the law. Loans made by CRA-regulated lenders in the neighborhoods in which they were required to lend were half as likely to default as similar loans made in the same neighborhoods by independent mortgage originators not subject to the law.
There are two main channels (I am ignoring the VA, Farmer Mac, and other small entities) that offer credit protection on mortgages: the Federal Housing Administration, which insures loans that are then issued as securities through Ginnie Mae (and are explicitly backed by the full faith and credit of the US government); and the GSEs, Fannie Mae and Freddie Mac, whose securities received implicit government backing. Both the FHA and the GSEs do engage in some amount of lending to borrowers who would be considered under some definitions to be "subprime," and have for decades.
However, let's look at the pre-crisis boom period from 2002-2006, during which house prices nationally increased by an average rate of about 14% annually:
And let's see what happened to the government share of mortgage originations:
This should make it very clear that during the boom period, GSE originations fell significantly, while private (that is, no government backing, implicit or explicit) originations expanded from about 50% of the overall market to about 70% of the market. Both of the above graphics are pulled from the Financial Stability Oversight Council's 2013 Annual Report, which notes (page 57):
In 2012, the Federal Housing Administration (FHA) and the Department of Veterans Affairs (VA) guaranteed 20 percent of originated mortgages. FHA- and VA-guaranteed loans make up a majority of Ginnie Mae MBS issuances. Between 2001 and 2007, FHA lending accounted for less than 5 percent of annual originations. The market share for FHA lending was small at the time because eligible borrowers were primarily receiving non-agency loans funded through securitization. After secondary-market investors retreated from private-label
securities after the crisis, FHA lending became the dominant avenue for low- to middle-income mortgage market credit.
Emphasis mine. This graphic also illustrates how after the housing crash that began in 2006 and became acute in 2007, federal lending programs expanded significantly, acting as a safety net for the housing market. Regardless, it should be clear that private lending, not government lending, drove the housing bubble.
Further, while both the FHA and the GSEs saw significant losses during the crisis years, with the GSEs receiving a government bailout under the Housing and Economic Recovery Act of 2008, no investor saw a single dollar loss on debt or mortgage-backed securities issued by Ginnie Mae, Fannie Mae, or Freddie Mac. The fact that no investor lost principal on these securities should be a strong hint that they were not behind the financial crisis. Here's the Financial Crisis Inquiry Commission report on the matter (p. xxvi):
We conclude that these two entities [the GSEs] contributed to the crisis, but were not a primary cause. Importantly, GSE mortgage securities essentially maintained their value throughout the crisis and did not contribute to the significant financial firm losses that were central to the financial crisis.
So on this point, we've learned two major lessons:
- Implicit government guarantees did not drive the housing bubble.
- No investors lost principal on GSE or Ginnie Mae debt or mortgage-backed securities. Put differently, nothing that was viewed as having a government guarantee lost a dime.
Error Two: Confusing Mortgage-Backed Securities with CDOs
The mortgage companies then had a large tranches of debt on their books that, although apparently backed by Sam, were riskier than their previously core business. To mitigate this risk they rolled them up into CDOs which, given that the probability of any one loan defaulting was taken to be independent of any and all others defaulting, supposedly held lower risk than the individual loans.
This description of the crisis completely glosses over the main financial instrument at the heart of the crisis, which is the private-label mortgage-backed security (herefter referred to as PLMBS). These securities, consisting of pools of mortgages that back securities of different risk profiles (often referred to as "tranches"), have no government backing, implicit or explicit. Tranching can render senior tranches of PLMBS safe (and some senior tranches of PLMBS in fact saw no losses in the crisis).
Regarding the use of the word "supposedly," basic statistics can show that PLMBS pools are safer than individual loans so long as default correlations are less than one (one does not need to assume that correlations are zero, as the answer implies); and basic math can show that even under the extreme scenario where default correlations approach one, senior tranches are still safer than individual loans. Correlations mattered significantly in CDOs, but CDOs weren't composed of loans: they were composed of junior tranches of securities backed by pools of loans (often PLMBS), like so:
Additionally, it is inaccurate to suggest that MBS issuance was in response to "large tranches of debt" on the books of "mortgage companies" when in fact subprime mortgages were originated for the express purpose of being securitized. The mortgage loans weren't generally held on the books of financial institutions, they were held primarily in off-balance-sheet ABS warehouse facilities until they were delivered into PLMBS pools.
Demand for PLMBS (the source of which is an interesting story itself but this answer is long enough already) actually drove subprime mortgage originations, as noted by the Financial Crisis Inquiry Commission (p. 87):
When it came to subprime lending, now it was Wall Street investment banks that
worried about competition posed by the largest commercial banks and thrifts. Former Lehman president Bart McDade told the FCIC that the banks had gained their own securitization skills and didn’t need the investment banks to structure and distribute. So the investment banks moved into mortgage origination to guarantee a supply of loans they could securitize and sell to the growing legions of investors.
Error Three: CDOs and CDS Did Not Cause the Financial Crisis
This is a subtle, but important point. Derivatives, including CDOs and CDS, certainly played a role in the financial crisis— they played a major role in the failure of AIG, and they kept the mortgage securitization chain running for longer than it would have otherwise, but beyond AIG, no major firm failed as a result of its derivatives exposure.
Here's a list of the major (US) firm failures, in order (I am counting firms that would have failed had they not sold themselves as failures, and excluding a bunch of pretty plain-vanilla banks that all failed primarily due to portfolio mortgage exposures):
- Bear Stearns (wholesale funding run)
- Countrywide (mortgage portfolio/warehouse losses)
- Fannie Mae and Freddie Mac (mortgage portfolio and PLMBS losses)
- Merrill Lynch (wholesale funding run)
- AIG (derivatives exposures)
- Washington Mutual (mortgage portfolio losses; bank run)
- Lehman Brothers (wholesale funding run)
- Wachovia (mortgage portfolio losses; bank run)
Okay, What DID Cause The Financial Crisis?
Well, I kind of gave it away above, but let me slay a couple more bad ideas first.
Mortgage losses alone were probably not sufficient to cause the financial crisis. They were certainly a core part of it, but they, by themselves, were not sufficient to cause, as the original poster asked, the near-failure of the world economy. This might sound crazy, but let's look at the numbers briefly.
Here's the total amount of mortgage debt outstanding in the United States, from the Federal Reserve, via FRED:
It peaks around \$14.8T, and hits bottom around \$13.2T. Being really lazy about it and assuming both that all that decline is due to mortgage defaults and just rounding up a bit, we come to about \$2 trillion in losses on mortgage debt over the entire history of the financial crisis.
But here's the market capitalization of a few of the larger US financial firms prior to the crisis:
Which doesn't look good, until you realize that a) many of our mortgage assets were held by foreigners, pension funds, and other entities; b) the GSEs (and ultimately taxpayers) absorbed hundreds of billions in losses, and c) the $2T figure I started with includes all losses up through the end of the mortgage crisis, and the actual financial crisis occurred only two year in to the mortgage crisis. Then you realize that the mortgage losses alone probably weren't enough to bring down the financial system.
Derivatives also did not cause the financial crisis. To a first approximation, one could say that the financial system as a whole lost no money at all on derivatives, as any one party's loss was another's gain, and the only major firm to fail primarily as a result of derivatives exposures was AIG (and this failure did not cause the failure of any other major firm).
So what was it, really? A bank run, just like every other financial crisis. Not a traditional bank run, but a run on repo, which is the core bit of the story that is omitted above. (To be fair, he does mention leverage in passing, but repo is more than leverage— it's leverage and liquidity transformation)
Repo is essentially a form of collateralized borrowing used by financial firms— you lend me money, and I give you a pile of stuff that you're pretty sure is worth a little more than the money you're lending me as collateral, then later on, we trade back. Unfortunately, one of the "piles of stuff" that was being used heavily in repo was mostly high-quality, AAA tranches of the aforementioned PLMBS, which at first everyone assumed was as good as (actually, sometimes better than) gold, but then once people started seeing losses on PLMBS, because nobody sitting at a repo desk could figure out how to price the stuff, they started lending less and less against it, until they wouldn't accept it as collateral at all.
One problem with this is that it had the same effect as a bank run, but there was no equivalent of government deposit insurance to help stop the run— people ran, and for a number of major financial firms, it was over. A bigger problem with this is that it meant that the entire shadow banking system seized up, causing a significant contraction in the broader money supply— which is what actually almost killed the global economy.
It's this critical link— the fact that people not paying mortgages was amplified through wholesale finance in a way that transformed the mortgage debt into highly-liquid, money-like liabilities, so that the lost wealth actually translated into a contraction of the money supply— that is often lost. Stock market losses in the 2000 "Dot-Com" crash were actually greater than losses on residential mortgages. But it didn't destroy the global economy, because people weren't funding stock market positions with short term debt— if they were, it would look like— wait, now I'm actually just describing the Great Depression.
Almost all the other stuff that @MD-Tech says is true— there were, for example, people who took out no-documentation mortgages with no intention of ever paying them back, borrowing sometimes more than the cost of their homes and blowing the money on stuff (I don't know what, exactly, but Las Vegas saw a lot of the housing boom and bust so gambling and strip clubs were probably in the mix).
And yes, CDOs did play a role in getting to that point, but the role they played was mostly at the end— they were sufficiently complicated that errors in modeling correlations led some to believe that the more senior tranches were safe, while the more junior tranches were actually often purchased by people who were betting against the housing market (these individuals would take out large CDS positions but also buy junior CDOs, which gave them cash flow to fund CDS premiums until everything blew up, at which point the CDS paid out and they were rich(er) and people wrote books about them).