Character Analysis
Everybody should have a BFF like Margaret Phelps. She's reliable, she's understanding, and she's smart—as long as it doesn't involve her ex-husband, Charley. When it comes to friendship, Margaret's in it for the long haul.
Margaret starts out as Joanna's close friend and confidante. They're so tight that Ted tries to blame Joanna's departure on Margaret:
TED: Do me a favor, just tell me the truth, okay? Did you set my wife up to this?
MARGARET: No, I did not put Joanna up to this.
TED: Give her a little pep talk?
MARGARET: No, I did not give her any pep talk. Joanna and I talk a great deal, yes, and Joanna's a very, very unhappy woman, and you may not want to hear this, but it took a lot of courage for her to walk out of here.
When Ted persists in making Joanna's unhappiness all about him, Margaret stands up to him, even unleashing some subtle sarcasm as Ted whines about how Joanna had the nerve to walk out on him on what was an otherwise awesome day for him, work-wise, as if she planned it that way for maximum inconvenience to Ted:
TED: Look, the fact is, for the last six months, I've been spitting blood to get this agency one of the biggest accounts it's ever had, and at 5:00 this afternoon, we got the account! At 8:00, I'm walking home with the vice president who tells me I'm going to be the next Creative Director of this department. I come through this door to share with my wife what's probably is going to be one of the five best days of my life, and she looks at me, cool as a cucumber, and tells me she doesn't want to live with me anymore! Can't you understand what she's done to me?
MARGARET: Yeah, she loused up one of the five best days of your life.
Well played, Margaret. Well played.
Needless to say, Margaret and Ted aren't best buds at the beginning of the film. As an audience, we're never made aware of exactly what their relationship was like before Joanna skips town, but she's pretty firmly on #TeamJoanna after she leaves, presumably because she's lent an ear to Joanna, and been a source of understanding. She had a front row seat to Joanna's misery, and it can't help but color her impression of Ted. (The fact that he keeps trying to blame her for Joanna's decision probably doesn't help.)
Once Ted starts to get his act together, though, once he starts becoming a devoted dad to Billy, Margaret sees it and her attitude toward him changes. She becomes his friend, ally, and support system, just as she'd done for Joanna. Margaret and Ted take their kids to the park together, for example, and she and Ted hang out and discuss parenting and their love lives.
As a divorcée, Margaret knows the drill, and she can sympathize, even though her situation with her ex is a little different than Ted's. Ted has no misconceptions that Joanna's going to come back, tell him she was wrong, and kick start a tearful reunion where they ride off into the sunset with Billy on matching unicorns. Margaret, on the other hand, still harbors feelings for her ex-husband. What kind of feelings? It's hard to say. Here's Margaret's attempt to explain:
TED: You think you'll ever get married again?
MARGARET: Nuh-uh.
TED: I mean to anybody.
MARGARET: Oh, no.
TED: Why?
MARGARET: I don't know. Maybe it's different if you don't have children, but even if Charley and I aren't living together, and even if we're sleeping with other people, and even if Charley were to get married again, I don't know, he's still my husband, and he's still the father of my children. That stuff about "'til death do you part," that's really true.
Things between Margaret and Ted stay completely platonic throughout the film. They're really good friends, and nothing more. When Ted and Joanna go to court for custody of Billy, Margaret testifies on Ted's behalf, not Joanna's. She's witnessed Ted's evolution from jerk to hero firsthand while Joanna's been AWOL, and she pleads with Joanna to reconsider her custody demands until after she's had a chance to really see Ted 2.0 up close:
MARGARET: Joanna, things are not the same now. Ted is not the same man. You don't know how hard he's tried. They're beautiful together, just beautiful…If you could see them together, Joanna—I mean, maybe you wouldn't be here now.
"Maybe you wouldn't be here now." Ouch. We see you, Margaret, dropping truth bombs. That's just one more thing that makes Margaret a BFF extraordinaire. She keeps it real, and she keeps it civil.
Now if only she could forget about that Charley guy. He sounds like he's the worst.