Heller has a Bachelor of Arts in Political Science from Yale University. He is characterized as a loyal public servant, serving in the United States Army as a pilot and air defense artillery officer, obtaining the rank of Captain, and became a reservist upon his retirement from active duty. He was CEO of Anderson Aerospace before serving as a Congressman and chairman of the House Armed Services Committee and the Commission to Assess National Security Policy. He was also director of the President's Economic Stabilization Program. Heller was appointed Secretary of Defense under President John Keeler and retained this position under President Charles Logan. Viewers of the TV series learn in season 4 of 24 that Heller is the father of his senior policy analyst, Audrey Raines, and that he is a widower. His son Richard frequently participates in anti-government/anti-corporate protests, much to his father's chagrin; Heller refers to his son's ideology as "6th Grade Michael Moore logic." In season 9 it is revealed that Heller is the President of the United States.
Heller is characterized as a true patriot; when his former special advisor, Jack Bauer, requests his assistance to remove Logan from office, Heller objects, saying that the country does not deserve to go through a long impeachment process. He attempts to cut a deal with Logan which would have resulted in his resignation as president.
Despite being middle-aged, Heller has been shown to be extremely adept at combat, being able to proficiently handle an AK-47 during the first escape attempt from his kidnappers on Day 4 and the Heckler & Koch USP 9mm Jack Bauer gives him in the second attempt. He is also able to knock Bauer out stone cold on Day 5 by striking him on the neck.
Before season 4, Heller hires Bauer as a special advisor following his dismissal from CTU. During that day, Heller and his daughter are kidnapped by a terrorist group, who plan to broadcast his execution over the internet. Bauer rescues them, however, and Heller coordinates CTU's pursuit of terrorist leader Habib Marwan. After spending several hours directing operations in CTU-Los Angeles, he is eventually transferred to Division when the threat escalates. Neither Heller nor his daughter are part of the tight circle that helped fake Jack's death to avoid an international incident with the Chinese.
At the start of season 5, Heller is attending a summit in Japan. While on his private jet on the return trip, Audrey telephoned him and told him that it was urgent that he redirect the plane to land in Los Angeles. Jack meets him at Van Nuys Airport to give him evidence implicating President Logan in the death of David Palmer. After hearing the recording, Heller feels the best course of action is to personally meet with Logan and try to quietly force his resignation. He leaves the recording with one of his security officers and orders Jack and Audrey to be kept in custody until he returns. After he leaves, Christopher Henderson locates Jack at the Van Nuys airport and forces him to surrender the recording while holding Audrey at gunpoint. Heller's plan backfires when Logan, notified by Henderson that the tape has been recovered, informs Vice President Hal Gardner that he is forcing Heller's resignation because of his unsubstantiated allegation that he was complicit in Palmer's death.
After Bauer captures Henderson, Henderson reveals he has his men on standby to kill Heller. The men have orders to kill Heller if Henderson does not make contact with them every 15 minutes. Jack calls Heller to ask him if any of Henderson's men are visible, and Heller informs him that a man from a hovering helicopter has a laser sight on him. Bauer is insistent on letting Henderson go to save Heller. Heller, however, sacrifices his life for the sake of the mission. He asks Bauer's forgiveness for not trusting him earlier, and then says, "Tell Audrey I love her." He then hangs up, and in a suicidal gesture, drives his car off the cliff into a lake. His car is last seen impacting the water of the lake.
It is later revealed that Heller survived the crash and is in intensive care.
In season 6 of 24, Heller returns at 1:56 a.m. after he learns of his daughter's condition. When he sees what state she is in, he tells Bauer to stay away from her. He threatens to file a legal restraining order to make sure that Bauer will never see her. Nadia Yassir tells Jack that Heller moved Audrey to a civilian hospital.
In the closing minutes of Day 6, Bauer arrives at Heller's beach house, holding Heller at gunpoint and demanding to know why Heller didn't try to get him out of China. Heller insists that he did, but those efforts met with failure. Bauer tells him that he did not try hard enough, and that he wrote him off as an "acceptable loss". Bauer also says that Heller doesn't blame him for Audrey's condition but the fact that Audrey would not give up on Bauer regardless of what he told her. Heller admits that Bauer is right, and he deserves better, but Bauer is not interested. Additionally, Bauer demands to know where Audrey is, and Heller refuses, which enrages Bauer further. Heller calmly lets Bauer know that no matter how badly Bauer wants to regain his life, he will be drawn back into "the game and my daughter's going to pay the price...like your wife did!" Enraged, Bauer threatens to kill him, but Heller then implores Bauer to let Audrey go. After a few moments with Audrey, Bauer agrees with Heller, and bids Audrey goodbye for the last time.
James Heller, now the President of the United States, is in London conducting talks to keep an American military base in the United Kingdom open. He is showing signs of memory loss. Attempts to keep the base open are damaged when (unknown to the U.S.) a hacker takes control of an American drone over Afghanistan and uses it to kill four soldiers, two of which are British. In a sign of goodwill, Heller plans to hand over Lt. Chris Tanner, the airman accused of the attack to British authorities for questioning and decides to address Parliament directly. Later, Heller learns that Jack Bauer has broken into the US Embassy and taken hostages. Speaking to Jack directly, Heller is told that the drone pilot is innocent and that a terrorist named Margot Al-Harazi has the ability to hack into the drones. At the advice of his Chief of Staff Mark Boudreau, Heller orders an assault to take control of the hostages.
After receiving confirmation Margot has the ability to control the drones, Heller orders the entire American drone fleet grounded. Before the drones can be grounded, Margot takes control of several drones and releases a video accusing Heller of killing 26 children in the drone strike that killed her husband, demanding that he surrender himself to her in three hours. Jack informs Heller that he can reach an arms dealer who can tell them Margot's location. Heller authorizes a covert mission led by Jack after a failed raid led to the deaths of several CIA agents. Heller informs the British Prime Minister of the situation and then confronts the PM after he goes behind his back with MI5 due to knowledge of Heller being diagnosed with Alzheimer's disease.
Afraid that Jack won't be able to locate Margot in time, Heller agrees to surrender himself to her in exchange for her destroying the drones. With Jack and Mark's help, he is able to bypass security and fly to Wembley Stadium. Beforehand, he grants Jack a presidential pardon so he will be a free man once more after everything is over. Once at the stadium, Margot fires a missile into the stadium, and the drone reports a confirmed kill of Heller. It is then shown that Chloe O'Brian hacked into the drone's video feed and used recycled footage to fake Heller's death. Heller is then instructed by Jack to go into hiding.
Although Jack manages to kill Al-Harazi and stop her last drone, Adrian Cross steals the override device with help from Steve Navarro and gives it to Cheng Zhi who is supposedly dead. Cheng uses the device to spark a war between the United States and China by making a US sub torpedo a Chinese aircraft carrier. Heller does his best to convince the Chinese President of the US' innocence in the matter, but is forced to prepare for war while commissioning Jack to track down Cheng and stop him and Audrey to attempt to spread information about the override device to the Chinese government through a contact of hers. Heller is shocked to learn Mark Boudreau betrayed him and Jack by trying to give them Jack and forging his signature. Heller initially goes to arrest Mark for treason but Jack convinces him to allow Mark to help him infiltrate the Russian compound to locate Cheng first. As the two countries draw close to war, Heller reluctantly prepares for all possibilities including nuclear war while unsuccessfully trying to convince President Wei of the truth. Finally, as the war is about to begin, Jack contacts Heller to let him know he has Cheng captive. After the CIA confirms his identity, Heller contacts President Wei with the evidence and warns him that he has to back off now or Heller will have no choice but to open fire. With this new evidence, Wei agrees on the promise that they will discuss reparations for the loss of lives and property. As everyone celebrates, Heller is informed that Audrey was killed by Cheng's men and collapses in shock.
The next morning, as he prepares to escort Audrey's body home, Heller solemnly reflects to Prime Minister Davies on how his Alzheimer's is worsening to the point that he will soon forget he even had a daughter let alone that she died.