State tax filing

OK, the $15K earnings are included in your federal taxable income and the $25K basis is an amount that you had previously deducted on one or more prior year IL tax returns.

 

The federal government does not tax return of basis.

 

Use the "Enter income you received in 2022 from a College Savings and Tuition Program (529 Plan) or ABLE account that was not included in your federal income" to enter the $25K basis.  Do not enter the $15K earnings in the IL Educational area.

 

Bottom line: IL will tax the non-qualified earnings because it is part of the federal taxable income and IL will tax the non-qualified basis distribution because it was previously excluded from IL state tax when it was contributed.