One strategy that's worked for me is to introduce primary villains that are often weaker than the party but cannot be directly defeated. For instance, in a previous campaign the arch-villain was a wealthy and influential merchant who was well-loved by the populace for his leniency, generous loans to the impoverished, and support of the monarchy and goodly-aligned church. He did, however, come to hate the PCs because of their capacity for collateral-damage and frequent disregard for what I call the misdemeanor laws of the community (when heroes believe their should be special rules for special people), and he worked tirelessly to have their adventuring discredited as borderline grave-robbing and highway robbery. When the PC's tired of this harassment (after their loot was being severely taxed since they'd taken it from some noble family's crypt) the PCs outright killed the merchant which lead to the citizens and eventually the whole apparatus of the state attempting to hunt them down.