Halep raced through the first set after moving 5-0 up, and in the final set was 3-1 and 5-3 up. But Kerber roared back, saving two match points at 5-4 and then going up 6-5. Then it was her turn to see a pair of match points saved by Halep who broke for 6-6.
Halep finally prevailed in the 16th game for 9-7 when Kerber, who had saved another match point in that game, went long.
"At the end I was just trying to give everything that I had left," Kerber said. "I was fighting until the last point.
"My heart was there. My heart was on the court, I know I'm back," the former No. 1 added.
Like Halep, second seed Wozniacki will aim for a first Grand Slam title after twice losing U.S. Open finals.
The Dane admitted she had trouble finishing off Mertens after almost two and a half hours, leading 5-4 and 30-0 but losing serve for 5-5.
Two games later, she saved two Mertens set points to force a tiebreaker, which she won on the first of four match points as the Belgian hit the net.
"I think I was nervous, I didn't do much wrong for the first three points of that (10th) game," Wozniacki said.
"I served two good serves, then I had that forehand down the line which I missed by a couple of millimeters. It was 30-15 instead of 40-Love. All of a sudden, yeah, it just turned around.
"But I managed to just gather myself and thankfully closed it out in the end."
(c)2018 Deutsche Presse-Agentur GmbH (Hamburg, Germany)
Visit Deutsche Presse-Agentur GmbH (Hamburg, Germany) at www.dpa.de/English.82.0.html
Distributed by Tribune Content Agency, LLC.