Cardiff - Jos Buttler made an unbeaten half-century as England shrugged off Clint McKay's hat-trick to win the fourth one-day international against Australia by three wickets on Saturday to set up a series decider on Monday.
Buttler guided England, chasing 228 for victory, home in Cardiff with three balls to spare after hitting 65 including a six off Mitchell Johnson in the final over.
The five-match series is tied at 1-1 after the first and third games were washed out by rain.
England were reeling at eight for three after fast bowler McKay dismissed Kevin Pietersen, Jonathan Trott and Joe Root in the third over.
Pietersen was trapped lbw for five, Trott edged a catch to Aaron Finch at second slip and Root nicked a full-length delivery to Shane Watson at first slip as McKay became only the fifth Australian to take a hat-trick in one-day internationals.
England recovered with opener Michael Carberry and captain Eoin Morgan sharing a stand of 104.
Morgan was bowled for 53 and when Carberry, who had progressed to 63, his maiden ODI half-century, became debutant Nathan Coulter-Nile's first ODI victim, England still had work to do.
Ravi Bopara fell cheaply, allowing Ben Stokes (25) to join Buttler and the pair added 75 to take the hosts to the brink of victory.
Australia's 227 all out owed much to George Bailey's fluent 87 off 91 balls.
England fast bowler Steven Finn removed Aaron Finch in the first over and Watson made only six before nicking a catch to wicketkeeper Buttler off Boyd Rankin.
Shaun Marsh (25) and captain Michael Clarke (22) also fell cheaply but Bailey received solid support from Adam Voges (30) and Matthew Wade (36) in testing batting conditions.
Bailey, who hit three sixes and five fours, was eyeing a century when he edged Rankin to Buttler and spinner James Tredwell took three wickets as Australia were bowled out in the 49th over.