Cardiff City moved into the Second Division play-off zone with a 3-2 win over Wrexham - but they were left hanging on in the final minutes.
The Bluebirds raced into a 2-0 lead within 17 minutes thanks to goals from Scott Young and Peter Thorne, and looked as if they could follow up last weekend's 7-1 success over Oldham with another big win.
But Craig Faulconbridge reduced the deficit in the 34th minute with a fine header, and Cardiff began to get the jitters.
The half-time whistle came at just the right time for the home side, and Lennie Lawrence's team talk had the desired effect.
Desperate
Defender Danny Gabbidon fired home a long-range drive to restore City's two-goal advantage.
After missing several chances, Cardiff sat back and Wrexham came into the game again.
Lee Trundle and Faulconbridge both had chances, but they didn't pull a goal back until the 88th minute through substitute Hector Sam.
Cardiff then had to endure a desperate four minutes of added time as the Dragons tried hard for the equaliser.
But it didn't arrive, and Denis Smith's side stay in relegation trouble just one of the bottom of the table.