Ghanaians were voting on Wednesday for a President and parliament in a neck-and-neck race for the highest office.

This office has been dominated by a three-year economic downturn that has led to heavy job losses and price hikes.

President John Dramani Mahama is running for a second four-year term in the West African nation rich in gold, cocoa, diamonds, aluminum, bauxite and recently discovered oil.

Mahama is competing with six other candidates for the presidency.

His fiercest rival is Nana Akufo-Addo, the leader of the largest opposition group, the New Patriotic Party (NPP).

Both Mahama and Akufo-Addo cast their ballots in their home towns in the country’s north.

“This election is going to consolidate our democracy further I know the good people of Ghana will vote for me,’’ Mahama said.

Akufo-Addo appealed to electoral officials to “make sure that the process is transparent and credible,’’ when casting his vote in the town of Kyebi.

“Ghana is then the winner,’’ Akufo-Addo added.

Security was beefed up across the country, with a heavy police and military presence around polling stations and major roads.

However the atmosphere remained calm and peaceful, buffered by a pledge all seven candidates made last week to follow electoral rules and oppose violence.

Mahama remains popular in the nation of 26 million people, the first sub-Saharan country to gain independence in colonial Africa, in 1957.

The 58-year-old incumbent made major progress in improving Ghana’s infrastructure by building schools, health facilities and roads.

But many voters hold Mahama and the ruling National Democratic Congress (NDC) responsible for a debilitating three-year energy crisis that led to a 10 per cent drop in economic growth and sharp rise in electricity between 2011 and 2015.

Akufo-Addo promises to use Ghana’s new found oil to create jobs and push industrialisation in all economic sectors, including agriculture.

It is the third election in which the 72-year-old is vying for the presidency.

ALSO READ:Ghana's affable but embattled president

Observers from Britain, the African Union and the Economic Community of West African States (ECOWAS), were monitoring the election together with 8,000 domestic observers.

If no presidential candidate gains 51 per cent or more of the vote, the election will go into a second round results are expected within 72 hours of the end of voting.