Contrary to popular belief, Hela - and not Thanos - is the MCU's most powerful villain, as indicated by a scene in Avengers: Endgame. When Thor met the Mad Titan for the first time in Avengers: Infinity War, he was fresh out of a conflict with Cate Blanchett's Hela, the Goddess of Death. Hela was the main villain of Thor: Ragnarok and Thor's greatest threat to date. Presumably, this changed almost immediately when Thanos came onto the scene.
Thor: Ragnarok gave Thor one of the toughest fights of his life with the introduction of Hela, Odin's first child. The challenge Hela posed to Thor far exceeded all of Thor's previous foes, including Loki, Malekith, and Ultron. Hela easily disposed of the God of Thunder and destroyed one of the greatest weapons in the Marvel Universe, Mjolnir. After being captured and taken to Sakaar, it took almost an entire movie for Thor to get a team together and have a rematch with his older and more powerful sister. Even after tapping into his full potential, Thor still couldn't defeat Hela. The only thing that could stop her was Surtur, who, after being resurrected, destroyed Asgard and killed Hela.
Supposedly, Thanos is even stronger than Hela. He hits the Avengers with everything he has in the final battle of Avengers: Endgame, and how he's able to push them all to their limits is impressive to say the least. But, his fight with Captain America makes a statement about how his power compares to Hela's. Thanos hits Captain America with a barrage of attacks, repeatedly striking Captain America's shield. Despite the shield being made out of vibranium, Thanos' sword is able to break it apart, piece by piece. As shocking as this may be, it pales in comparison to what Hela was able to accomplish in Thor: Ragnarok.
An unarmed Hela disintegrated Thor's hammer just by holding it in her bare hand. It took Thanos a significant effort to break Captain America's shield, but Hela destroyed Mjolnir with ease. And there's no mistaking which weapon is made of the strongest material. Captain America's shield may be made out of vibranium, but even that can't compete with uru metal, which far outshines anything forged by mortals.
So if Hela really is more powerful than Thanos, why did nearly every hero in the MCU have to come together to fight him, when Hela was challenged by only a handful of super-powered characters? That's because Thor engineered Hela's fall by having Surtur kill her. This means that Thor never technically defeated Hela. In fact, he came closer to beating Thanos in Infinity War than he ever did with his sister.