Courtesy of Jim R Stephenson Photography
Welcome to the A to Z Challenge! You can visit the A to Z Homepage HERE.
There are a number of situations in which it is okay for the protagonist to die. The reasons vary, depending on whether the story is based on a real or fictional character, the time frame of the story and other considerations.
With fictional characters, it all depends on the author's future plans. If there is a series, and the author decides to end it, then he/she may allow the protagonist to die. That way, the story line ends. Sometimes this happens when the author does not want anyone else to continue the stories with his character after he/she is gone. Sometimes it happens when an author is tired of these characters and wants to move on.
Some stories are written so the protagonist dies a heroic death, fighting the antagonist. Other stories have the protagonist die and are reborn. In some stories, the death of the protagonist leads to another plane of existence. One writer of a fantasy series had the protagonist die in the beginning and the story revolves around his adventures in the world he enters.
So there are numerous situations in which it is acceptable for your protagonist to die. Besides, if you want to revive your character later, you can either write a prequel, or, if you can think of a logical and plausible way to do it, show that your character really did not die. It was just the readers perception at the time!