The home side got the only goal of the game after 12 minutes when Scottish defenders backed off and allowed Giovani dos Santos to fire home from just inside the box.
Mexico, who play a final warm-up against Denmark in Copenhagen next Saturday, were far superior to a team that have not qualified for a major tournament since 1998 and who fielded an inexperienced and experimental side.
Mexico had a goal chalked off for offside after 70 minutes and hit the woodwork twice but could not turn their dominance into further goals despite Scotland tiring at high altitude in Mexico City.
In one of their few chances, Oliver McBurnie saw a header come back off the post early in the second half for the Scots.
Mexico have been drawn in Group F for the World Cup in Russia and will kick off their campaign against Germany on June 17 before facing South Korea and Sweden.