The character of Macheath in John Gay's The Beggar's Opera (1728) was based on Sheppard, keeping him in the limelight for over 100 years. He returned to the public consciousness around 1840, when William Harrison Ainsworth wrote a novel entitled Jack Sheppard, with illustrations by George Cruikshank. The popularity of his tale, and the fear that others would be drawn to emulate his behaviour, led the authorities to refuse to license any plays in London with "Jack Sheppard" in the title for forty years.