Just have the villain win sometimes.
Obviously, there are certain victories that would render the premise of your series irrelevant and bring it to a premature end. What those are will depend strongly on the story: the villain killing or incapacitating the primary protagonist will often mean their complete victory, or at least a story that no one will be interested in watching afterward, but not always—for instance, on The Vampire Diaries TV show, the primary protagonist, Elena, was incapacitated and rendered an effective non-entity in the plot two seasons before it ended.
But most villain victories do not negate the premise of the series, so they can safely be used in moderation (too much, and you end up with a villain protagonist, viewer apathy, or both). For instance:
If the villain is a sadistic type who likes hurting or killing people, then any suffering they cause is a victory for them. The nearly invulnerable superhero protagonist may never be in any real danger, but if the villain kills a few (or a few million) people, they've won even if the hero foils their even worse plans, or even if they imprison or kill the villain. Or maybe there are no worse plans, and the villain just gets away with it this time.
If the villain is arrogant and believes themself untouchable, then any situation in which they escape unscathed is a victory for them. Think of the corrupt billionaire CEO whose company has been selling dangerous products—sure, the hero exposed the products' risks and got them pulled, but the CEO is still out there, still rich and powerful, and still enjoying their ill-gotten gains at the expense of everyone else no matter how many times the protagonist inconveniences them. A bit of gloating works wonders here: "Do you really think I care about a few millions lost when I made billions last year?" Or perhaps the hero fails altogether: the product continues on the market and the CEO suffers no more than a small inconvenience.
If the villain has a concrete goal, let them achieve it sometimes. They just want to stop the protagonist because they protagonist is in their way, so the protagonist surviving, or even defeating them in a fight (physical or otherwise) is still a loss if they get what they were after: the magic artifact, revenge against the people who killed their parents, a political office, a great deal of money, the respect of the general public.
Because we identify with the heroes, even if they defeat every single aim that the villain may have, the villain can still win a victory if they injure, incapacitate or kill someone on the hero's side, particularly if that loss is permanent. If you think the show cannot continue without the protagonist, then perhaps the villain can occasionally take out an important but secondary character; if you are daring, and the show has an ensemble of well-developed protagonists, the villain can even eliminate the main protagonist (but do be aware that the audience may really dislike this). Conversely, on the lighter side, the villain can permanently reduce the protagonist's capabilities: cut off their arm, smash their weapon, steal all of their money, dissipate their powers, burn their house down. The hero has still lost something—not only something that they will miss, but something that will probably make them lose again, or at least struggle mightily to win.
In a more depressing work, this last strategy can effectively amount to the villain wearing the protagonist down, until after enough confrontations that they "won," the protagonist has taken enough damage that the villain wins some kind of lasting victory, even if it can be framed as an overall protagonist victory in the end: perhaps the villain finally kills the protagonist but their goals are defeated, or vice versa. This is related to the strategy of escalating villain threat rather than villain decay—the villain achieves more of their goals, and larger ones, up until their final defeat (unless they win....) not fewer. The villain takes more away from the hero up until they finally lose, not less. We start with an optimistic, powerful protagonist confronting a villain who barely is an annoyance, and end with a protagonist giving their all to defeat a villain who has achieved almost everything they wanted and taken everything from them.
The key in any of these cases is to really convey to the audience, emotionally, that the villain has won this time, which is a matter of emphasis and tone more than a matter of facts. A New Hope frames its plot as a straightforward victory for the heroes because the emphasis is placed on the ruination of the most destructive of the Empire's plans, but a slightly different framing could turn it into a depressing villain victory: Leia failed to prevent the deaths of billions of her people and is now without a family or a planet, Luke lost literally everyone who ever mattered to him, and the Empire is just building another Death Star, with the protagonists' continued survival having been bought at a high cost in Rebel and Imperial lives.
Show that the characters believe that they have lost, and that the villain believes that they have won, backing it up with facts that make this point of view plausible, and the audience will agree with them. And if the villain sometimes wins, and the protagonists cannot fully prevent these victories, well, we can see why the villain is still a threat.