|Bath (16) 33|
|Tries: Mercer 2, Bayliss Cons: Wilson 3 Pens: Wilson 4|
|Sale (18) 32|
|Tries: Solomona 2, Yarde Con: de Klerk Pens: de Klerk 5|
Makeshift fly-half James Wilson held his nerve to kick Bath to a narrow victory over Sale, converting Zach Mercer's try with 30 seconds remaining.
Wilson was only wearing the 10 shirt with Rhys Priestland, Freddie Burns and Josh Lewis all injured but he kicked 18 points as Bath snuck home at the Rec.
Sale looked on course for victory after winger Denny Solomona went over either side of Marland Yarde's try.
But Mercer and Josh Bayliss scored for Bath before Mercer's second won it.
The win kept Bath firmly in the race for the play-offs, as they bounced back from last weekend's humbling defeat at Newcastle to move up to fifth in the table.
Returning Wales number eight Taulupe Faletau burst into space and sent Mercer over for Bath's first try before 20-year-old Bayliss scored for the first time in the Premiership and Mercer dived over from close range with time running out.
Sale failed to make ground on the top four but scored a fine first-phase move from a line-out on the Bath 22 that sent Yarde into the corner.
And Solomona produced the pick of the game's tries as he kicked in behind the Bath defence and gathered to score his side's third try - but it was not enough for victory.
Bath coach Stuart Hooper told BBC Radio Bristol:
"There's performances and there's results and that was a result.
"There were things we didn't do very well, but credit to the lads.
"Across the season Sale's defence is up there with the best in the Premiership, so to break them down and score three tries is credit to the lads and they should be proud of getting the win."
Bath: Atkins; Brew, Hurrell, Tapuai, Vuna; Wilson, Fotuali'i; Obano, Batty, Thomas, Garvey (capt), Stooke, Mercer, Bayliss, Faletau.
Replacements: Van Vuuren, Noguera, Lahiff, Charteris, Phillips, Cook, Wilson, Homer.
Sale: Haley; Solomona, Addison (capt), James, Yarde; James, De Klerk; Harrison, Webber, John, Beaumont, Ostrikov, Ross, Curry, Strauss.
Replacements: Jones, Flynn, Tarus, Nott, Neild, Cliff, Charnley, Redpath.
Referee: Ian Tempest.