The Thunder completed the double over the Diamonds to knock their arch-rivals out of contention as they defended a target of 155 to win by nine runs.
Their first win in five games and their fourth from nine in all owed a lot to India T20 captain Harmanpreet Kaur’s superb 74 off 44 balls as they posted 154-9 having been inserted.
Yorkshire then slipped to 70-4 in the 12th over of their chase before England all-rounders Alice Davidson-Richards and Katherine Brunt revived hopes with a fifth-wicket stand of 61 in 37 balls.
But the Diamonds failed to get 19 off the last over, with the Diamonds finishing on 145-8 and Brunt unbeaten on 44 off 25.
Lancashire travel to the Ageas Bowl to face Southern Vipers on Saturday (7pm) knowing they have to win and hope Surrey Stars lose to Western Storm at the Kia Oval. The Thunder are currently three points behind the third-placed Stars.
Yorkshire coach Paul Grayson said: “We missed a big opportunity to get Kaur early on, and that’s been a bit of a story of our campaign. There’s been big opportunities at various times. The word we’ve just used upstairs is ‘Frustrating’.
“Ten games and won two, it could have been so different with those big moments. We dropped her and she’s punished us. That’s what big players do.
“No one means to drop catches, it’s part of the game.
“I thought we bowled okay and fielded okay, and it was well within our reach to chase those runs on a decent pitch with a fast outfield against a team who have lost a few lately.
“I felt quite confident at the turn. We just needed someone in our top four to get 60 or 70. Then we may have won it.”
Lancashire’s Kaur said: “We were looking for that win after losing those games back-to-back. When we were bowling, I thought it was going to be one-sided, but Katherine Brunt batted well. But our bowlers did a good job in the last few overs.”