The city has underestimated the amount of money it will have to hand off to charter schools next year by $28 million, according to the Independent Budget Office.

The possible deficit could leave the city millions of dollars in the hole if it doesn’t tweak its projections before the budget gets enacted at the end of the month, IBO Chief Ronnie Lowenstein told City Council members on Friday.

The funds at issue come from the state, which funnels money for education into the city’s budget. When a city student enrolls in a charter school rather than a district school, state law requires the city to turn over its per-pupil expenditure—$13,777 per student next year—to the charter school.

One piece of the spending discrepancy, which neither the city nor the IBO could fully explain, stems from a disagreement over how many students will actually be attending charter schools next year, and thus how much money the city will need to hand over. The IBO’s estimate is 1,100 more students than what the city expects—a $15 million difference.

Charter school enrollment is expected to increase from about 70,000 this year to, roughly, 83,000 next year. Charter school spending constitutes about $1.3 billion of the city’s proposed $20.6 billion operating budget.

It’s not unusual for the city’s number-crunchers to wildly miscalculate charter school spending for the coming year. But usually, the oversight occurs earlier in the year and gets corrected by the time a final budget is proposed in May.

Last year, for instance, the Department of Education was initially off by $140 million. The year before that, the city was off by more than $70 million.

In the past, city officials said the discrepancy was caused by the timing of the budget process. With dozens of charter schools adding grades each year, they said the initial budgeting phases were too early to factor in all of the students who would be added to those schools’ rosters in the future.

“At that time, we still don’t know the full extent of how the charters are phasing in,” former Chief Financial Officer Michael Tragale said last year.

But the city apparently still hasn’t accounted for all of the students who will be added to charter schools next year. Even after the city added nearly $100 million to its initial charter school enrollment projections, the IBO still insists the city is off.

“By our estimates, they didn’t add quite enough,” said IBO spokesman Doug Turetsky.

A Department of Education spokeswoman stood by the city’s estimates. But Turetsky noted the IBO’s numbers on charter school enrollment have historically been more reliable.

Neither side could explain the remaining $13 million difference in their charter spending estimates. Turetsky said that IBO’s analysts usually take into account money that follows charter school students who receive special education services, though he didn’t think that figure would come close to $13 million.

In any event, Turetsky said he expected the problem to be resolved before the city officially enacts the budget at the end of the month.

“I’d go back to the fact that in the past [the budget office] has added funds to come into line with our projections,” Turetsky said. “I expect history will repeat.”

Follow Chalkbeat on Facebook and Twitter for the latest New York City schools news.