Adrian Ramos put the visitors in front before an Eric-Maxim Choupo-Moting penalty levelled matters and ensured both sides can still dream of European football next season.
Only goal difference separates Mainz from the top six, with Hertha just two points further behind with 10 games of the season to go.
Mainz failed to make their visible superiority count at the end of a one-sided opening 45 minutes, and they were made to pay early in the second half.
Choupo-Moting and Shawn Parker wasted the best of Mainz's chances, although each time it was Thomas Kraft in the Hertha goal who denied them.
Choupo-Moting then made a costly mistake deep in his own half, casually losing the ball to Per Skjelbred. He quickly sent it into the path of Ramos, who did not hesitate in bagging his 15th goal of the season.
Mainz's reply was immediate and Nikolce Noveski had the equaliser served on a plate, but he somehow placed his free header wide from five yards out.
The next mistake of the game, this time from former Mainz forward Sami Allagui, set up the hosts for an equaliser.
He unnecessarily threw himself at the feet of Park Joo-ho, and a penalty was inevitable as the South Korean went down.
Choupo-Moting made up for his earlier mistake by dispatching the spot-kick beyond the reach of Kraft into the bottom left-hand corner.
Mainz created the better chances to win the game but Kraft continued to keep them at bay, most notably tipping a Choupo-Moting lob over the crossbar 10 minutes from time.