You need to double check your w2 entry screen. It sounds like both w2s are under one name. The child care credit is to allow you to work or go to school. If not disabled or in school, you must both have earned income and the lowest income limits the credit.
From Child and Dependent Care Credit FAQs
A1. You are eligible to claim this credit if you (or your spouse in the case of a joint return) pay someone to care for one or more qualifying persons in order for you to work or look for work, and your income level is within the income limits set for the credit. If you are married, you must file a joint return to claim the credit. However, if you are legally separated or living apart from your spouse, you may be able to file a separate return and still claim the credit. If you or your spouse was a full-time student, see Q17 and IRS Publication 503, Child and Dependent Care Expenses, for more information on eligibility.
Earned Income Requirement: You (and your spouse in the case of a joint return) must have earned income during the year to claim the credit. See Q16 and Q17 for more information, including special rules that may apply if you are a student or are unable to care for yourself.
Reference:
About Form 2441, Child and Dependent Care Expenses
Thanks for the suggestion. My income is W-2 and my wife's is 1099-NEC from self-employed work as an independent contractor. I checked, and the income is indeed divided under the appropriate names. Plus, everything I read seems to indicate that 1099-NEC still counts as earned income. For example: "Earned income includes wages, salaries, tips, other taxable employee compensation, and net earnings from self-employment." (https://www.irs.gov/publications/p503#en_US_2023_publink1000203280)
I do have some good news, though. I figured out how to force TurboTax Desktop to allow me to claim the credit. I filled it out with myself as a student (as I indicated above). Then, I was able to switch to Forms mode and delete any reference to me being a student. I double-checked everything and it looks like all of the numbers are correct after the change.
Thank you again for your help. This workaround at least fixes the issue for me.