The pair, who have denied wrongdoing, are accused of hiding more than four million euros ($5.39 million) by filing incomplete tax returns for the years 2006 to 2009.
Neither Messi nor his father spoke after their testimony, but their lawyer, Cristóbal Martell, said the two "proved the absence of intent to defraud and their great willingness to set the matter straight with the tax authorities".
They have already made a "corrective payment" to Spanish authorities of just over five million euros.
In a written petition to the judge last August, Martell said Messi's father assumed full responsibility for his son's tax situation, distancing the player from any direct involvement.
The judge will now determine whether or not to dismiss the charges or impose a fine.
A spokesperson for the Superior Court said the ruling "should not take long".
After Messi's father testified, the player arrived with his brother Rodrigo. A crowd of about 100 people assembled in the plaza of the town to catch a glimpse of Messi and to give their support with shouts of "Long live, Messi," "President Messi," and "You're the best".
Although the odd "cheat" was also heard, Messi appeared relaxed and smiling, acknowledging supporters with a thumbs-up sign.
According to the prosecutor's office for tax crimes in Catalonia, income from the sale of Messi's image rights was hidden using a complex web of companies in Uruguay, Belize, Switzerland and the United Kingdom.
He has been resident in Barcelona since joining the club's academy in 2000 and gained Spanish citizenship five years later.
Image: Barcelona soccer player Lionel Messi (centre) gives a thumbs up as he leaves after answering charges of tax evasion in a court in Gava, Spain.
Photograph: Albert Gea/Reuters
Preview: Bale set for Bernabeu baptism of fire in Madrid derby
Misunderstanding on ordinance on convicted lawmakers: Tewari
Miss World: 9 facts about the pageant you probably didn't know
Barcelona defender Mascherano out for up to 2 weeks
World's best selling cars; Swift ranks 20