Jakarta, April 17 -- Tens of millions of Indonesians were voting in presidential and legislative elections Wednesday after a campaign that pitted the moderate incumbent against an ultranationalist former general whose fear-based rhetoric warned the country would fall apart without his strongman leadership.

The first votes were cast in easternmost provinces after polling booths opened at 7 a.m. followed an hour later by central regions such as Bali and then the capital Jakarta and western provinces. Indonesia, a sprawling archipelago of 17,000 islands and hundreds of ethnic groups, has three time zones.

About 193 million people are eligible to vote in polls that will decide who leads the world's most populous Muslim-majority nation and t...