The actress purchased a $3.3 million (£2.41 million) mansion in Malibu, California from Cynthia Pett-Dante - Brad's longtime manager - in 2016, but soon realised there were serious problems with the pad, including mould and leaks, requiring an outlay of at least $500,000 (£365,000) in remedial work.
Megan filed a $5 million (£3.65 million) lawsuit against Pett-Dante, claiming the property troubles had given her "chronic migraines" and "constant stress."
However, a court order earlier this month ruled in favour of Pett-Dante as Judge David Soleto granted her motion for a summary judgement.
Cynthia offered a $100,000 (£73,000) compromise deal under a California civil code, which allows either party to propose a settlement before the case goes to trial.
The deal was accepted by Megan although it is one-fiftieth of the amount she had demanded, according to court papers obtained by MailOnline.
The judge pointed a finger at Fox during the case for ignoring the advice of real estate lawyer Joseph D'Onofrio, who had described the property as a "nightmarish, ill-advised and risky" purchase.
Megan also admitted to not reading vital emails and inspection reports that would have alerted her to the mansion's problems.
"I pay other people to read them and tell me what's in them and advise me on what I should do or not do," she testified.
Fox confessed to pushing the sale through because it was the only home in Malibu in her price range and she wanted her children to go to a new school there.
She also gave birth to her third child with her ex, Brian Austin Green, Journey River Green, three months after the purchase, which also caused the new mum to be less attentive to her business dealings than usual.
"Well, for me it's hazy. I just had a baby," Megan said in her testimony. "So I was concentrating on that. I remember that the (repair) estimate came in very high. We didn't have that kind of money sitting around where I could fix it and be okay."
"So there were a lot of discussions about me needing to go back to work pretty quickly after having the baby, in case I was going to have to fix this. I don't recall exactly. It was high. I believe the first estimate was high. Upwards of $500,000."