FILE PHOTO: A woman buys tomatoes in a groceries stall at Granada market in Mexico City, Mexico, January 10, 2017. REUTERS/Tomas Bravo/File Photo

MEXICO CITY (Reuters) -Mexico's headline inflation sped up in the first half of September, broadly in line with market expectations, heading closer to the upper limit of the central bank's target.

Consumer prices were up 3.74% in the 12 months through mid-September, statistics agency INEGI said, speeding from a prior figure of 3.49%. Analysts polled by Reuters had forecast an annual rate of 3.77%.

While the market expects inflation in Latin America's second-largest economy to reach 3.9% by the end of the year, Banxico, as the central bank is known, targets an inflation rate of 3%, plus or minus a percentage point.

Month-on-month Mexican consumer prices rose 0.18% during the first half of September, also accelerating from a prior decrease of 0.02%, and compared with a 0.19% rise expected by economists in the poll.

The closely watched core price index, which strips out some volatile food and energy prices, kept picking up with a 0.22% monthly increase in early September, from the prior figure of 0.09%.

(Reporting by Aida Pelaez-Fernandez and Ricardo Figueroa; Editing by Nick Zieminski)