Heimdall was one of the most powerful characters in the MCU universe, but the films repeatedly failed to use him to his full potential. Introduced in Thor, Heimdall was the guardian of the Bifrost Bridge and due to his incredible senses, he was able to hear and see anything that happened in all of the Nine Realms. His abilities made him the perfect gatekeeper for Asgard, as he was supposedly able to sense any incoming threat. This near omniscience, however, was not as useful as it could have been on screen.
While Heimdall was shown capable of hearing Asgardians call him across the universe and even share his visions with Thor, since the very first Thor movie, he also failed to spot upcoming threats by allowing Frost Giants to sneak into Asgard and even failing to see Thanos and his ship arriving in Avengers: Infinity War. Despite being introduced as a powerful all-seeing being, the MCU immediately made him incompetent at his job. In Thor, Heimdall is fooled by Loki multiple times as the trickster god traveled between Asgard and Jotunheim without Heimdall noticing in order to conspire against Thor and Odin. He was also easily neutralized by Loki, who froze him to take control of the Bifrost.
In Thor: The Dark World, Heimdall couldn’t sense the upcoming invasion of the Dark Elves. Although he put a good fight against their forces, by the time he finally sensed something was amiss, the elves were already in Asgard. Once again, Heimdall’s powers were undermined and his usefulness as Asgard’s gatekeeper and the Bifrost guardian was put in question. His mistake led to Queen Frigga’s death, which greatly affected Odin, Loki, and Thor. Not only that, but Heimdall constantly either disobeys orders or fails to stop people from using the Bifrost to enter or leave Asgard.
It’s no wonder that, by Thor: Ragnarok, Heimdall had lost his position as the Bifrost guardian to Skurge instead. Of course, that was part of Loki’s petty revenge, but looking back at the past movies, Heimdall’s track record didn’t exactly look good. If Odin had exiled him instead, it would’ve been hard not to see the reason. The problem with Heimdall was that the MCU never knew how to use him without undermining his abilities. He was simply too powerful and if he had done his job properly, a lot of events would simply not have happened. The entire first movie depends on Heimdall missing Loki’s trips and if he had seen the Dark Elves coming Thor: The Dark World would’ve been a very short movie.
Perhaps knowing how badly they treated Heimdall, the MCU creators decided to give him one last heroic act before he was killed. It was thanks to Heimdall’s magic that Bruce Banner was able to warn Tony and Doctor Strange of Thanos and his goal of stealing the Infinity Stones. Although Heimdall sending the Hulk back to Earth did not stop Thanos in the end, it gave the Avengers precious time to prepare themselves. Avengers: Infinity War didn’t solve the MCU’s Heimdall problem, nor it did redeem the character, but it did at least include a nod to his role in the Thor movies.
More: Why Thor Gets A New Weapon After Ragnarok (Despite Not Needing Mjolnir)