In the night's other first leg, a second-string Barcelona were held to a goalless draw at city rivals Espanyol, who put on a solid, morale-boosting performance for new coach Mauricio Pochettino.
Mata grabbed a valuable lead for Valencia before next week's return leg in Seville when he picked up the ball in the area in the 86th minute and unleashed a low drive that spooned up off defender Sebastien Squillaci into the net.
A defensive howler by Adriano Correia had gifted Valencia their opening goal after five minutes. Striker David Villa intercepted the Brazilian's wayward back pass, rounded Palop and drove the ball into the empty net from a narrow angle.
The Spain international was forced to leave the pitch shortly afterwards with an injury to his left hamstring and was replaced by Fernando Morientes.
Sevilla coach Manolo Jimenez brought on winger Diego Capel at the break and his cross from the right created the equaliser.
Valencia keeper Vicente Guaita rushed off his line but the 21-year-old missed his attempted punch and Luis Fabiano leapt to nod the ball home.
The Valencia players were furious with the officials after Correia made it 2-1 on 67 minutes.
Replays showed the Brazilian was several metres offside when the ball was played through but the referee allowed the goal to stand after Correia sent a crisp finish past Guaita.
Ruben Baraja equalised in the 84th minute with a low shot and Valencia's efforts to find a winner were rewarded when Joaquin released Mata to score two minutes later.
Valencia coach Unai Emery said the error by the referee's assistant had been hard to take but he was more worried by the number of goals his side were leaking recently.
"Generally I am satisfied but we had a bad patch in the second half, not for the first time this season," he said.
Villa was doubtful for Sunday's League match at Real Mallorca, he added.
Barcelona coach Pep Guardiola opted to leave key players including Lionel Messi, Xavi and Samuel Eto'o out of the starting line-up and the league leaders struggled to break down Espanyol's stubborn resistance.
Not even the introduction of Messi and Xavi midway through the second half could open up the home side's defence and the match stuttered to a draw.
Athletic Bilbao host Sporting Gijon and Real Betis play at Real Mallorca in Thursday's quarter-finals.
In the semi-finals, the winners of the Espanyol-Barca tie will play Mallorca or Betis for a place in May's final and Valencia or Sevilla will take on Athletic or Sporting.