Two teenagers accused of setting fire to Mt Lawley Primary School have pleaded guilty to a downgraded charge of being negligent with fire.
The boys, aged 15 and 16, were initially charged with arson but the prosecution revised the charge.
The teenagers set fire to chairs under the school's verandah in July last year.
The court was told the boys set the chairs alight thinking the fire would be put out, and did not intend for it to spread.
The blaze quickly got out of control, causing damage to about 80 per cent of the school.
It is estimated it will cost about $9 million to rebuild.
The teenagers denied arson charges but changed their pleas to guilty after the charges were downgraded.
They will be sentenced later this month.