“Vivarium” is an enigmatic movie where the meaning of its ending may be elusive, but it's actually easy to understand when you consider a metaphor from earlier in the film.
In certain species of cuckoo birds, the mother will lay her eggs in the nest of a different bird species, attempting to force the other bird to raise her offspring.
The invasive cuckoo chick may even kill the host bird’s babies, and this is depicted early in the movie when the cuckoo chick fatally tosses the other hatchlings from their home.
When a little girl happens upon the corpses of the baby birds and asks who did this and why, Gemma (Imogen Poots) explains that perhaps it was a cuckoo bird who needed a nest.
In response, the child asks why the cuckoos didn’t just build their own nest. Gemma replies, “I don’t know. That’s nature. That’s just the way things are.”
The cuckoo birds are a metaphor for what happens to Tom (Jesse Eisenberg) and Gemma, and this is the very heavy-handed foreshadowing that also explains the ending of the film.
Tom and Gemma are forced to become adoptive parents, trapped in the nest that is Yonder, and made to raise the creepy future Martin (Éanna Hardwicke) so his species can live on.
There is no plan for world domination or some sinister plot. Martin and his species just force couples to raise their young to survive, and that’s just the way things are.