Messi and his father Jorge, who manages his finances, were both convicted in 2016 of defrauding Spain of €4.1m (£3.5m; $4.6m) in taxes.
Jorge Messi's jail term was reduced because he paid some of the taxes.
In Spain, prison terms of under two years can be served under probation.
The case will now return to the court in Barcelona that handed down the original judgement.
Lionel Messi, a five-time world footballer of the year, has denied any involvement and told his trial in June 2016: "I only worried about playing football."
But in its decision on Wednesday, the court said: "It defies logic to concede that someone who earns a large income does not know that he must pay taxes on it."
Both men were originally convicted of three counts of fraud, for using tax havens in Belize and Uruguay between 2007 and 2009, and were also given heavy fines.
They were found guilty of resorting to fictitious companies to evade Spanish taxes on income from companies using Lionel Messi's image rights.
Jorge Messi's jail term was reduced from 21 months to 15 by the Supreme Court to take into account the money he had since handed to the tax authorities.