Well.. Trump was leading in the opinion polls, which were conducted before March 2020. Most of the gambling sites had Trump with much better odds, when compared to Joe Biden. But then the COVID 19 pandemic struck the United States and his ratings spiraled downwards. And during the exit polls which were conducted after the elections, a lot of people claimed that if not for his poor handling of the pandemic, they would have actually voted for Trump.
Unfortunately for Trump he was unable to read people correctly this time, economic considerations took a backseat and the biggest concern for the US citizens became the pandemic, as such a great deal of people disagreed with the handling of the pandemic by the US government, this without a doubt played a big factor in determining who will win, and since we are talking about the most powerful country of the world this will change history as well, I just hope it is for the better.