From 5bdcdcae0306606a42f087711a804b9de072237b Mon Sep 17 00:00:00 2001 From: Max Ghenis Date: Sun, 11 Oct 2026 11:40:13 -0400 Subject: [PATCH] Limit Kansas itemized deductions to the four K.S.A. 79-32,120(a) categories Kansas allows charitable contributions (100%), medical care, qualified residence interest and real and personal property taxes (50% in 2015-2017 without medical, 50% in 2018, 75% in 2019, 100% from 2020). Main summed every federal non-SALT itemized deduction, including investment interest, casualty losses, pre-2018 miscellaneous deductions and the 2020-2021 non-itemizer charitable deduction, at 100% in all years. Before 2021, (a)(1)(A) lets only federal itemizers itemize in Kansas. Co-Authored-By: Claude Opus 5.5 --- ...s-itemized-deductions-closed-list.fixed.md | 1 + .../federal_itemization_required.yaml | 13 ++++ .../rate/charitable_contributions.yaml | 14 ++++ .../itemized/rate/medical_expenses.yaml | 19 +++++ .../itemized/rate/property_taxes.yaml | 18 +++++ .../rate/qualified_residence_interest.yaml | 18 +++++ .../ks/tax/income/ks_itemized_deductions.yaml | 75 ++++++++++++++++++- .../ks/tax/income/ks_taxable_income.yaml | 38 ++++++++++ .../deductions/ks_itemized_deductions.py | 35 +++++---- .../states/ks/tax/income/ks_taxable_income.py | 9 ++- 10 files changed, 223 insertions(+), 17 deletions(-) create mode 100644 changelog.d/ks-itemized-deductions-closed-list.fixed.md create mode 100644 policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/federal_itemization_required.yaml create mode 100644 policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/charitable_contributions.yaml create mode 100644 policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/medical_expenses.yaml create mode 100644 policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/property_taxes.yaml create mode 100644 policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/qualified_residence_interest.yaml diff --git a/changelog.d/ks-itemized-deductions-closed-list.fixed.md b/changelog.d/ks-itemized-deductions-closed-list.fixed.md new file mode 100644 index 00000000000..9fc3e9221df --- /dev/null +++ b/changelog.d/ks-itemized-deductions-closed-list.fixed.md @@ -0,0 +1 @@ +Limit Kansas itemized deductions to charitable contributions, medical care, qualified residence interest and property taxes at the K.S.A. 79-32,120(a) shares for each year, and require federal itemizing before 2021. diff --git a/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/federal_itemization_required.yaml b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/federal_itemization_required.yaml new file mode 100644 index 00000000000..7f703f9cc34 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/federal_itemization_required.yaml @@ -0,0 +1,13 @@ +description: Kansas allows the Kansas itemized deduction only to filers who itemize on their federal return, if this is true. +values: + 2015-01-01: true + 2021-01-01: false +metadata: + unit: bool + period: year + label: Kansas itemized deduction requires federal itemization + reference: + - title: K.S.A. 79-32,120(a)(1) + href: https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html + - title: 2018 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip18.pdf#page=2 diff --git a/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/charitable_contributions.yaml b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/charitable_contributions.yaml new file mode 100644 index 00000000000..303f4796749 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/charitable_contributions.yaml @@ -0,0 +1,14 @@ +description: Kansas allows this share of charitable contributions deductible under section 170 of the Internal Revenue Code as an itemized deduction. +values: + 2015-01-01: 1 +metadata: + unit: /1 + period: year + label: Kansas itemized deduction share of charitable contributions + reference: + - title: K.S.A. 79-32,120(a) + href: https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html + - title: 2017 Form K-40 instructions, Schedule S Part C, line C4 + href: https://www.ksrevenue.gov/pdf/ip17.pdf#page=14 + - title: 2025 Form K-40 instructions, Kansas Schedule A + href: https://www.ksrevenue.gov/pdf/ip25.pdf#page=14 diff --git a/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/medical_expenses.yaml b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/medical_expenses.yaml new file mode 100644 index 00000000000..4513fbe69de --- /dev/null +++ b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/medical_expenses.yaml @@ -0,0 +1,19 @@ +description: Kansas allows this share of medical expenses deductible under section 213 of the Internal Revenue Code as an itemized deduction. +values: + 2015-01-01: 0 + 2018-01-01: 0.5 + 2019-01-01: 0.75 + 2020-01-01: 1 +metadata: + unit: /1 + period: year + label: Kansas itemized deduction share of medical expenses + reference: + - title: K.S.A. 79-32,120(a) + href: https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html + - title: 2018 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip18.pdf#page=2 + - title: 2019 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip19.pdf#page=2 + - title: 2025 Form K-40 instructions, Kansas Schedule A, lines 1 to 4 + href: https://www.ksrevenue.gov/pdf/ip25.pdf#page=14 diff --git a/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/property_taxes.yaml b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/property_taxes.yaml new file mode 100644 index 00000000000..f9e7a9f4993 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/property_taxes.yaml @@ -0,0 +1,18 @@ +description: Kansas allows this share of taxes on real and personal property under section 164(a) of the Internal Revenue Code as an itemized deduction. +values: + 2015-01-01: 0.5 + 2019-01-01: 0.75 + 2020-01-01: 1 +metadata: + unit: /1 + period: year + label: Kansas itemized deduction share of real and personal property taxes + reference: + - title: K.S.A. 79-32,120(a) + href: https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html + - title: 2017 Form K-40 instructions, Schedule S Part C, lines C1 and C2 + href: https://www.ksrevenue.gov/pdf/ip17.pdf#page=14 + - title: 2018 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip18.pdf#page=2 + - title: 2019 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip19.pdf#page=2 diff --git a/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/qualified_residence_interest.yaml b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/qualified_residence_interest.yaml new file mode 100644 index 00000000000..a1168914900 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ks/tax/income/deductions/itemized/rate/qualified_residence_interest.yaml @@ -0,0 +1,18 @@ +description: Kansas allows this share of qualified residence interest under section 163(h) of the Internal Revenue Code as an itemized deduction. +values: + 2015-01-01: 0.5 + 2019-01-01: 0.75 + 2020-01-01: 1 +metadata: + unit: /1 + period: year + label: Kansas itemized deduction share of qualified residence interest + reference: + - title: K.S.A. 79-32,120(a) + href: https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html + - title: 2017 Form K-40 instructions, Schedule S Part C, lines C3 + href: https://www.ksrevenue.gov/pdf/ip17.pdf#page=14 + - title: 2018 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip18.pdf#page=2 + - title: 2019 Form K-40 instructions, itemized deductions + href: https://www.ksrevenue.gov/pdf/ip19.pdf#page=2 diff --git a/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_itemized_deductions.yaml b/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_itemized_deductions.yaml index 63a6603f62b..c8f977b3367 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_itemized_deductions.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_itemized_deductions.yaml @@ -3,7 +3,7 @@ input: real_estate_taxes: 8 salt_deduction: 10 - interest_deduction: 9 + deductible_mortgage_interest_tax_unit: 9 medical_expense_deduction: 2 state_code: KS output: @@ -14,8 +14,79 @@ input: real_estate_taxes: 12 salt_deduction: 10 - interest_deduction: 9 + deductible_mortgage_interest_tax_unit: 9 medical_expense_deduction: 2 state_code: KS output: ks_itemized_deductions: 12 + 9 + 2 + +# K.S.A. 79-32,120(a)(5): from 2020, 100% of charitable contributions, medical +# care, qualified residence interest and real and personal property taxes. +# Investment interest and casualty losses are not Kansas itemized deductions. +- name: Case 3, 2025 only the four Kansas categories count. + period: 2025 + input: + state_code: KS + charitable_deduction: 3_000 + medical_expense_deduction: 2_000 + deductible_mortgage_interest_tax_unit: 9_000 + interest_deduction: 13_000 + casualty_loss_deduction: 1_000 + real_estate_taxes: 5_000 + output: + # 3,000 + 2,000 + 9,000 + 5,000; not the 4,000 of investment interest in + # interest_deduction or the 1,000 casualty loss. + ks_itemized_deductions: 19_000 + +# K.S.A. 79-32,120(a)(4): 2019 allows 100% of charity and 75% of the other +# three categories. +- name: Case 4, 2019 shares. + period: 2019 + input: + state_code: KS + charitable_deduction: 1_000 + medical_expense_deduction: 2_000 + deductible_mortgage_interest_tax_unit: 8_000 + real_estate_taxes: 4_000 + output: + # 1,000 + 0.75 * (2,000 + 8,000 + 4,000) + ks_itemized_deductions: 11_500 + +# K.S.A. 79-32,120(a)(3): 2018 allows 100% of charity and 50% of the other +# three categories. +- name: Case 5, 2018 shares. + period: 2018 + input: + state_code: KS + charitable_deduction: 1_000 + medical_expense_deduction: 2_000 + deductible_mortgage_interest_tax_unit: 8_000 + real_estate_taxes: 4_000 + output: + # 1,000 + 0.5 * (2,000 + 8,000 + 4,000) + ks_itemized_deductions: 8_000 + +# K.S.A. 79-32,120(a)(2): 2015 to 2017 allow 100% of charity, 50% of qualified +# residence interest and property taxes, and no medical care (2017 Schedule S, +# Part C). +- name: Case 6, 2017 shares, no medical expenses. + period: 2017 + input: + state_code: KS + charitable_deduction: 1_000 + medical_expense_deduction: 2_000 + deductible_mortgage_interest_tax_unit: 8_000 + real_estate_taxes: 4_000 + output: + # 1,000 + 0.5 * (8,000 + 4,000) + ks_itemized_deductions: 7_000 + +- name: Case 7, 2021 federal deduction for non-itemizers' charitable gifts is not a Kansas itemized deduction. + period: 2021 + input: + state_code: KS + charitable_deduction: 2_000 + charitable_deduction_for_non_itemizers: 300 + real_estate_taxes: 4_000 + output: + ks_itemized_deductions: 6_000 diff --git a/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_taxable_income.yaml b/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_taxable_income.yaml index 80de06563bb..66d2d2060cc 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_taxable_income.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/ks/tax/income/ks_taxable_income.yaml @@ -30,3 +30,41 @@ state_code: KS output: ks_taxable_income: 0 + +# K.S.A. 79-32,120(a)(1)(A): before 2021, only federal itemizers may take the +# Kansas itemized deduction; (a)(1)(B) removes that condition from 2021. +- name: Case 4, 2019 non-itemizer federally takes the Kansas standard deduction. + period: 2019 + input: + ks_agi: 50_000 + ks_standard_deduction: 3_000 + ks_itemized_deductions: 9_000 + ks_exemptions: 2_250 + tax_unit_itemizes: false + state_code: KS + output: + ks_taxable_income: 50_000 - 3_000 - 2_250 + +- name: Case 5, 2019 federal itemizer takes the larger Kansas itemized deduction. + period: 2019 + input: + ks_agi: 50_000 + ks_standard_deduction: 3_000 + ks_itemized_deductions: 9_000 + ks_exemptions: 2_250 + tax_unit_itemizes: true + state_code: KS + output: + ks_taxable_income: 50_000 - 9_000 - 2_250 + +- name: Case 6, 2021 Kansas itemizing no longer requires federal itemizing. + period: 2021 + input: + ks_agi: 50_000 + ks_standard_deduction: 3_500 + ks_itemized_deductions: 9_000 + ks_exemptions: 2_250 + tax_unit_itemizes: false + state_code: KS + output: + ks_taxable_income: 50_000 - 9_000 - 2_250 diff --git a/policyengine_us/variables/gov/states/ks/tax/income/deductions/ks_itemized_deductions.py b/policyengine_us/variables/gov/states/ks/tax/income/deductions/ks_itemized_deductions.py index fd0b8dee13f..ce52850b5fc 100644 --- a/policyengine_us/variables/gov/states/ks/tax/income/deductions/ks_itemized_deductions.py +++ b/policyengine_us/variables/gov/states/ks/tax/income/deductions/ks_itemized_deductions.py @@ -8,21 +8,28 @@ class ks_itemized_deductions(Variable): unit = USD definition_period = YEAR reference = ( - "https://www.ksrevenue.gov/pdf/ip21.pdf", - "https://www.ksrevenue.gov/pdf/ip22.pdf", + "https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html", + "https://www.ksrevenue.gov/pdf/ip17.pdf#page=14", + "https://www.ksrevenue.gov/pdf/ip25.pdf#page=14", ) defined_for = StateCode.KS def formula(tax_unit, period, parameters): - # 2021 Form K-40 instructions say this: - # LINE 4 (Standard deduction or itemized deductions): - # If you did not itemize your deductions on your federal return, - # you may choose to itemize your deductions or claim the - # standard deduction on your Kansas return whichever is to your - # advantage. If you itemized on your federal return, you may - # either itemize or take the standard deduction on your Kansas - # return, whichever is to your advantage. - # compute itemized deduction maximum - itm_deds_less_salt = tax_unit("itemized_deductions_less_salt", period) - uncapped_property_taxes = add(tax_unit, period, ["real_estate_taxes"]) - return itm_deds_less_salt + uncapped_property_taxes + # K.S.A. 79-32,120(a) limits the Kansas itemized deduction to four + # federal categories, each at a year-specific share. Other federal + # itemized deductions (investment interest, casualty and theft losses, + # miscellaneous deductions) do not count. Property taxes are not limited + # by the federal cap on state and local taxes. + p = parameters(period).gov.states.ks.tax.income.deductions.itemized.rate + charitable = tax_unit("charitable_deduction", period) + medical = tax_unit("medical_expense_deduction", period) + qualified_residence_interest = tax_unit( + "deductible_mortgage_interest_tax_unit", period + ) + property_taxes = add(tax_unit, period, ["real_estate_taxes"]) + return ( + p.charitable_contributions * charitable + + p.medical_expenses * medical + + p.qualified_residence_interest * qualified_residence_interest + + p.property_taxes * property_taxes + ) diff --git a/policyengine_us/variables/gov/states/ks/tax/income/ks_taxable_income.py b/policyengine_us/variables/gov/states/ks/tax/income/ks_taxable_income.py index 79dba7f7981..f690bf4a6c3 100644 --- a/policyengine_us/variables/gov/states/ks/tax/income/ks_taxable_income.py +++ b/policyengine_us/variables/gov/states/ks/tax/income/ks_taxable_income.py @@ -10,12 +10,19 @@ class ks_taxable_income(Variable): reference = ( "https://www.ksrevenue.gov/pdf/ip21.pdf", "https://www.ksrevenue.gov/pdf/ip22.pdf", + "https://www.ksrevisor.gov/statutes/chapters/ch79/079_032_0120.html", ) defined_for = StateCode.KS def formula(tax_unit, period, parameters): + p = parameters(period).gov.states.ks.tax.income.deductions.itemized std_ded = tax_unit("ks_standard_deduction", period) itm_ded = tax_unit("ks_itemized_deductions", period) - deductions = where(itm_ded > std_ded, itm_ded, std_ded) + # K.S.A. 79-32,120(a)(1): before 2021, only federal itemizers may + # itemize on the Kansas return. + may_itemize = True + if p.federal_itemization_required: + may_itemize = tax_unit("tax_unit_itemizes", period) + deductions = where(may_itemize & (itm_ded > std_ded), itm_ded, std_ded) exemptions = tax_unit("ks_exemptions", period) return max_(0, tax_unit("ks_agi", period) - deductions - exemptions)