A judge has tossed the $10 million defamation lawsuit of a drowsy Yankees fan who sued ESPN for mocking him on air when he fell asleep in his seat during a home game.

Used car salesman Andrew Rector had claimed that ESPN announcers Dan Shulman and former Major Leaguer John Kruk defamed him by showing his image and riffing on the lop-headed, dead-to-the-world nap he took during a July 2014 Yankees-Red Sox game.

The judge agreed that Shulman and Kruk did marvel at Rector’s ability to sleep through the standing ovation that followed a Carlos Beltran homer, and made a passing comparison to the sleeping fan’s girth and that of the hefty Kruk.

But Rector was on camera for only a total of 31 seconds, the judge noted in her decision, first reported by The Smoking Gun.

The announcer’s comments lasted barely longer than a minute, and did not rise to the level of defamation, which requires “extreme and outrageous conduct [which] intentionally or recklessly causes severe emotional distress to another,” wrote the judge, Bronx Supreme Court Justice Julia Rodriguez.

Click for more from NYPost.com