Nothing deserves its U certificate less than this: Toy Story 3 is a brutally adult movie with brutally adult themes: the origin of evil in childhood pain, the death of childhood and, well, just death. There are scary villains and intensely, unbearably sad moments. Earlier this year, I wrote here, online, about how having a child of my own opened my eyes to the true and terrible meaning of the Toy Story movies, and particularly cowgirl Jessie's heartrending song When She Loved Me in Toy Story 2, describing how her mistress gradually fell out of love with her as she became a teenager.

Before I became a parent, I had vaguely thought that song was a parable for the child's fear of abandonment. Watching it recently again as a dad, I experienced something between an epiphany and a nervous breakdown. Like the theologian crazed by his theory of the New Testament in Borges's short story Three Versions of Judas, I was gibberingly convinced that I, and I alone, understood the real meaning of the Toy Stories; John Lasseter had spoken directly to me. We, the adults, are the toys. One day, our children will get bored playing with us. They won't want to be cuddled by us; they won't want to confide in us; they will go away and leave us. It will never be the same again. The toys in Toy Story 3 are sent away to a daycare centre where they are victimised and mistreated – just like the infantilised inmates of an old people's home.

TS3 undoubtedly takes its cue from TS2's gloomy visions of mortality and obsolescence, and amplifies them in ways that, though not as brilliant and novel as the second movie, are tremendously inventive and, yes, powerfully sad. The melancholy that was largely compressed into When She Loved Me is now diffused throughout the film, but it is still superb, and the opening sequence is as thrilling, funny and visually gorgeous as anything in the Pixar canon.

We join the story as Andy, 17, is about to go up to college. Sentimentally loyal to his boyhood self, he intends to take Woody (voiced by Tom Hanks) with him as a mascot and store the rest, including Buzz (Tim Allen) in the attic – but a mixup means they all get taken to a daycare centre. At first delighted by the prospect of playing with real kids once more, the gang find the roost is ruled by an evil bully: the insidiously cute Lotso-Huggin' Bear, voiced by Ned Beatty, who turns the centre into a jail like the one in Cool Hand Luke. He has a horror-movie-style sidekick in the form of Big Baby, a chilling, dead-eyed enforcer.

The humour, the drama, everything in the film seems targeted more at the parents than the children: certainly those cheeky hints at the metrosexual proclivities of Barbie's true love, Ken, with his scarf and blow-dried hair. That said, it's an effortlessly superior family movie. We grownups, however, may have to gulp back our tears and somehow keep it together in front of the kids: just like the toys who revert to blank grins when their owners come back into the bedroom.

Sign up for the Guardian Today

Our editors' picks for the day's top news and commentary delivered to your inbox each morning.