From Wiki and my memory.
“Traditional political mapmakers, at least throughout the 20th century, had used blue to represent the modern-day Republicans, as well as the earlier Federalist Party. This may have been a holdover from the Civil War, during which the predominantly Republican north was considered “blue”.[5]”
Said it was changed permanently in 2000.
But then it is Wiki.