500002587 in words is written as :

Million Two Thousand Five Hundred and Eighty Seven