Alan Judge's late winner kept up Notts County's play-off charge and relegated Wycombe from League One.
Matt Bloomfield fired through Magpies keeper Stuart Nelson, but Daniel Bogdanovic stroked home an equaliser almost immediately.
Grant Basey's penalty put the hosts ahead after Stuart Beavon was felled, but Judge lashed in an equaliser.
Beavon's fine goal made it 3-2, but Dele Adebola headed in and Judge rattled home a dramatic winner.
County moved above Stevenage into the play-off places, but the Boro retook sixth place with a point against Sheffield United in the late kick-off.
Wycombe, whose hopes of survival looked genuine for long periods, will return to League Two next season.
Notts County manager Keith Curle told BBC Radio Nottingham:
"Even at 3-2 down after 89 minutes we knew the supporters were still with us and for us as a football club that's massive.
"I don't want to be a successful manager, I want to be part of a process of the football club being successful.
"Until that referee blows that whistle I still think there's something in store.
"There's something special in that changing room and there's a level of honesty about the players' play. There's team spirit in there that's growing."