They can confirm their place in the top flight of the County Championship providing they pick up enough points from their match with Warwickshire, which gets under way on Tuesday.
Lancashire are six points ahead of Warwickshire and 14 in front of Hampshire, who occupy the remaining relegation spot.
Lancashire coach Ashley Giles said: “A 14 point advantage over Hampshire is a nice cushion, but a win for them means we’ve got to get a lot of bonus points. So there’s all to play for.”
Middlesex will need to win their final match against Yorkshire to guarantee a first County Championship title since 1993.
Blackpool fan hit with THREE-YEAR ban as authorities clamp down on pyrotechnics
Ticket allocation for Blackpool's Lancashire derby against Burnley revealed
Fleetwood Town boss praises Morecambe striker as Cod Army front man heads to Port Vale
Blackpool's cup humbling won't impact players against Swansea City, according to Michael Appleton
Wigan remain Championship relegation candidates but bookies' odds drift for Preston North End and Blackpool
Resuming on the final day with a lead of 140, David Malan and John Simpson’s stand of 151 provided the backbone of Middlesex’s second innings 259 for eight declared, which set up a chase of 309 from 44 overs.
Malan and Simpson had come together with their side wavering on the third afternoon, but had dug in to reach stumps and it was more of the same against high-quality bowling from Simon Kerrigan (who finished with six for 86, and match figures of 10 for 166) and Kyle Jarvis.
Both batsman waited for the bad ball, and made it through the morning session unscathed, recording elegant half-centuries.
Malan, having smacked the Lancashire captain Steven Croft down the ground for six, reached his half-century from 128 balls, with five fours. Simpson, playing busily and repelling impressive turn from Liam Livingstone’s leg-breaks, brought up his own 50 with a cover driven four off Kerrigan, from his 150th ball.
Both fell as Middlesex looked to push on after tea. Malan reached 87 before edging behind trying to cut Kerrigan, while Toby Roland-Jones sliced to point and James Franklin was caught at long-on, also both to Kerrigan. Simpson fell shortly before the declaration arrived, bowled by Luke Procter.
Lancashire opted to promote Jos Buttler, England’s interim ODI captain, to open the batting ahead of Haseeb Hameed. Buttler was immediately into his work, carving his first and third balls from Steven Finn for four through the off-side, and unfurling an array of ramps and scoops. After nine balls, he had 24, while his partner Rob Jones - a first-innings centurion - was still on 0.
But Buttler tried to flick Finn to leg and was caught by Nick Compton at cover, departing with all 26 Lancashire runs to his name. From there, Jones, 20, and Hameed, 19, dropped anchor and batted out impressively for the draw.
There were some dashing strokes, particularly from Jones down the ground to Ollie Rayner, while Hameed nudged and nurdled until Middlesex captain Franklin offered a handshake at 4.30pm.
Both batsmen ended with 25 as Lancashire reached 80 for one.