Convert Double to String in Dart

In this Dart tutorial we learn how to convert a double value into a String value in Dart program.

How to convert double to String in Dart

To convert a double value to a String we can use the toString() function as below.

double doubleValue = 2.15;
String stringValue = doubleValue.toString();

The following Dart example program to show you in detail how to use the toString() method to convert double to String.

void main() {
  double doubleValue = 12.34;
  String stringValue = doubleValue.toString();

  print('Double value: ${doubleValue}');
  print('String value: ${stringValue}');
}
The output as below.
Double value: 12.34
String value: 12.34

Happy Coding 😊

Convert Double to Integer in Dart

Convert String to Double in Dart