All players worry about character death. With a slash of a sword or a lucky goblin's crossbow bolt, all those experience points will go to waste. However, as a DM, it's our duty to occasionally kill a player.
Death is needed
However tempting it is to pull your players out of the fire, without character death, the adventure loses its luster. If a character cannot die, there is nothing to properly challenge the players. The darkness surrounding your points of light becomes just a shadow, something to merely bother and not terrify.
Death should be based on player agency
The trick for the DM is to ensure that such deaths are not meaningless. Hopefully the player's character will die to make a difference, save the party, or will have ultimately decided to do something very stupid.
Unless your campaign is designed as a meat grinder, you do not want a death to be cheap. For example, If every time your characters miss a trap, someone dies, your players will exhibit unproductive paranoid behavior that will eventually wear down the campaign. You want a death to be an extension of the characters actions and choices, even of those choices are overly noble or foolhardy.
Furthermore, the death of a character doesn't have to be something that happens when a monster gets lucky, players can always collude with the DM to make the death of their character memorable and dramatic.
You should set the tone with your players. You should ensure that everyone at the table understands the lethality level of the campaign. Are the PCs mostly going to live if they don't do something stupid? Are the "safeties off" and will the denizens of the campaign use every rule in an attempt to end the life of our adventures? Answers to these questions can help the players make sense of the world around them and help prepare for the inevitable.
Example: My Own Experience
Several years ago, my character, Malik, was escorting a Half-Orc Prince through a forest to see his father, the local chieftain. The orcish hordes were bearding down on the local populace, and this was the last, best hope to negotiate a peace.
Suddenly, a dozen orcs revealed themselves and shot at the prince.
"The arrows hit the Half-Orc and he dies..." Stated the DM.
"Wait, I dive in front of the prince to block the arrows." I said
"Interesting. Well", the DM retorted, grabbing fist of of d6's, "are you sure you want to do that?"
I paused and then nodded ascent. "It is what Malik would do."
Too many arrows to count slammed in to Malik, although his armor stopped some of them, most found their way into the soft flesh below. He was probably dead before he hit the ground. It was at that moment, the orcs realized at whom they were shooting, and stopped. The other heroes managed to complete the escort and negotiate a truce, saving the villages from the orc menace.
This death was a good death. It was, ultimately, my choice and the DM sought confirmation with the infamous "are you sure?". The death also had meaning. It substantially helped out the party and saved the surrounding areas from the orc menace.