The Civil War was about a lot more than just slavery (it always surprises me when some people argue about this). It’s very easy to point to the south and say that they were just trying to preserve their plantation way of life and keep their slaves. But if you look at the north, their motivations were much more complex.
There was an anti-slavery sentiment that had been growing in popularity for many years, and many northerners did support the war because of it.
Patriotism, as Colibri detailed, was also a very important reasons for many northerners.
States rights factored into it as well. This wasn’t necessarily about the rights of states to do what they wanted within their borders as it was an overall fight for control of the country. Starting very early in the 1800s, you had this battle between the southern agricultural states and the northern industrial states, and back then, like today, people didn’t necessarily compromise very well. Instead, whichever group happened to have more votes in congress used their majority vote to beat the other group into submission (just like today - we never learn). So as each group of states tries to exert its will over the others, and the balance of power keeps shifting back and forth, you end up with a lot of anger on all sides. This was probably a big factor for the farm boys out west mostly due to the anger and control issues involved. They were so angry at the southern states for trying to rip the country apart and for trying to push down their states economically and politically that a lot of them felt that something simply had to be done about those damn southerners. The Civil War didn’t happen over night, and the decades of political fighting leading up to it where the main issue is mostly anger and control are a much more important factor than a lot of people seem to realize. Without that built up anger, a lot of folks wouldn’t have felt a need to pick up a weapon and shoot the other guy with it.
So there were a lot of reasons and a lot of anger on both sides, plus folks back then had a lot different ideas about war. Attitudes about war changed rather dramatically in the Vietnam era. You have to look back and see how folks back then saw war, which was a lot different than how we view it. Duty and honor were a lot more important. People had faith in their leaders. It was a whole different world back then.