JAKARTA -- Indonesia's economy grew faster than expected in the three months ended December, thanks to solid investment from both the private and public sectors.

The Central Statistics Agency on Monday said gross domestic product for the October-December quarter expanded by 5.19% year-on-year, up from the 5.06% recorded in the third quarter. Economists polled by Reuters had expected growth of 5.12%.

Growth was driven by private sector investment as domestic fixed capital formation rose 7.3%. Growth in government spending also recovered to 3.8% from 0.3% in the third quarter. Meanwhile, household consumption increased 4.97%, mostly unchanged from previous quarters.

Full-year GDP in 2017 increased by 5.07%, higher than the 5.03% growth logged in 2016.

Indonesia's benchmark stock index cut some of its losses on the announcement amid a broad sell-off in Asian equity markets.

Many economists expect further acceleration in 2018, helped by spending ahead of regional elections in June and a presidential election next year.