Experienced Lopez, the middleweight champion at Rio 2016, claimed a tense and tight gold medal bout on a 4:1 split-decision.
Whittaker left the ring in tears after the result was announced but can reflect on a terrific tournament in which he has shone both in and out of the ring.
Lopez unquestionably represented the toughest test of the 24-year-old’s career to date and the task got harder when the Cuban was awarded a close opening round by all five judges.
Whittaker tried to respond in the second and caught the eye with a thundering left hook but it was again his opponent who got the nod from four judges.
By then the Black Country ace needed a stoppage to claim the title but despite an impressive final round, Lopez proved immovable.
Whittaker, who is expected to turn professional, will return to the Midlands to a hero’s welcome.