The results voters see reported on election night are the culmination of a lengthy process that starts well before and continues for days or weeks after Election Day. While different states, territories and the District of Columbia administer federal elections differently, they all follow similar processes to count ballots and declare winners.
Throughout the election, state and local election officials work to make the results of each race public as quickly as possible. Media outlets then use this information to predict the winner of each race, a process called “calling a race.” The ability of the media to accurately and quickly call races is important to the public’s understanding of election outcomes and to the peaceful transfer of power. Long waits for official results leave room for inaccurate information to take root, and can lead to voter confusion and dissatisfaction.
After a race is called, the media still gives updates on the ongoing vote counting until it is completed and the results are certified by election officials. This is a time-consuming process that requires a lot of effort from reporters. This is one reason why you might notice slight differences in vote counts among various media outlets at any given point: they may be collecting data from different locations at slightly different speeds, and are likely to have a variety of sources that they compare with each other.
As the votes are counted and verified, each ballot is ranked for the candidates. Your first choice candidate is counted, and then your second, third and so on. When all first-choice votes are counted, the resulting rankings can be used to determine the winner of each race.