Young St Johnstone and Motherwell fans faced-off outside McDiarmid Park after a botched bid by police officers and ground security to avoid confrontation.
The groups traded insults and the visitors were challenged to fight by older youths within the ranks of the Saints support.
Fans had been carefully marshalled from the Perth side’s ground following a 1-1 draw in December 2016, only to come face-to-face on Crieff Road.
The city’s sheriff court heard the ringleaders had been 18-year-old Sean Ormsby and a 17-year-old who cannot be named for legal reasons.
Depute Fiscal Claire Kennedy said: “The accused were part of a group of young home supporters at the St Johnstone versus Motherwall match.
“They were considered the ringleaders of the group, with the younger fans said to have been following their lead.
“Supporters of both clubs were being escorted from the ground but unfortunately this happened at the same time and the two groups met.”
The court was told Ormsby and his co-accused had begun shouting and had been challenging away fans to fight.
Though they were repeatedly warned about their behaviour they continued to act in a disorderly manner and were arrested.
Their actions helped to create a tense atmosphere outside the ground, with the court hearing the emotions of impressionable younger fans had been whipped-up by the pair.
Ormsby, 18, of Cooper Drive in Perth and his co-accused, subsequently admitted that on December 17, 2016, outside McDiarmid Park, they behaved in a disorderly manner, shouted and challenged Motherwell FC supporters to a fight and committed a breach of the peace.
Sheriff Gillian Wade told the pair: “This kind of behaviour at football matches cannot be tolerated.
“You clearly were not setting a good example to the young people in your company.”
The sheriff said as each was a first offender and had been of good behaviour since the incident she was willing to restrict their fines to £225.
The 2016 match-up between St Johnstone and Motherwell saw the home side’s Chris Kane cancel out an early own goal by goalkeeper Zander Clark.