I actually kinda like tension breakers, despite their bad reputation (see: MCU criticism) and I use them all the time. ^^; Like, for example, there's this one in one of the later chapters of a novel I just finished:
“I feel like a lot of things...are missing, in my head…”
“Your local memory must have deteriorated quickly while you were unconscious...and by the time His Eminence successfully installed your new brain, much had already been lost.”
“...Oh…well...at least now that won’t happen again, right...?”
“Indeed. The mind you have now will serve you well until your dying day...as long as the duct tape stays on.”
“...What??”
“Here is the exit. Will you be needing any further assistance?”
Like, this character having their brain replaced is not only one of the most important moments in their story, but also a pivotal event in the history of the world it takes place in, essentially a paradigm shift that leads to the collapse of civilization. And in this short scene we learn it was accomplished with duct tape and willpower. XD
The whole story is filled with things like that, namely to help the actually serious (i.e. personally important to the characters) scenes stand out from all the stupid. ^^ Nevertheless, doing it constantly from the very beginning of the story helps it feel less out of place later on.
Another thing that helps tension-breakers feel less like "this author is afraid to take their story seriously and let their characters' emotions feel genuine" (which I think is a legitimate criticism that definitely applies in some cases...) is to realize that there are different kinds of tension breakers. You have more options than just throwing in a goofy quip or a sarcastic remark. You can:
Change to a different negative emotion: Using anger, fatigue, or even sadness in a comedic way can help break the tension in a way that still feels in-character, and/or help gently guide the viewer into seeing the humor in what just happened, rather than essentially holding up a "PLEASE LAUGH" sign.
For example, this short film script I'm working on is 90% comedy, but near the end the main character gets shot and loses a limb. And I thought a fun way to reset the tone after that would be to have him start ugly crying about how now all his fancy clothes won't fit right anymore. ^^
Throughout the story, he's always been a shallow, superficial person, so this concern suits his character. And it also suits pretty much anyone's character to be devastated about losing a limb. It's the way you play it that makes it funny, breaking the tension in a more subtle way.
Underreact: This is probably the easiest strategy to use, and one I also used in the novel I quoted above. There's a discussion between the same 2 characters where one is telling the MC all about the secret background of 'His Eminence' and the more serious aspects of the worldbuilding that they should probably be invested in, and they're just like "...Ok". Because they're already too depressed about something else to pay attention. ^^
Not only is this an imperceptibly smooth way to break the tension, it also helps lend some realism to the character: they're not gonna stop caring about the death of their friend just because it's Important Lore Time. Unlike most other tension breakers, this one redirects your attention TOWARDS the character's emotions, rather than dismissing them.
I've already said a lot, but I just have to give a very successful example of this, that happens to be one of my favorite scenes in the show it comes from (Season 1 of the most recent Lost in Space adaptation).
So the mother and father of the family at the center of the plot have always had a lot of tension between them (I think they were divorced and/or separated before the start of the story...), even though they're emotionally mature enough to work together well in this life-threatening situation they're in. But gradually, all this time they spend working together starts to soften them up, rekindling their relationship.
Later on, they end up alone together in an even more life-threatening situation-- they are trapped in an enclosed vehicle at the bottom of a tar pit, running out of oxygen. After taking some time to think (and discussing some nostalgic family history~), they realize they have one spacesuit with them, which the father decides the mother should use to escape. Even though the moment she opens the door, the vehicle is going to fill with tar, immediately burning him to death.
She's opposed, they argue about it a little, but they agree that at least one of them should survive to protect their children, and the father refuses to budge. Since the mother is a world-class scientist and he isn't, he feels her survival is more important to everyone's future. Tearfully, she agrees to the plan, and for a while the viewer is left waiting to see if one of the main characters is actually going to sacrifice himself.
But then, at the last second, she finally comes up with a new plan to save them both: they use a tank of helium and a tarp to create a sort of inflatable tunnel they can use to crawl out of the pit. And they do this, and they cut themselves out at the surface, and they collapse on the shore all sweaty and oxygen-deprived and glad to be alive...and then they say "I love you" in these ridiculous squeaky voices (because of the helium!) and instantly burst out laughing. XD
And it's like taking a big cathartic sledgehammer to all the episode-long tension of this subplot; it feels amazing, so much so that I can't help laughing with them. ^^ A+ writing, acting and directing; 10/10~