For nearly a decade, Beth Jacobson lived inside the vast machinery of subprime mortgages that shook the nation’s economy.

In sworn court testimony, she described watching loan officers comb through heavily African American areas such as Baltimore and Prince George’s County, forging relationships with churches and community groups to sell their members shoddy mortgages. She says she processed loans for homeowners with sterling credit ratings with higher interest rates than they needed to pay. And she says she pumped out millions of dollars in mortgages to people with no paperwork and low incomes, becoming Wells Fargo’s top-producing loan officer.

The machine made her rich — the questions came later. Now, she has recast herself as a crusader for consumers in a battle that has pitted her against the system she once pushed.

The 51-year-old Maryland resident has emerged as a defining character in the ongoing saga of the country’s housing crisis, from the headiest days of the bubble to the current flood of foreclosures. Her scathing affidavit detailing “the stagecoach to hell” at Wells Fargo is a key part of the groundbreaking lawsuit filed by the city of Baltimore against her former employer. The case spawned copycats across the nation, and federal regulators launched investigations mirroring its allegations.

The company flatly denies any wrongdoing, especially when it comes to Jacobson’s claims. It calls her testimony misleading at best and, at worst, outright lies.

The consequences are still unraveling. Wells Fargo is under investigation by the Justice Department over alleged fair-lending violations, and it has spent millions of dollars to put similar charges to rest.

Jacobson has faced her own fallout. Her income plummeted after she left Wells Fargo five years ago, and creditors are knocking. A vacation home and an investment property she bought at the height of the market were both foreclosed on. She and her husband divorced last year.

Yet she has placed herself back inside the machine. Her new business focuses on homeowners navigating complicated loan modifications and examines mortgage documents for fraud. She has used an obscure clause in the federal financial regulatory overhaul to help her clients win thousands of dollars from their mortgage companies. She tracks auction notices and pursues strangers on Facebook to tell them to fight their banks.

Jacobson’s journey through the housing boom and bust mirrors the country’s own struggle for recovery — a messy, complicated affair in which blame is plentiful but redemption is hard to find.

“The whole system’s crazy,” she said.

Get people approved

Jacobson had never heard of a subprime loan when she joined Wells Fargo in 1998.

Wall Street had just figured out how to generate enormous pools of money that could be used to extend these mortgages to people with low incomes or poor credit. Many of them were minorities who traditionally had been unable to qualify for a loan. The trade-off was that they paid higher interest rates and often accepted adjustable terms.

The mortgages were so popular that they spawned a boom in lending that in turn fueled the country’s economic growth. Home­ownership soared among blacks and Latinos, a fact celebrated at the time by banks and consumer advocates.

Jacobson said her job in Wells Fargo’s subprime unit was straightforward: Get people approved.

She had never worked in lending but quickly learned the ropes. In her affidavit, she said the quickest and most profitable way to make loans was to steer borrowers into the new breed of subprime mortgages. It didn’t matter if they couldn’t afford the mortgage in the long run. All loan officers were paid by the number of loans they approved, not whether they succeeded, she said.

Subprime loans were so lucrative, she testified, that many of her counterparts selling traditional mortgages realized they could make more money by referring borrowers to her than by making their own loans. That meant customers were offered subprime mortgages even if they qualified for better interest rates, she said. Other times, brokers encouraged buyers not to provide a down payment or income documents, automatically funneling them into the more profitable subprime division, she said.

“There was always a big financial incentive to make a subprime loan wherever one could,” Jacobson wrote in her affidavit.

Company spokesman Oscar Suris flatly denied Jacobson’s testimony. He said the bank never made “no doc” mortgages or predatory loans that kept homeowners from paying down principal. An internal review of a sample of the subprime mortgages Jacobson approved found that almost all of the borrowers would not have qualified for traditional loans. And, he said, prime-loan officers had quotas to meet as well — only a few could have made more money referring clients to Jacobson.

Her declaration proves that she violated several company policies, Suris said. According to Wells Fargo, Jacobson was more like a technical glitch than a cog in a well-oiled machine. Back then, only 10 percent of the company’s mortgage business was subprime, he said.

“Ms. Jacobson is making unfounded and opportunistic accusations that are offensive, inaccurate, and contrary to Wells Fargo’s commitment to fair, responsible and unbiased lending practices,” Suris said.

There is one thing, however, that Wells Fargo does not dispute: Jacobson was extraordinarily successful at what she did.

She churned out roughly $50 million in loans annually for Wells Fargo, making her the top-producing subprime officer in the country. She earned as much as $700,000 one year, more than seven times the company’s stated average for subprime-loan officers in her area.

As a reward, she got all-

expenses-paid trips to Cancun and the Bahamas, where the likes of Aerosmith and Jimmy Buffett performed for employees, according to her testimony. She bought a home in Federalsburg, Md., with her husband, an investment property down the street and a vacation house in Virginia.

This was the good life. She didn’t ask a lot of questions.

But some things poked at her conscience, she said.

She said she grew uncomfortable after being excluded from meetings about marketing to black churches. She said that she later learned how sales pitches purposefully shunned the word “subprime” and that she was taken off the roster to speak at a “wealth-building” seminar in predominantly black Prince George’s County because she was “too white.”

“The point was clear to me: Wells Fargo wanted black potential borrowers talking to black loan officers,” she wrote in the affidavit.

Wells Fargo said she was asked not to speak because she lived far from the region being discussed.

Jacobson’s testimony is one of the most salacious and incendiary pieces of the Baltimore lawsuit. The city’s attorney, John Relman, said her statements are crucial to proving that Wells Fargo intentionally made bad loans to black homeowners — and that it is the bank’s fault many of them have gone bad. The company argued that the scope of the case has become so narrow that Jacobson’s affidavit is no longer relevant.

But in an opinion allowing the suit to move forward last year, U.S. District Judge Frederick Motz cited Jacobson’s testimony as essential to bolstering the city’s claims.

“This proffered evidence also undermines Wells Fargo’s claim that the city’s allegations identify nothing more than ‘industry-wide wrongful practices’ common to all lenders,” he wrote.

Connecting the dots

Jacobson can’t shake the shadow of Wells Fargo.

She said she left the company in 2007 when she moved to Easton, Md., and was unable to open an office closer to her new home. Disillusionment also set in after she heard a company executive deny dealing in subprime loans, she said.

Jacobson said the statement blew her mind. She had recently received an internal e-mail congratulating her division for meeting its quarterly targets. How could anyone say that she didn’t exist?

That’s when she began to connect the dots. The loans she was originating were not just un­affordable for homeowners — she believed they were intentionally designed that way.

She recalled thinking, “Wait a minute — we’re setting people up for failure.”

Wells Fargo has scoffed at the characterization — 2007 was the year the bank stopped making subprime loans, leaving Jacobson out of a job, a spokesman said.

That year, the volume of subprime loans fell by $40 billion across the country, according to Moody’s Analytics. Meanwhile, foreclosures doubled. Soon, the mortgage crisis landed on her doorstep.

Not only did Jacobson lose homes she owned in Virginia and Federalsburg, but several of her friends were also underwater, owing more than their homes were worth. In 2009, one friend told her his bank could not even find proof that it owned his loan.

That didn’t make any sense to Jacobson. If the bank couldn’t prove it owned the loan, then it should not be able to foreclose on the home. How did the bank even know the property belonged to it?

Soon she was trolling the Web site of the Securities and Exchange Commission in hopes of unraveling how loans were sold and resold, in many cases without proper papers. She read 1,200-page pooling and securitization agreements and began trolling Internet forums where people shared their experiences about fighting foreclosures.

“You could see this wave of movement from homeowners,” Jacobson said. “There was this kind of quiet uprising.”

It would be another year before fraudulent and shoddy foreclosure paperwork made national headlines in fall 2010. Earlier this year, some of the nation’s largest banks, including Wells Fargo, agreed to a $25 billion settlement with the federal government over the “robo-signing” scandal — the largest industry payout since the tobacco settlement in the late 1990s.

By then, Jacobson had found her new calling.

Her new business is called Professional Compliance Examiners. She and her partner, Doug Rian, have roughly 60 open cases and work round the clock, waiting for hours on the phone to speak with a client’s lender, traveling with them to the foreclosure offices the banks have set up, testifying on their behalf in court as expert witnesses.

“This is not a world that the lay person can navigate,” said Lynn Anstatt, who worked with them to secure a modification for her loan after years of battling on her own. “You just feel amazingly alone, and you don’t know where to turn.”

Jacobson and Rian work out of a picturesque home on the water on Maryland’s Eastern Shore that they say they saved from foreclosure. Only a small sign above the mailbox indicates that this is anything but another neighborhood home. Inside, two massive desks stacked high with files sit by the front window.

“The true revolution of which we’re a part is that of homeowners, one at a time, insisting that ours is a nation of laws,” Rian said in an e-mail. “They’re not getting the attention that the Occupy Wall Street people are, but these homeowners are quietly saving their home using the information from our audits, and each time we testify another of society’s foundations — that of secure wealth — that has been roughly shaken, is preserved and thereby strengthened.”

‘Like two pit bulls’

For their services, Jacobson and Rian charge between $300 and $2,000. For-profit mortgage-relief companies have come under scrutiny by federal regulators, who say many have scammed customers for services never produced. The Federal Trade Commission has warned that there is no evidence that audits speed up loan modifications or foreclosure relief.

Jacobson said she and her partner have gotten 30 foreclosures dismissed over the past two years and helped in dozens of other successful loan-modification and foreclosure cases. They have sent tips to the Maryland attorney general’s office and helped homeowners fight foreclosure-relief scams.

Jacobson said she is not in the business for the money — especially since she is barely making any. Court documents show one of the most recent creditor filings against her was by her dentist for $905.

On a recent rainy morning, Jacobson sat on a couch in the living room of her Easton office with John Dierker, a mammoth man clutching a super-size soda in one hand and his Shih Tzu, Haley, in the other. Despite a string of layoffs during the recession, Dierker stayed current on his mortgage until two years ago. That’s when his lender began moving to foreclose on his home — and when Dierker began fighting back.

In their 21-page audit of his loan, Jacobson and Rian say Dierker’s lender stopped accepting his payments in August 2010. The notice of intent to foreclose listed the day he defaulted as May 2, even though Dierker’s bank statements show that the company cashed two checks he sent after that date. In other words, they say the bank tried to foreclose while Dierker was still sending in payments.

Today, Jacobson has even better news to deliver. The bank doesn’t even own his loan.

“They had no legal standing to even sue you,” she told Dierker, handing over a letter verifying her statement. Freddie Mac actually holds the note.

“They’re like two pit bulls,” Dierker said of Jacobson and Rian. “When these guys get going, there’s nothing stopping them.”

Critics have compared them less charitably to “junkyard dogs,” Jacobson said with a mix of disdain and pride. But if she knew five years ago what she knows now, she said, she might have been able to save her properties from foreclosure.

She is still working through a loan modification for the house she bought in Easton at the height of the market for more than $500,000. Jacobson said the bank wrongfully returned payments she made during her trial modification. The bank said it is still waiting for her to submit missing documents.

For Jacobson, this has become as much about the process as a symbol of her fight. She said she isn’t even sure who owns her loan anymore. One letter she received said Freddie Mac held the note.

Another said it was Wells Fargo. Her former employer began moving to foreclose this month.