The highlight on Wednesday was her tour of Cape Coast Castle, a major outpost on the Atlantic slave trading route.
She first paid a courtesy visit to a local traditional ruler, Osabarimba Kwesi Atta II, meeting him in Obama Hall, named after former US President Barack Obama.
Mr Obama, the first African American president, visited the castle in 2009, with his wife, Michelle, a descendant of African slaves, and their two daughters.
After being shown around the castle and given a history lesson about it, Mrs Trump said: "It's very emotional. I will never forget [the] incredible experience and the stories that I heard."
On Tuesday, Mrs Trump visited, alongside Ghana's First Lady Rebecca Akufo-Addo, the Ridge Hospital in the capital, Accra.
Mrs Trump observed babies being weighed as part of a project aimed at promoting nutrition in children, which is supported by funding from the US government's foreign aid organisation, USAid.
What is the significance of the castle?
By Thomas Naadi, BBC Africa, Cape Coast Castle
The castle is one of the many historical trading posts dotted along the West Africa coast. During the Trans-Atlantic slave trade, tens of thousands of enslaved Africans were held here under degrading and inhuman conditions before being shipped to the Americas.
Some of them were kidnapped and exchanged for items like alcohol and guns. The castle was originally used as a trading post for goods like gold and timber.
In 2009, Mr Obama described the castle as a remnant of profound suffering and a reminder of the human capacity to commit great evil.
It stands as an important signifier of the starting point of African American history.
Has Mrs Trump visited Africa before?
Ahead of her trip Mrs Trump said that she was looking forward to visiting "four beautiful and very different countries in Africa".
"She is interested in Africa because she has never been before and knows that each country will have its own unique history and culture." Stephanie Grisham, her communications director, said.
Mrs Trump said that she was looking forward to seeing how the US can continue working together with Malawi to support a USAid programme that is focused on children's education.
The first lady also highlighted the work the US was doing in Kenya to support early-childhood education, wildlife conservation and HIV prevention.
"My final stop, which is Egypt, will focus on the country's tourism and conservation projects," she said.
How has she been received?
Mrs Trump has got a warm reception, but huge crowds have not lined the streets to welcome her, as they did for the Obamas.
Views about the visit have been mixed. "I think Melania is a great woman. Her story is particularly inspiring," one resident of Accra told the BBC.
But another said "she doesn't inspire me" comparing her unfavourably to former First Lady Michelle Obama, who travelled to Ghana with her husband on a trip in 2009.
What does President Trump think of Africa?
Before his wife left for Africa, Mr Trump told reporters: "We both love Africa. Africa is so beautiful. The most beautiful part of the world, in many ways."
This view is at odds with comments he allegedly made in a private discussion in February.
Mr Trump was accused of racism, after he was reported to have used the word "shithole" to refer to African nations when talking about immigration policy.
The African Union asked him to apologise over the comment.
He later told reporters: "I am not a racist. I'm the least racist person you have ever interviewed."
In August the president angered the South African government by falsely claiming that there was large-scale killing of white farmers in South Africa.
I have asked Secretary of State @SecPompeo to closely study the South Africa land and farm seizures and expropriations and the large scale killing of farmers. “South African Government is now seizing land from white farmers.” @TuckerCarlson@FoxNews