Kieran Martin's late goal capped a dramatic Croke Park comeback that secured the inaugural Tailteann Cup title for Westmeath.

Three points down approaching the hour mark, Jack Cooney's side looked in real bother but reeled off an unanswered 1-04 - the goal a terrific 67th minute solo score from substitute Kieran Martin - to pinch the silverware.

Sam McCartan also contributed two important late points while Ronan O'Toole's 61st minute score was his fifth of the day and capped a Player of the Match performance from the Mullingar man.

Cavan were tournament favourites and looked all set to deliver on their billing when they led by 1-13 to 1-10 late on but the 58th minute dismissal of 2020 All-Star midfielder Thomas Galligan was a huge blow.

Westmeath took full advantage and as a result of the tournament win will be exempt from next year's competition.

Both sides made late alterations to their published line-ups with Sam Duncan coming into the Westmeath team for Nigel Harte and Cavan's Niall Carolan replacing veteran Martin Reilly.

That required a reshuffling of bodies and positional switches in both teams with Duncan lining out in Westmeath's midfield next to Ray Connellan and Carolan playing in the Cavan defence.

The early match-ups were intriguing; Carolan picking up Westmeath forward Lorcan Dolan and fellow Cavan defender Killian Brady on dangerman John Heslin.

James Smith, wearing number nine for Cavan, started in their full-forward line and was picked up by Westmeath captain Kevin Maguire while David Lynch, wearing number 12, was handed a man-marking job on Cavan centre-forward Gearoid McKiernan.

It was high quality fare from the off and the sides were level four times up to 0-06 apiece in an entertaining opening half.

O'Toole scored four of Westmeath's first six points and, similar to his strong start against Kildare at the same venue in the Leinster Championship, was virtually unmarkable in this period.

Back-to-back McKiernan points for Cavan nudged the tournament favourites two points clear before they were hit with a body blow in the form of a Lorcan Dolan Westmeath goal.

O'Toole was centrally involved in the 28th minute major, the attacker cleverly holding up play on the left wing before arrowing a pass across the goal to Luke Loughlin who slipped but still got a pass away to Dolan who opened out his body and finished soccer style to the top corner.

Lorcan Dolan celebrates his first-half goal

Loughlin then pointed himself and punched the air in delight as Westmeath found themselves three points to the good.

A terrific half of football ended in suitable fashion with Cavan full-forward Paddy Lynch booming over a beauty from way out on the left wing to leave just two in it at half-time, 1-08 to 0-09.

Westmeath retained a two-point lead at the end of a humdrum third quarter before the game suddenly burst into life again.

This time it was all about Cavan who reeled off 1-02 without reply between the 53rd and 56th minutes to wrestle control of the game and put themselves in pole position.

Full-back Padraig Faulkner was the unlikely goalscorer when he pounced from close range after James Smith's ball in from the left broke down kindly to him.

Leading 1-13 to 1-10, it was Cavan's game to lose and, remarkably, they did just that with Galligan's 58th-minute departure following a straight red card for a high challenge on O'Toole, a huge turning point.

The sides were level at 1-13 apiece when Martin then struck Westmeath's second goal though Cavan had an opportunity to level through one of their own subs, Conor Madden.

His 72nd minute shot was expertly blocked by Westmeath skipper Maguire, however, and the Lake County went on to strike an insurance score from Ronan Wallace, sealing the four-point win.

Westmeath: Jason Daly; Jamie Gonoud, Jack Smith, Kevin Maguire; Ronan Wallace (0-01), David Lynch, James Dolan; Ray Connellan, Sam Duncan; Sam McCartan (0-03, 0-01 45), Ronan O'Toole (0-05), Jonathan Lynam; Luke Loughlin (0-02), John Heslin (0-03, 0-02fs), Lorcan Dolan (1-00).

Subs: Ger Egan for Lynam (58), Kieran Martin (1-00) for Lorcan Dolan (60), Alex Gardiner for Loughlin (70).

Cavan: Raymond Galligan; Niall Carolan, Killian Brady, Padraig Faulkner (1-00); Jason McLoughlin (0-01), Conor Moynagh, Conor Brady; Thomas Galligan, Killian Clarke; Oisin Kiernan (0-01), Gearoid McKiernan (0-03, 0-01f), Gerard Smith (0-03); James Smith (0-01), Paddy Lynch (0-03), Cian Madden.

Subs: Stephen Smith (0-01) for Madden (ht), Martin Reilly for Conor Brady (51), Luke Fortune for Moynagh (66), Cormac O'Reilly for Killian Brady (71), Conor Madden for Clarke (71).

Referee: Barry Cassidy (Derry).