Pete Buttigieg's narrow win in Iowa makes him the first openly gay candidate to win delegates in any presidential contest.

The former mayor of South Bend, Indiana received 26.21 percent of the vote, while Vermont Senator Bernie Sanders received 26.12 percent. Rounding out the top five were Massachusetts Senator Elizabeth Warren (18.03%), former Vice President Joe Biden (15.80%), and Minnesota Senator Amy Klobuchar (12.27%).

The final results come after multiple delays blamed on a faulty app the Iowa Democratic Party used for the first time this year.

The Sanders campaign on Sunday said that it would ask for a recanvass for some of the results.

Buttigieg, who is married, has repeatedly said that the United States is ready for a gay president.

(Related: Pete Buttigieg: U.S. “absolutely” ready for gay president.)

Fred Karger made headlines in 2012 for being the nation's first openly gay presidential candidate. But his campaign for the Republican nomination never received any delegates. Karger used his campaign to raise awareness of LGBT rights.