Probably doesn't happen often but, It Does Happen:
Elections Won By One Vote
The races won by a single vote, in addition to the new 1910 Congressional election in New York, according to Mulligan and Hunter, were:
a 1982 state House election in Maine in which the victor won 1,387 votes to the loser’s 1,386 votes
a 1982 state Senate race in Massachusetts in which the victor won 5,352 votes to the loser’s 5,351; a subsequent recount late found wider margin
a 1980 state House race in Utah in which the victor won 1,931 votes to the loser’s 1,930 votes
a 1978 state Senate race in North Dakota in which the victor won 2,459 votes to the loser’s 2,458 votes; a subsequent recount found the margin to be six votes
a 1970 state House race in Rhode Island in which the victor won 1,760 votes to the loser’s 1,759
a 1970 state House race in Missouri in which the victor won 4,819 votes to the loser’s 4,818 votes
and a 1968 state House race in Wisconsin in which the victor won 6,522 votes to the loser’s 6,521 votes; a subsequent recount found the margin to be two votes, not one.
A 1978 race for Rhode Island state Senate was tied at 4,110 votes, and decided by a second runoff election. So was a 1980 race for New Mexico state House, at 2,327 votes for each candidate.