Naturally, it’s going to be subjective. And I wouldn’t want to raise any spoilers by mentioning ill-fated characters by name.
I’ve just finished E.M. Forster’s Where Angels Fear to Tread. Forster was in his early twenties when this was published (1905). He kills off a main character by page 100 (in a 160 page book). The death was necessary for the tragic plot.
In the midst of life there is Death.
Not only literary fiction opts for the tragedy of a main character dying.
James Clavell did it most powerfully in his oriental epics, Tai-Pan and Shogun. These deaths were all the more shocking after wading through hundreds of pages with the tragic character.
David Baldacci did it in his first novel, Absolute Power (though the screenwriters decided not to kill off their star, so changed that aspect in the movie!) This was quite a surprise when I first read it; it worked, but jarred and pulled me out of the story.
Arthur Conan Doyle attempted killing off Sherlock Holmes, but he had to bring him back from the dead due to popular demand – in the days before pressure groups, fan clubs and fan websites!
And we mustn’t forget that Cervantes killed off Don Quixote, (I’ve mentioned him by name because I feel that anyone who has heard of Quixote also knows his fate).
Neville Shute kills off his main character right at the outset in Requiem for a Wren. This works, as we know from the beginning. The title helps, too! So there’s no sense of being cheated, though the ending is moving as the reader mourns a life lived.George R.R. Martin is quite ruthless with his Game of Thrones characters – but the deaths he depicts reflect the violent mythical society he’s writing about. And, what’s more, the deaths echo through the hearts and minds of the survivors in subsequent tomes.
Most famously, J.K. Rowling killed off a number of main characters. She wrestled long and hard over a few nights when the necessity of these deaths proved inevitable. Necessary deaths, otherwise, the threat doesn’t seem dire enough, real enough, for those who survive.
I killed a main character in Bullets for a Ballot. Because I wanted to write a tragedy that happened to be a western. And I’ve done it again in next year’s release, The Magnificent Mendozas.
There are countless examples, I’m sure.
So, I would advocate not to hesitate about killing off a main character, so long as it isn’t gratuitous.
In the final analysis, however, the majority of readers tend to want the hero – or heroine – to survive at the end. There’s a sense of feeling cheated when you encounter the death after travelling through thick and thin for many hours and pages.