Assassination of Robert Baratheon

"It wasn't the wine that killed Robert, nor the boar. The wine slowed him down and the boar ripped him open, but it was your mercy that killed the King."

- Varys chides Eddard Stark for causing Robert's death

The Assassination of Robert Baratheon was a pivotal event that preceded the War of the Five Kings.

Background
The relationship between the Starks and the Lannisters, which has never been friendly, becomes hostile due to the kidnapping of Tyrion; Jaime confronts Eddard about the kidnapping, and the result is a bloody brawl. Robert orders Ned (not very firmly) to have Tyrion freed and to make peace with Jaime. Cersei is filled with contempt toward Robert, for treating the situation so meekly and refusing to punish the Starks. Instead of using his authority to defuse the hostility between the houses, Robert leaves the capital to hunt in the kingswood.

As revealed later, Cersei comes up with a plan to dispose of Robert: she orders her henchman/lover Lancel to give Robert plenty of wine, in order to dull his senses and slow his reactions during the hunt.

Robert hunts in the Kingswood, accompanied by Renly Baratheon, Ser Barristan Selmy and his squire Lancel. Lancel, obediently following Cersei's orders, keeps offering wine to Robert, who drinks a lot.

In the meantime, Ned discovers why Jon Arryn was killed: he has found evidence which proved that Robert was not the father of Cersei's children, who were actually a product of incest between her and Jaime. Very foolishly, blinded by his self-righteousness, Ned arranges a secret meeting with Cersei and reveals to her that he knows the secret about her children. Cersei does not even bother to deny the accusation; she openly expresses her hatred to Robert. Ned warns Cersei that he will tell Robert the truth, and that she and her children must get as far as they can. Cersei departs with a chilling warning: "When you play the game of thrones, you win or you die. There is no middle ground".

Not surprisingly, Cersei decides not to accept Ned's "generous" offer, which means giving up her power position and luxurious life, and becoming a fugitive vagabond.

Robert's death
Renly informs Ned that Robert has been injured by a boar at the hunt. Ned enters Robert's chambers. Robert, lying near death, admits that he drank too much wine. He orders all the present people to leave, except Ned. Robert instructs Ned to write a letter, naming him as the Lord Protector of the Realm, to rule until Joffrey comes of age. Ned does not write Joffrey's name but "the rightful heir". Robert regrets about giving the order to kill Daenerys, and orders Ned to stop it, and help Joffrey to become a better man than him. Ned promises to do whatever he can to honor Robert's memory.

Ser Barristan tells Ned and Varys that Robert was reeling from the wine. Varys asks Ser Barristan who gave Robert the wine; Ser Barristan says it was Lancel. Varys comments sarcastically "Such a dutiful boy to make sure his Grace did not lack refreshment. I do hope the poor lad does not blame himself".

In private, Renly advises Ned to take Joffrey into their custody; he offers Ned a hundred soldiers for that purpose. Ned refuses to dishonor Robert's last hours by shedding blood in the Red Keep and taking frightened children hostage. Renly suggests that he could make a good king, but Ned sharply points out that Stannis is Renly's older brother and the true heir. Renly tries in vain to knock some sense into Ned's head, warning him that every moment he delays - gives Cersei another moment to prepare, and by the time Robert dies, it will be too late for Ned and Renly; Ned does not listen to him - another foolish mistake.

Ned writes a letter to Stannis about his findings and instructs Tomard to deliver it to Dragonstone. Later, Ned makes his third foolish mistake in a row by putting his trust in the treacherous Littlefinger, thus sealing his fate.

Soon afterwards, Ned is informed that Robert has died.

Aftermath
Renly's warning proves to be correct: as soon as Robert dies, Cersei does not waste time, but immediately sets the stage for Joffrey's coronation. Ned's attempt to foil her results in a bloodshed and his imprisonment.

Varys visits Ned in his cell in the dungeons. He is incredulous that Ned warned Cersei what he was going to do. Ned says he wanted to extend mercy to Cersei's children, whom Robert would have killed if he'd known the truth. Varys bluntly tells Ned that his mercy is what killed King Robert, to Ned's shame.

A singer named Marillion composes and performs a funny song about Robert and the boar. At Joffrey's order, Ser Ilyn Payne cut out his tongue.

Long afterwards, in Braavos, Robert's death is portrayed in the play The Bloody Hand in a very ridiculous manner, much to the amusement of the audience (including Arya).

While Septa Unella is at her mercy, Cersei states that she indeed killed Robert.

Plot holes and speculations

 * There are several plot holes about the assassination, mainly that it is unclear whether Cersei has given Lancel the order before or after her conversation with Ned. Varys's accusation suggests it was afterwards, but Lancel started offering Robert the wine before the conversation. Since there is no evidence to support either possibility, the following scenarios are based on speculations only.
 * Scenario #1: Cersei made her move after the conversation with Ned, to prevent Robert from being told the truth about her children. In this scenario Cersei's motive is obvious, and it is also consistent with Varys's accusation, but it has several flaws:
 * It is inconsistent with the order of scenes.
 * Cersei had a very limited window of opportunity to deliver her order and the wine to Lancel.
 * Moreover, how could she do that right under the noses of Robert, Renly and Ser Barristan?
 * Why was Cersei acting so calm during the conversation with Ned? Logically she should have been scared or nervous.
 * Scenario #2: Cersei ordered Lancel to have Robert drunk before he had gone to hunt. This scenario is arguably more plausible: it is consistent with the order of scenes; Cersei had enough time to set the stage; it explains why she acted so calmly in view of Ned's threat. This scenario, however, is inconsistent with Varys's accusation, and it has a serious flaw: what motivated Cersei to have Robert killed, if not Ned's ultimatum? The possible motives are:
 * Cersei hated and despised Robert from their wedding night, and her hatred has increased with time due to Robert's whoring and drinking habits. Robert's refusal to punish the Starks for the recent hostilities toward the Lannisters (Tyrion's kidnapping and the brawl between Ned and Jaime) might have been the last straw in Cersei's eyes.
 * Cersei might have learned, from her spies and henchmen, about Ned's investigation. She figured it was just a matter of time before he found out her secret and told Robert about it, so she decided to strike first.
 * According to the novels (see below), Cersei had at least two additional reasons, one is mentioned by Varys, but neither is mentioned in the show as a possible motive.
 * Why did Varys claim that Ned was responsible for Robert's death, if there was no such connection? The simple answer is that he was unaware of the exact chronology of events, and genuinely believed that Cersei had been prompted to make her move by Ned's ultimatum.
 * There is another plot hole about both aforementioned scenarios: how could Cersei be certain that Robert would get killed by a boar? It is in character for Cersei to come up with half-baked schemes (she acts that way very often in "A Feast for Crows"), but she has never relied on blind luck; it seems somewhat unlikely that, given that her children's lives were at stake, she would simply hope that a boar would appear and attack Robert.
 * In the book (see below) Varys implies that Cersei positioned henchmen in the wood to assure Robert's death, but there is no mentioning of that in the show.

In the books
In the A Song of Ice and Fire novels, the assassination occurs about the same, but the background and the aftermath are significantly different. There is no on-screen scene of the hunt, since Robert and his escorts are not POV characters.

Similarly to the show, in the books it is unclear when Cersei makes her move to kill Robert, before or after her conversation with Ned. Based on Varys's explanation, the assassination might have occurred either way, regardless of Ned's ultimatum.

The assassination is preceded by at least one unsuccessful attempt of Cersei to have Robert killed: during the Tourney of the Hand, Cersei prompts Robert to participate the mêlée contest, using reverse psychology, by forbidding him to - in the presence of his brother, his knights and half the court. Robert falls for the trick and insists on participating; eventually Ned dissuades him, though. Later, Varys tells Ned that the Lannisters sought to kill Robert during the mêlée; among the forty participants they had a henchman who would have killed Robert, making it look like an "unfortunate accident". Ned intends to tell that to Robert, but Varys dissuades him, pointing out that they have no evidence to support such a serious accusation; he warns Ned that it is just a matter of time before the Lannisters make another attempt on Robert's life.

Although Ned is aware that Robert is in danger, he does not tell him about the aforementioned attempt, nor does he take any steps to protect Robert from harm. Thus Ned's inaction makes him partly responsible for Robert's death.

In addition to Renly, Lancel and Ser Barristan, Robert is accompanied by many more people, among them: Joffrey, the Hound, Ser Balon Swann and Lord Yohn Royce; most of those (including Joffrey and the Hound) return to King's Landing before the fatal encounter with the boar.

While Robert is dying, he claims that the gods punished him for giving the order to kill Daenerys, and that he has been a wretched king, bad as Aerys.

When Varys visits Ned at his cell, he tells that he questioned Lancel, and the squire admitted Cersei had given him the wineskins. Similarly to the show, Varys blames Ned that it was not the wine that caused Robert's death, but the mercy Ned offered Cersei. Varys also reveals that if the boar had not injured Robert - he would have been killed from a fall from a horse, the bite of a wood adder, an arrow gone astray, etc. (namely that Cersei placed more henchmen at the wood). Varys, however, assures Ned that Robert's death was not entirely his fault: Cersei would not have waited long in any case, since Robert was becoming unruly, and she needed to be rid of him to free her hands to deal with his brothers.

Cersei might have had an additional motive to kill Robert: at that time, Loras and Renly sought to wed Margaery to Robert, and they were not too discreet about their intention; had they succeeded, House Tyrell would have gained political power at the expense of the Lannisters, and Cersei wouldn't allow that to happen.

In "A Clash of Kings", Tyrion asks Cersei how she killed Robert. She answers nonchalantly: "He did that himself. All we did was help. When Lancel saw that Robert was going after boar, he gave him strong wine. His favorite sour red, but fortified, three times as potent as he was used to. The great stinking fool loved it. He could have stopped swilling it down any time he cared to, but no, he drained one skin and told Lancel to fetch another. The boar did the rest". Some time later, Tyrion confronts Lancel, accusing him of being Cersei's lover and assisting her to kill Robert. Lancel initially denies everything very feebly, but soon breaks and admits "The queen gave me the strongwine".

In "A Feast for Crows", as a result of his near-death experience at the battle of the Blackwater, Lancel becomes pious and deeply regrets his past sins. He tells the High Septon about his affair with Cersei and his part in Robert's death, unintentionally condemning him to death; Cersei, who fears that Lancel has spilled the beans to the High Septon, orders her henchman Osney Kettleblack to kill the High Septon, and he does.

While Jaime is on his way to Riverrun, he visits Lancel at Darry. Lancel remorsefully tells Jaime what he told to the High Septon earlier about Cersei and Robert's death. The confession confirms what Tyrion told Jaime earlier about Cersei (that she sleeps with other men, among them Lancel), and makes Jaime realizes that she is responsible for the deaths of Robert and the High Septon.

Based on the testimonies of Osney Kettleblack and Lancel, Cersei is charged with regicide (in addition to other crimes - high treason, fornication, adultery, incest and deicide). She admits only the lighter accusations and denies the rest, among them Robert's murder.

In "A Dance with Dragons", while watching a pitfighter named Barsena being torn apart by a boar, Daenerys wonders if the boar that killed Robert was also so fierce; for a moment, she almost feels sorry for Robert.