In Madison, New Jersey, David, a prototype Mecha child capable of experiencing love, is given to Henry Swinton and his wife Monica, whose son Martin contracted a rare disease and has been placed in suspended animation. Monica feels uneasy with David, but eventually warms to him and activates his imprinting protocol, causing him to have an enduring, childlike love for her. David seeks to have Monica express the same love towards him. He also befriends Teddy, Martin's robotic teddy bear. Martin is unexpectedly cured of his disease and brought home. Martin becomes jealous of David, and taunts him to perform worrisome acts, such as cutting off locks of Monica's hair while she is sleeping. At a pool party, one of Martin's friends pokes David with a knife, triggering his self-protection programming. David grabs onto Martin, and they both fall into the pool. Martin is saved before he drowns, and Henry convinces Monica to return David to his creators to be destroyed. On the way there, Monica has a change of heart and spares David from destruction by leaving him in the woods. With Teddy as his only companion, David recalls "The Adventures of Pinocchio" and decides to find the Blue Fairy so that she may turn him into a real boy, which he believes will win back Monica's love.