The holders rued a number of missed chances in the second half to be one of several Clydesdale Bank Premier League casualties in the second round of the competition.
A Brown Ferguson penalty and John Gemmell's header put Stenny two up at the break and the Irn-Bru Scottish Second Division part-timers held on for a famous win despite Michael Nelson's late reply.
Hibernian suffered more woe in their first cup tie since their Hampden thrashing by Hearts in the Scottish Cup final as Queen of the South sent them out with a 2-0 win at Palmerston.
Nicky Clark, son of former Hearts striker and current Queens assistant Sandy Clark, put the Dumfries side on their way to a thoroughly-deserved victory with a close-range finish on 12 minutes. Substitute Gavin Reilly added a second with a diving header in the 42nd minute.
Raith Rovers caused a major upset by thrashing Ross County 4-1 at the Global Energy Stadium.
Brian Graham netted in either half and Greig Spence and Dougie Hill got the others as the Division One outfit ran County's makeshift side ragged.
A late Russell Duncan goal was all the home side could muster on a night to forget for the SPL new boys.