I often find that pieces of media that feel pretentious are the ones that explore philosophy only through the character's dialogue--for example, heavily referencing concepts from certain philosophers, but not doing anything substantial with them story-wise.
The best though-provoking stories are those where the philosophy itself is embodied in the actions of the characters and the progression of the story.
Haibane Renmei--a story about loss--handles this theme not through characters talking about what they believe loss is, but rather from their reactions to losing things, as well as their resolutions regarding said losses.
Evangelion--a story about the messiness of human relationships. Arguably pretentious, especially with on the nose naming conventions of things (Lance of Longinus, Chamber of Guf, Hedgehog's dilemma--though this one is thematically relevant).
However, it still does a large part of its exploration through action, most specifically the dysfunctional relationships between the main characters, and their gradual spiral into self-loathing and madness.
Overall, I think stories only come off as pretentious if the creators behind it wanted to artificially elevate the work into high literature or something. Stories that are driven by honest motives and genuine concerns about life and existence are more likely to be thought-provoking.