Late points by Conor McManus and Colin Walshe helped Monaghan beat Cavan in a tight Ulster Football first-round tie at Breffni Park.
Cavan led 0-9 to 0-7 at the interval and extended their advantage to 0-13 to 0-9 midway through the second half.
However, Monaghan reeled off five points in a row in a 10-minute spell to hit the front after 60 minutes.
Martin Dunne scored a late free for Cavan but Monaghan held on to set up a semi-final against Fermanagh or Antrim.
The sides were level five times in a gripping first half, after which Cavan led by 0-9 to 0-7 having had the wind.
Although only five of the 16 points scored in the opening half were from play, with Cavan managing four of them, this first-round tie made for compulsive viewing.
McManus landed the first of his seven points with a second-minute free but Cavan took over with four points in a row.
Cian Mackey and Niall McDermott converted frees while Michael Argue, unexpectedly stationed on the edge of the square as a target man, turned Drew Wylie and fisted over the bar.
Monaghan responded with a four-in-a-row of their own in a seven minute spell.
McManus and Paul Finlay nailed frees while McManus then turned and twisted to beat Fergal Flanagan and slot the ball over the bar with his left foot.
Raymond Galligan, who plays as a forward for his club, was a surprise replacement for Conor Gilsenan in the Cavan goals and converted a free from 50 metres to restore parity for the home side at five points apiece.
Cian Mackey skipped through a few tackles to fire one over from close range and although Finlay equalised from a dead ball, Cavan hit two late points from Ronan Flanagan and Gearoid McKiernan to open up a 0-9 to 0-7 interval lead.
Dermot Malone was black-carded for Monaghan after 40 minutes, with Cavan's Martin Reilly following 18 minutes later.
The free count was almost two to one in Monaghan's favour and the home side were aggrieved at a number of frees in the middle third that went against their team in the second half.
The home side still led by 0-13 to 0-10 with 20 minutes to go but Monaghan used all their experience and composure to turn the game around, hitting five points in a row in a 10-minute spell.
Dessie Mone was annoyed he didn't receive a penalty in the 49th minute when he seemed to be impeded by Thomas Corr in the square
The brilliant McManus hit a free with Darren Hughes and sub Dick Clerkin scoring before Mone popped up with the leveller after 57 minutes.
Kieran Hughes's free nudged them in front after 60 minutes by 0-14 to 0-13, the first time they had led since the 23rd minute of the game.
Even though Cavan sub Martin Dunne levelled the scores again with four minutes remaining, Conor McManus replied immediately with a special score from out on the wing.
Monaghan's strong bench was a factor late on.
Walshe, in his first appearance since suffering a cruciate knee injury against Dublin in last year's All-Ireland quarter-final, popped up with a point to put them two points clear in stoppage-time.
Dunne's free deep in injury-time drew Cavan to within a point, but it was the last kick of the game and Monaghan booked their place in the Ulster semi-final.
Cavan: R Galligan (0-1, f); J McLoughlin, R Dunne, R Flanagan (0-1); J McEnroe, F Flanagan, D O'Reilly; T Corr, G McKiernan (0-2); D McVeety, M Argue (0-2), M Reilly; C Mackey (0-2, 1f), N Murray, N McDermott (0-4, 4f). Subs: C Brady (0-1) for McEnroe (38), M Dunne (0-2, 1f) for O'Reilly (52), M Lyng for Reilly (BC, 58), T Hayes for Mackey (66)
Monaghan: R Beggan; D Mone (01-), D Wylie, R Wylie; F Kelly, V Corey, K O'Connell (0-1); N McAdam, S Carey; R McAnespie, P Finlay (0-3, 3f), D Hughes (0-1); D Malone, K Hughes (0-1, f), C McManus (0-7, 5f). Subs: S Gallogly for Malone (BC, 40), C Walshe (0-1) for Carey (43), D Clerkin (0-1) for Finlay (50), C McGuinness for McAnespie (53)
Referee: Padraig Hughes (Armagh)