McCarty finished off a long free kick in the 72nd minute by midfielder Sacha Kljestan to give the top-seeded Red Bulls the advantage heading into the second leg of the total goal series next Sunday.
McCarty spent half of the 2011 season with DC before a trade sent him to New York. It was the Red Bull captain's first playoff goal since 2010.
"At the end of the day, the way he plays, we feed off of that," New York goalkeeper Luis Robles said. "For him to score a goal like he did in such a big moment, it's just the cherry on top to an incredible season that he's had."
In other playoff matches Sunday, the Portland Timbers tied the Vancouver Whitecaps 0-0, the Montreal Impact defeated the Columbus Crew 2-1 and Seattle Sounders beat FC Dallas 2-1.
Fourth-seeded DC can still advance if it wins and scores at least two goals in the return leg. New York advances with a win or a draw, and a 1-0 DC win would send the total-goals series to 30 minutes of extra time.
The Red Bulls defeated United at the same stage of the playoffs last season and won 3-0 and 2-0 in two games this season against DC at Red Bull Arena.
"We're not taking anything for granted; it's the playoffs," New York coach Jesse Marsch said. "And DC is going to come to Red Bull Arena fighting for dear life."
Elsewhere, substitute midfielder Johan Venegas' 77th-minute goal lifted the host Montreal over Columbus in the other Eastern Conference contest.
Late in the game, Venegas stole the ball from Crew defender Michael Parkhurst about 10 yards inside the Columbus half before chipping it over goalie Steve Clark to break the tie.
The teams will face each other again next Sunday in Columbus, Ohio.
- Sounders rally to win -
In Seattle, forward Clint Dempsey sailed a 25-yard free kick into the top right corner of the goal in the 86th minute, powering the Sounders to a come-from-behind win over Dallas.
Dempsey's free kick, which he curled around the Dallas wall and underneath the crossbar, was his 12th goal of the season.
Portland and Vancouver played to a scoreless stalemate, setting up a key Western Conference second-leg showdown.
The Timbers dominated possession throughout the afternoon in Providence Park, and a Portland offensive blitz in the second half forced Whitecaps goalkeeper David Ousted to make a number of crucial stops.
Ousted's biggest save came in the 72nd minute to deny a Diego Valeri free kick. Valeri's curling attempt went over the wall and nearly snuck inside the post, but a diving Ousted got a hand on it.
"I've seen him a few times (on free kicks)," Ousted said of Valeri. "He likes that corner and he's fantastic at putting the ball there. I needed a little bit extra to get there."