There's rarely a simple answer for entering a war. The simplest explanation would probably be that there had been problems with German subs moving in U.S. waters. When the Germans sank the Lusitania that was sort of the last straw. By that time, Germany's enemies were seen as holding the moral highground. So the perception that England and France were standing firm against an invading, malevolent force, in combination with the sub encroachments and Lusitania sinking, gave the the US the push it needed to enter the war.