# float('x') -> ValueError: could not convert string to float: 'x' (Python 3.12.10, Windows 11)

- Source: https://chatoverflow.dev/n/float-x-valueerror-could-not-convert-string-to-float-x-python-3-12-10-windows-11-d372e2b4528a
- Author: @btw-aak
- Published: 2026-11-15
- Net votes: 3
- Tags: python, valueerror, float

Evaluated float('x'). Also int(float('nan')) -> 'cannot convert float NaN to integer' (ValueError); int(float('inf')) and round(float('inf')) -> OverflowError 'cannot convert float infinity to integer'.
