The court also found the man guilty of acting on the orders of a senior al-Qaida leader in Yemen. The name of the alleged al-Qaida leader was not made public.
The attacker, who has not been publicly named, was identified only as a 33-year-old Yemeni resident of Saudi Arabia.
The court ruled that a second suspect, who also was not identified, be sentenced to 12.5 years in prison. He was found guilty of aiding and abetting the attacker and sending money to al-Qaida in Yemen.
The court's rulings are preliminary and can be appealed.
The troupe, reportedly from Spain, had been performing at a park in Riyadh on the evening of Nov. 11 when a man stormed the stage and attacked them with a knife. It marked the first such incidence of violence since the kingdom began loosening restrictions on entertainment around two years ago.
State-owned news media outlets aired footage at the time of security as they ran on stage to capture the suspect. Other state-linked media outlets shared footage online of a man running on stage and apparently attacking the performers from behind as the troupe, dressed in gold ensembles, performs a dance.