How to Convert String to Double in Python 2022-08-25 58 words - 1 min read If you need to convert a String to a Double in your Python code: Option 1 – Convert String to Double using float() 1 2 3 string = '1234.5678' myfloat = float(string) print(myfloat) Option 2 – Convert String to Double using decimal.Decimal() 1 2 3 4 5 from decimal import Decimal string = '1234.5678' myfloat = Decimal(string) print(myfloat)