Education spokesman Ross Greer said wiping the slate clean could be the first step to all pupils being offered free meals, which are only provided for primary ones to threes.
Arrears at Aberdeen City Council schools accounted for the lion’s share of the total - £434,545 - which have built up over more than five years, according to responses to the party’s freedom of information request.
It was followed by North Ayrshire with £168,855 since 2017, and Aberdeenshire with £98,986.
The £1,168,755 total covers 25 of Scotland’s 32 councils but is likely to be far higher because Scotland’s two biggest local authorities - Glasgow and Edinburgh - did not provide figures.
Greer said: “Children are going hungry in Scotland and we know means-tested free school means miss out far too many families who need them.
“This frankly astonishing mountain of school meal debt should be written off immediately.
“If it is serious about closing the attainment gap, the Scottish Government should follow the example of countries like Finland by providing all pupils with access to a free, nutritious breakfast and lunch, including during school holidays.
“The first step towards that would be writing off this growing debt, which is clearly not going to be paid off in most cases.”
But Aberdeen City Council co-leader Douglas Lumsden hit back: “It is complete hypocrisy by the Scottish Greens to be calling on local authorities to write off money and take it from other front line services.
“The Greens constantly prop up the SNP government to allow them to pass a budget that continues to make Aberdeen one of the lowest funded councils in Scotland.
“We will continue to try and recover outstanding amounts owed while protecting the most vulnerable in society.”
North Ayrshire Council said: “We have a proactive process which aims to reduce this debt while allowing parents to catch up on outstanding payments in a manageable way.”
An Aberdeenshire Council spokesperson said: “It would always be our priority to ensure that any child or young person in Aberdeenshire was able to engage in the highest quality learning at all times.
“This cannot be done if the individual is unable to concentrate due to being hungry.
“We would seek to remove all barriers to learning wherever possible.”
A spokesperson for West Lothian Council, which has £10,491 arrears, said: “Policies and procedures are in place to manage school dinner debts, and cases are dealt with on an individual basis.”
A spokesperson for East Lothian Council, which has arrears of £11,860, said: “We recognise there can be a range of factors that can contribute to school lunch debt.
“Our headteachers and schools work sensitively with families to understand their individual circumstances.
“We help families to access financial support where it would benefit them.”
A spokesperson for the Convention of Scottish Local Authorities (Cosla) said: “Councils are increasingly aware of the pressure faced by low income families.
“Councils are working hard to ensure there is a maximum take up of free school meals for all that are eligible.
“To further increase support, the majority of councils are now providing meals out of school hours including in the summer holidays.
“This is being done from a reducing core budget – and Cosla will be continuing to press Scottish Government for a fair settlement for local government over the coming weeks.”