GUATEMALA CITY — A comedian won the first round of voting in Guatemala’s presidential election, five days after a wave of protests forced the country’s president from office.

Jimmy Morales, a television comedian with name recognition but no political experience, emerged seemingly out of nowhere to move up in the polls as the political crisis deepened over the summer. The latest count gives him almost 24 percent of the vote.

Only a few thousand votes separated the second-place finishers, as the last results of Sunday’s elections came in Monday. Mr. Morales and the candidate receiving the next highest number of votes will head to a runoff in October.

Julio Solórzano, a member of the electoral tribunal, said that the results would not be known until each district made an official count of the preliminary results, expected by Friday. Candidates may also file challenges to the result, but Guatemalan law does not provide for a recount.