In the ancient Greek play Antigone, Creon, the king of Thebes sentences Antigone to be buried alive in a cave for breaking his orders. Rather than starve to death, she hangs herself. When her fiancé, Creon's son learns that, he kills himself. When his mother, Creon's wife hears that, she kills herself. When Creon learns all that, he doesn't kill himself - he just becames very miserable.
Jocasta in Oedipus Rex, after she finds out her husband is her son.
In Hippolytus, Phaedra commits suicide after the goddess Aphrodite causes her to fall in love with her stepson, Hippolytus.
Io: What boots my life, then? why not cast myself Down headlong from this miserable rock, That, dashed against the flats, I may redeem My soul from sorrow? Better once to die Than day by day to suffer.
Ajax, after his madness dissipates, is in such a state of dishonour that he cannot allow himself to try and reconcile with the Greeks in Ajax, in spite of the pleas of his family and friends. He tricks them into thinking is is fine but then goes off to commit suicide on Hektor's sword.
Deianira of The Trachiniae kills herself with a sword on her marriage bed after she realizes her agency in fatally wounding her husband, Herakles.
In Hamlet, the famous "To be, or not to be" line is from a soliloquy of the title character after he found that his uncle Claudius had killed his father Hamlet Sr. and had married his mother Gertrude, and comparing the shock to that of someone contemplating suicide. One interpretation is that Ophelia's death really is a suicide.
Third example from Hamlet is Horatio, who attempts to die with Hamlet by drinking the remainder of the poisoned wine that killed Gertrude. Hamlet has to wrestle the chalice away from him and talk him into living. It's not the most inspiring speech, but it works.
Also from William Shakespeare, in King Lear, after Gloucester is blinded, he asks someone to take him to a cliff so he can jump off. The disguised Edgar takes him up on it, but tricks him into thinking he's at a cliff when really he's on a flat plain. It can be hard to direct; after all, if not pulled off correctly, the scene can just fall flat on its face.
Romeo and Juliet both kill themselves at the end, Romeo because he wanted to join Juliet in death (but tragically, he didn't know that Juliet was only Faking the Dead because the information that Friar Lawrence had intended for him never arrived), and Juliet because she wanted to join Romeo in death.
Some productions make Tybalt's death more or less a suicide too- his slaying of Mercutio is sometimes played as unintentional, and Tybalt is shocked enough by what he's done that he lets Romeo kill him.
Most of Shakespeare's Tragic Heroes and villains qualify for this trope. Macbeth was one of the exceptions, as his death was in battle against Macduff rather than by his own hand. His wife, however...
Floria Tosca of the opera Tosca throws herself off a tower after a harrowing Break the Cutie ordeal that ends with her being forced to accept the original Scarpia Ultimatum to keep her lover Mario Cavaradossi from being executed, killing Scarpia before he can rape her, and then finding out that he had ordered Mario's real execution instead of the false one he had promised her if she agreed to it.
Madame Butterfly, in its tragic tearjerking finale, has poor Cio-Cio-San committing seppuku with the dagger given to her by the Mikado after learning that her lover Pinkerton is not coming for her like he promised her he would and that he has married another.
And the Broadway interpretation Miss Saigon does something similar, when the protagonist shoots herself both in despair over the loss of Chris and to force him to take their son Tam back to America with him.
Katerina in Shostakovich's Lady Macbeth of the Mtsensk District, having painted herself into a Failure Is the Only Option corner, jumps into a frozen lake. Britten's Peter Grimes is similar.
Subverted in Alban Berg's Lulu. Dr Schön forces Lulu to kill herself after he finds out about her affair. She kills him instead.
Averted in Mozart's Magic Flute. Pamina keeps the knife her mother gave her to kill Sarastro. She instead encounters Tamino, and believing he has rejected her (he's in the middle of a trial of silence so can't talk to her), Pamina wanders off in a mad stupor calling the knife her "bridegroom". The Three Spirits manage to save her in the nick of time.
Magda Sorel in The Consul, having failed after many visits to get the Secretary to give her something besides paperwork, gasses herself to death at home.
Richard Wagner's Tristan und Isolde has Isolde requesting a Potion of Death in the first act. When she drinks it, it turns out to have been switched with the Love Potion.
The Children's Hour': Martha actually does commit suicide after the rumor of her being a lesbian becomes too much.
To specify: She considers her and her best friends lives ruined because of said rumor, a rumor that occured because she did have feelings for Karen. Karen's fiance leaving her due to doubting her fidelity only made everything worse. Combine this extra stress and guilt with the fact she's a lesbian in The Twenties, possibly The Thirties, and the fact she has an unrequited love and...
Henrik Ibsenloved this trope. He wrote suicidal characters in A Dolls House, Ghosts (assisted suicide), The Wild Duck, Rosmersholm, and Hedda Gabler. Not all of them go through with it, but for those five plays, the final tally is: 4 suicides in the text, 1 in the backstory, and possibly 2 others, depending on your character interpretation. As great a writer as he was, Ibsen really could have used a hug.
Rosmersholm stands out with the highest suicide rate in any play written by Ibsen: Beate Rosmer (before the play started), Ulrik Brendel, Rosmer himself and Rebekka West - four, with two remaining cast members left alive at the very end.
Mariane in Moliere's Tartuffe declares that she'll kill herself - with a pair of sewing scissors, no less - since her father is making her marry the eponymous Jerk Ass. Her maid intervenes.
Christine and then Orin in Mourning Becomes Electra.
Moritz Stiefel in Spring Awakening. He's a decent, hard-working kid trying to deal with schoolwork and his parents making him feel like a total pariah at home when he doesn't get top marks, plus guilt and shame over his changing body and sexual urges. He seems to get a break when he finds out he passed the midterms. Whereupon they fail him anyway because the school can't pass everyone. He then appeals to his best friend's mother, who apparently doesn't give a poo about his angst and ignores his cry for help, and his parents - well... After that, a (female) childhood friend offers him comfort, but he's so conflicted, he refuses and she storms off, very hurt. And then the poor boy puts a pistol in his mouth. And most of the audience walk away with broken hearts.
S.P. Miskowski's my new friends (are so much better than you) is based on the forementioned Real Life tragedy of Megan Meier, who hanged herself after being bullied by a friend's mother masquerading as a teenage boy named Josh Evans on MySpace.
In Marsha Norman's 'night, Mother a woman nonchalantly tells her mother she's planning to commit suicide that night, leading to a long dialogue in which Mama tries to talk her out of it. Mama is unsuccessful.
Ajax in The Golden Apple jumps out a window after squandering his friends' money by unwisely investing it in hemp.
Jason in bare: a pop opera. He's feeling so much angst about being gay, he got Ivy pregnant, his friends have left him and when he asks Peter to run away with him, Peter refuses and says he can't hide anymore. The audience is left drowning in their own tears.
In the backstory of Rent, Roger's girlfriend April slit her wrists after testing HIV-positive.
In Jesus Christ Superstar Judas hanged himself shortly after betraying Jesus.
In Dorothy L. Sayers's The Emperor Constantine, Maximian. Or so one soldier recounts to another, who doesn't believe it — Maximian had tried to assasinate Constantine, and Constantine only threw him in jail? Much more likely he was disposed of.