Substitute Peter Thompson fired home from a couple of yards out in added time to seal victory for Linfield over nine-man Coleraine at Windsor Park.
Howard Beverland was sent-off for a second yellow card offence after 66 minutes, while ex-Blues defender Steven Douglas followed him to the dressing room on 82, also for two yellow cards.
Linfield had the better chances and made it five straight league wins.
David Jeffrey's side move up to third, one point behind leaders Portadown.
In a first half of few scoring opportunities, Ruairi Harkin blasted over and Niall Quinn saw a long-range effort fly wide.
Quinn went close again after the break but his low free-kick was pushed away by visiting goalkeeper Wayne Drummond.
Eoin Bradley brought a fine save from Jonathan Tuffey and then Coleraine skipper Beverland was red-carded.
The dismissal of Douglas put further pressure on the Bannsiders, who were forced into a desperate rearguard action.
Aaron Burns headed over when well placed before Thompson pounced to clinch all three points for the hosts.