The ending of the film differs from that of the book.
Plot
British diplomat Harrington Brande takes up a minor provincial consular post in Spain. The appointment is a disappointment to Harrington, who was hoping for a more senior position. His abandonment by his wife may have adversely affected his career, as might his brusque manner. He is accompanied by his eleven-year-old son, Nicholas, whom he teaches at home, contrary to his friend's advice that the boy would benefit from the social engagement with other boys at a boarding school. Harrington prefers to monopolise his company.
Nicholas sees it as an adventure, and soon becomes friends with the teenage gardener, José, spending time every day helping him with the plants and relaxing together. The exercise he is getting is much better for him than his father's mollycoddling of the perfectly healthy boy. However, the middle-aged Harrington is jealous of his son's enthusiasm for and friendship with the much younger man. He rebukes his son for taking him to watch Jose play pelota and refuses Jose's gift of fish that he had caught. Similarly, he refuses to let Nicholas join a youth group organized by a junior colleague. He later bans Nicholas and Jose from speaking on pain of Jose's dismissal. He also sets Jose to clear a large rockery as punishment.
While Harrington is away on a business trip, the drunken Garcia, the butler/ chauffeur, threatens Nicholas with a knife and tries to break into his bedroom and the terrified boy takes refuge overnight with Jose with whom he has again been spending time. His father discovers this and is furious. Garcia then frames José by convincing the father that Jose has stolen Nicholas' wristwatch, that Garcia himself had stolen, to cover up his own thieving behaviour.
Jose is arrested and is taken in handcuffs on a train with two armed soldiers guarding him. Brande is on the same train and suddenly realises his fault, but at the same time, Jose jumps from the train. It is initially unclear if he survived the jump.
Brande goes home and discovers his son has run away. He goes to Jose's family, but they have little sympathy, but the old father thinks he knows where they have gone.
On a stormy night Nicholas finds Jose in a derelict old mill, then Brande finds both and tells Jose that he knows he is innocent. Brande and Nicholas move on to another posting, and as they leave Brande apologises again to Jose, who does not see them to the station but instead says he must stay, as "there's much to do".