Yannick Noah's champions had their backs against the wall after losing both Friday's singles but Herbert and Mahut began the fightback, reducing the deficit to 2-1 and ensuring the last Davis Cup in its present guise will stretch into Sunday.
The odds are still stacked in Croatia's favour as no team has recovered from 2-0 down to win the trophy since Australia beat the United States in 1939.
But with 26,000 mainly flag-waving French fans set to flock back into the cavernous home of Lille's soccer club on Sunday, hope still remains.
Tokyo 2020
Murray's Olympic love affair ends with doubles defeat
28/07/2021 AT 06:21
It had looked like being a relatively comfortable win for the French duo when they had points for a double break in the third set, having won the first two in dominant fashion.
But Pavic and Dodig, who had partnered Marin Cilic to a crucial win over Mahut and Herbert when the sides met in the 2016 semi-finals in Zadar, hit back to set home nerves jangling.
Herbert faltered when serving at 3-4 allowing the Croats to break serve and then hold with ease to the delight of their noisy followers high in the upper tiers.

Nicolas Mahut et Pierre-Hugues Herbert

Image credit: Getty Images

Alarm bells were ringing at the start of the fourth when France had to save three break points on the Herbert serve and he was again made to work hard at 2-2 as the momentum of the match began to swing Croatia's way.
France kept their noses in front though and the fans ratcheted up the decibel levels as Pavic served at 4-5.
The Croat, yet to win a Davis Cup tie, duly buckled with a double-fault at 0-30 and bedlam broke out in the stands with opposing fan clubs trying to out-sing each other.
With the umpire struggling to restore order, Pavic showed incredible composure as he and Dodig somehow dug themelves out of a seemingly impossible position to make it 5-5.
Boos rang out as Pavic gestured defiantly at the massed ranks of blue amid the suspicion that Croatia would be favourites to win the rubber if they could take the tiebreak.
Yet Mahut and Herbert jumped into a 4-1 lead and though the Croatians got it back to 4-3, the French pair then kept their cool with Mahut's reflex volley sealing the win.
Tokyo 2020
Murray and Salisbury pull off major upset at Olympics
24/07/2021 AT 05:13
Murray: I don't want it to be my last Wimbledon
22/06/2021 AT 09:36