Nigeria has overtaken South Africa as Africa's largest economy after a rebasing calculation nearly doubled its gross domestic product, data from the statistics office showed on Sunday.

GDP for 2013 in Africa's top oil producer totalled 80.3 trillion naira, or $509.9 billion, the Nigeria Bureau of Statistics said, an increase from the 42.3 trillion estimated before the rebasing.

The new figure shrank Nigeria's debt-to-GDP ratio to 11 percent for 2013, against 19 percent in 2012, statistics chief Yemi Kale told reporters in the capital of Abuja.

Most governments overhaul GDP calculations every few years to reflect changes in output and consumption, but Nigeria had not done so since 1990, so sectors such as e-commerce, mobile phones and its prolific "Nollywood" film industry had to be newly factored in to give a more accurate picture.

Growing attention from foreign investors was forcing Nigeria to more accurately calculate its statistics, including GDP, Kale said, adding that the base year would now be recalibrated every five years, in line with global norms.

Nigeria, Africa's most populous country with 170 million people, has been growing as a destination for foreign investors owing to the size of its consumer market and increasingly sophisticated capital markets.

But political risk as Nigeria approaches hotly contested elections in February next year remains a concern, as does a bloody insurgency waged by Islamist sect Boko Haram in the country's poor and underdeveloped northeast.

President Goodluck Jonathan's suspension in February of respected central bank chief Lamido Sanusi after he had publicly questioned massive oil revenue leakages from the state oil firm did not impress debt and equity investors, some of whom sold off holdings.