Leyton Orient scored twice in three second-half minutes to end Notts County's 22-game unbeaten away run.
Notts, who had to bring on substitute goalkeeper Fabian Spiess early on to replace the injured Bartosz Bialkowski, edged the first half and hit the bar through Yoann Arquin's header.
But the O's improved after the break and led through David Mooney's header.
Mathieu Baudry volleyed a second and the hosts held on despite a close-range Jeff Hughes strike.
Hughes's effort, after Alan Sheehan's strike was blocked, gave hope of preserving manager Keith Curle's remarkable record of not having lost away from Meadow Lane in his 11-month reign.
But they were unable to create a decent opportunity in the closing stages.
Notts had started brightly and although their rhythm was disrupted by the eight-minute delay following Bialkowski's head injury on 19 minutes after a late sliding lunge from Charlie McDonald, they still looked the more likely to go ahead.
As well as Arquin's effort from Andre Boucaud's cross, Enoch Showunmi also had a header cleared off the line.
But the O's seized control after the interval and Spiess made a couple of fine stops before Mooney headed them ahead after the German-born keeper, who was making just his second Notts appearance, did well to deflect Lee Cook's strike onto the bar.
Baudry quickly slotted number two from close range following a Cook corner.
Referee Lee Collins was then forced off injured after pulling a muscle, adding another five minutes of stoppage time.
But Hughes's strike on 78 minutes could not inspire a comeback.
VIEW FROM THE DRESSING ROOM
Leyton Orient boss Russell Slade told BBC London 94.9:
"We worked very, very hard to get the win and after their substitute keeper came on I thought we wouldn't beat him as he was saving everything, but we got the goal and that settled us down.
"A games unbeaten away run is a terrific effort, but we earned it today.
"The lads deserved that as the effort has been phenomenal and if you are a neutral you've got your money's worth."