var f = "123.345"; console.log(parseFloat(f)) /*will console.log 123.345*/ console.log(typeof parseFloat(f)); /*will console.log number*/