The Bond star has worked in theatre since the 1950s and has received seven of Britain's prestigious Olivier Awards - more than any other performer.
And in a poll by acting publication The Stage, the actress saw off competition from the man her accolades are named after to be crowned queen of the theatre.
After hearing the news, Dench said, "I'm completely at a loss for words but it's one hell of a thing to live up to."
In second place was Dame Maggie Smith, Mark Rylance was in third and McKellen in fourth.
Revered Olivier only made fifth on the list, followed by Paul Scofield, Sir John Gielgud, Sir Michael Gambon, Vanessa Redgrave and Sir Ralph Richardson.