Studio Ghibli released 21 anime films between 1986 and 2014, but not one of them featured an openly LGBT character. That, of course, isn't a critique of the quality of those films; many of them never showed any romantic relationships of any kind, but opted instead more for themes of friendship and platonic love.
However, 2014's When Marnie Was There, the studio's final feature before an extended production hiatus that ended in 2020 with Earwig and the Witch, looked as if it could be an exception. The psychological drama had undeniably homoerotic themes throughout that appeared to be setting up a possible love story between two girls. But that potential subtext is eventually squashed when you understand the actual relationship dynamics between them.
When Marnie Was There's LGBT Undertones
The story focuses on a girl named Anna who's uncertain about her identity. She doesn't know who she is, because her earliest memories were of foster care. She knows nothing about her biological parents, other than that they died in a car accident. She spends a summer at the house of one of her foster mother's relatives, where she discovers a mysterious old mansion, within which she meets the blonde spectral figure of Marnie.
The two immediately become close, and, as the movie continues, their bond becomes stronger as Marnie helps Anna come to terms with who she is. It's clear early on there is something otherworldly about Marnie; after all, she emerges in an abandoned mansion, and disappears without explanation. But the nature of Anna and Marnie's relationship isn't clear until the end of the film, which might lead viewers to wonder, "Is Anna realizing she's gay?"
Marnie and Anna are very physically intimate throughout the film, often holding hands and holding each other in comforting ways. Even the film's poster depicts them with hands held back-to-back, a position that, were they members of the opposite gender, would immediately indicate to audiences that they're the story's romantic pair. They have more physical contact than Sophie and Howl, Ashitaka and San, or Chihiro and Haku. Even if nothing came of the budding relationship in terms of romantic attraction, there are enough implications to foster subtext.
However, that subtext is quashed when it's revealed Marnie is the ghost of Anna's grandmother, who briefly took care of Anna following the death of her parents before then passing on herself. The spirit following Anna is a forever representation of her grandmother's love for her. While this is a moving and fitting end to the story, it puts a serious damper on any potential queer reading, for obvious reasons.
Why Marnie Could Never Be an LGBT Film
In situations like this, it's vital to separate expectations from the reality of how the film was produced. That's not to say Japan is too conservative to release a movie featuring queer characters, or even that Ghibli as a studio is too conservative to feature LGBTQA characters. Former Hayao Miyazaki collaborator Hideaki Anno created the explicitly queer Kaworu Negisa in his series Neon Genesis Evangelion, while When Marnie Was There director Hiromasa Yonebayashi worked on shows like Serial Experiments Lain and Monster, both of which have queer-coding throughout.
The real reason why When Marnie Was There never had a shot at being an LGBTQA story is because it's based on a mainstream British children's book by author Joan G. Robinson, published in 1967.
The film does take liberties with the book's plot. Other popular books written in the 1950s and '60s, including A Separate Peace by John Knowles, have had adaptations that play up potential queer coding. The difference with When Marnie Was There is that, once you know the ending, it completely alters the type of film it is. On first watch, When Marnie Was There appears to be a story about Anna learning about her identity in the present sense. Upon re-watch, it's clear the film is about Anna learning who she was leading up to now in order to know who she is going forward. The entire lens of the narrative if fixated on a different aspect of Anna's life. It's just coincidental that the story's structure otherwise resembles a romantic coming-of-age story.