Consider the saying, "The enemy of my enemy is my friend."
Initially, the United States planned on remaining neutral and staying out of the conflict occurring in East Asia and Europe. However, in 1939 and 1940 the United States made several agreements with Great Britain to provide support by providing Navy destroyers. By January 1941, tensions were significantly increased and Roosevelt had accused Hitler of planning world conquest. The American and British governments began discussing possible courses of action if the United States were to join the war.
Later that year the Japanese began attacks around the Pacific and Roosevelt warned that any threat to the Phillippines or countries which neighboured the United States would not be tolerated. On the seventh of December, 1941, Japan attacked numerous American and British holdings around the Pacific, prompting the United States to declare war on Japan. As Japan and Germany were part of the same Axis Powers, Germany then declared war on the United States in solidarity with Japan.
More generally, the United States feared an attempt at world conquest by fascist regimes in Germany and Japan. The United States was formally neutral on the conflict until it impacted American territory.