c# char to int code example Example 1: c# char to int int val = (int)Char.GetNumericValue('8'); Example 2: c convert char to int int i = (int)(c - '0');