You can parse a string into an integer with int.parse(). For example:

var myInt = int.parse('12345');
assert(myInt is int);
print(myInt); // 12345

Note that int.parse() accepts 0x prefixed strings. Otherwise the input is treated as base-10.

You can parse a string into a double with double.parse(). For example:

var myDouble = double.parse('123.45');
assert(myDouble is double);
print(myDouble); // 123.45

parse() will throw FormatException if it cannot parse the input.

Answer from Seth Ladd on Stack Overflow
🌐
Flutter
api.flutter.dev › flutter › dart-core › int › parse.html
parse method - int class - dart:core library - Dart API
external static int parse(String source, {int? radix}); Flutter · dart:core · int · parse static method ·
🌐
BezKoder
bezkoder.com › home › how to parse a string into a number in dart/flutter
How to parse a String into a number in Dart/Flutter - BezKoder
April 1, 2022 - – Dart/Flutter Constructors tutorial with examples – Dart/Flutter String Methods & Operators tutorial with examples – Dart/Flutter Future Tutorial with Examples – Dart/Flutter List Tutorial with Examples – Dart/Flutter Map Tutorial with Examples ... Sometimes we have to work with string in radix number format. Dart int parse() method also supports convert string into a number with radix in the range 2..36:
🌐
Medium
medium.com › nextfunc › dart-flutter-how-to-parse-string-to-number-22c6e181e599
Dart/Flutter — How to parse String to number | by Phuc Tran | Nextfunc Co., Ltd | Medium
November 7, 2020 - This is the difference between tryParse() and parse() (which throws exception if we don’t handle onError method). int stringToInt_tryParse(String input) { return int.tryParse(input); } double stringToDouble_tryParse(String input) { return double.tryParse(input); } num stringToNumber_tryParse(String input) { return num.tryParse(input); }
🌐
LogRocket
blog.logrocket.com › home › how to parse json strings in flutter
How to parse JSON strings in Flutter - LogRocket Blog
June 4, 2024 - To serialize and parse this JSON data within our Flutter app, simply paste it into the JSON to Dart converter, as shown below: Now we can just copy and paste the BoredAPI class into our app as we see fit.
🌐
Flutter
api.flutter.dev › flutter › dart-core › Uri › parse.html
parse method - Uri class - dart:core library - Dart API
... final uri = Uri.parse('https://example.com/api/fetch?limit=10,20,30&max=100'); print(uri); // https://example.com/api/fetch?limit=10,20,30&max=100 Uri.parse('::Not valid URI::'); // Throws FormatException. static Uri parse(String uri, [int start = 0, int?
Find elsewhere
🌐
Flutter
api.flutter.dev › flutter › dart-core › DateTime › parse.html
parse method - DateTime class - dart:core library - Dart API
We only use the first 6 digits because of DateTime // precision of 999 milliseconds and 999 microseconds. int parseMilliAndMicroseconds(String?
🌐
BezKoder
bezkoder.com › home › dart/flutter – convert/parse json string, array into object, list
Dart/Flutter - Convert/Parse JSON string, array into Object, List - BezKoder
April 1, 2022 - – Dart/Flutter Constructors tutorial ... Tutorial with Examples ... dart:convert library has a built-in jsonDecode top-level function that can parse a string and return the a JSON object (dynamic)....
🌐
Code with Andrea
codewithandrea.com › articles › parse-json-dart
How to Parse JSON in Dart/Flutter: The Ultimate Guide
But inside our Flutter apps, we don't want to extract the data from a string manually: // a json payload represented as a (multi-line) string final json = ''' { "name": "Pizza da Mario", "cuisine": "Italian", "reviews": [ { "score": 4.5, "review": "The pizza was amazing!" }, { "score": 5.0, "review": "Very friendly staff, excellent service!" } ] } '''; Instead, we can decode the JSON first to obtain a map of key-value pairs that can be more easily parsed.
🌐
Flutter Gems
fluttergems.dev › parsing-other-utilities
Top Flutter Text Parsing, Text Utility, String Utility packages | Flutter Gems
Removes common accents and diacritical signs from a string by replacing them with an equivalent character. ... A utility for counting in a variety of languages and styles. Made for lists.
🌐
Bacancy Technology
bacancytechnology.com › qanda › flutter › parse-a-string-to-a-number-in-dart
How to Parse a String to a Number in Dart: Complete Guide
– Flutter provide int.parse() and int.tryParse() method. – We use this method when we are sure like string contains only numbers. If string contain alphabet then it throws a Format Exception.
🌐
Pub.dev
pub.dev › packages › flutter_text_parser
flutter_text_parser | Flutter package
September 28, 2025 - import 'package:flutter_text_parser/flutter_text_parser.dart'; void main() { String text = "<b><i>Flutter</i></b> is <color:red>awesome</color>!"; List<TextPart> parsed = text.parsedSpanTexts; for (var part in parsed) { print(part); // Output: SpannedText(text: Flutter, tags: [b, i]) // NormalText( is ) // SpannedText(text: awesome, tags: [color:red]) } }
Published   Sep 16, 2025
Version   1.0.2