All seven candidates have pledged to keep the process peaceful but an opposition supporter died when a rally tuned violent on Monday.
The campaign has been dominated by the faltering state of Ghana's economy and the issue of corruption.
Results are expected within three days.
A run-off will be held later in the month if neither of the two main candidates secures more than 50% of the votes.
In Tema, where I'm registered, I found a queue of men and women waiting for voting to start. The first in one of the queues, Alfred Aggrey, told me he arrived five hours earlier. Many wanted to get on with their day's business.
Loud noises of disapproval rung out when polling officers positioned the voting booths away from the crowd. People demanded that the booths be made to face them so they could see people going in to thumbprint only the assigned ballot papers and no other papers that they suspected could be smuggled in.
After a few minutes of shouting at the officers, their request was carried out to cheers of approval.
Many Ghanaians began queuing at polling stations overnight.
"I needed to register the strong feeling I have about this country with my thumb and the least I could do was to sacrifice sleep," Comfort Laryea, a 78-year-old who had waited to vote since 04:00 in the capital, Accra, told the Reuters news agency.
For many, the economy is the main issue.
"We need change in Ghana because things are very difficult," taxi driver Stephen Antwi Boasiako told the AP news agency. "This country has a lot of resources that can provide good jobs, but they're not used."
Police have told voters to go home after casting their votes, Joy FM reported.
The candidates signed a pact last week vowing to follow electoral rules and keep the peace.
But clashes broke out on Monday in Chereponi, a small northern town on the border with Togo. In addition to the reported death, six people are said to be in a critical condition as a result.
Thousands of domestic and foreign election observers have been deployed at the nearly 29,000 polling stations across the country.
Defeat for Mr Mahama of the National Democratic Congress (NDC) would make him the first incumbent to lose an election since Ghana returned to multi-party democracy.
He has been nicknamed "Mr Dumsor", a local word that refers to the power cuts that have blighted the country during his term, but on the campaign trial has been trying to convince Ghanaians that he is delivering on his promise of creating more jobs.
Mr Akufo-Addo meanwhile has promised free high-school education and more factories, but his critics have questioned the viability of his ambitions.
NDC candidate: John Dramani Mahama, 58
Can 'Mr Power Cut' John Mahama win a second term?
NPP candidate: Nana Addo Dankwa Akufo-Addo, 72
Third time lucky for opposition leader Nana Akufo-Addo?
There are long queues at polling stations in Ghana amid a tight election race between President John Mahama and veteran opposition leader Nana Akufo Addo.