"The Headband is one of the worst episodes in Avatar."
Nah. Sokka is probably at his funniest as Wang Fire. Getting to play dad is right in his wheelhouse, and the gags that result all hit. The beard being stuck to his face, his stand to attention when Aang tells him he enrolled in classes; all great stuff. (I really liked Katara's improvisation with Sapphire Fire.) Then you get a look into the life of a kid in the Fire Nation - all the joyless rigor these kids are put through. The indoctrination starts at an early age, and this stark setting allows Aang's vibrant personality to shine through strongly. His pure optimism and charisma cuts right through the imperialistic propaganda and reaches his FN peers on a fundamental level. Aang's spirit as a person transcends "enemy" lines, and directly leads to his wisdom later in the season that a person isn't born good or bad, and that the Fire Nation isn't inherently evil. It allows him to further understand his place as the Avatar and the nature of his duty.
Then you have the cute dance sequence which did more for Kataang than probably any specific instance focusing on their relationship. It wasn't in your face shipping that tLoK loved debasing itself to; it was genuine synergy that spoke a lot to how complementary the two were. They did something together that represented their feelings for each other, rather than merely saying as much.
The Headband is a great episode. All the characters are contributing to the episode in some form or fashion, and they're playing off each other well. Most importantly, we get to see the fundamental nature of who Aang is, all while he's immersed in what is supposed to be hostile territory. This subversion of what the Fire Nation is thought to represent is very well done. When I think about AtLA and what makes it so good, episodes like The Headband are what my mind goes to. The combination of humor, morals, and thematic expression is handled with deft skill and respect.