The United States became directly involved in World War I after declaring war on Germany on April 6, 1917. The declaration ended nearly three years of American neutrality in the war since the beginning, and the country's involvement in the conflict lasted for nineteen months before a ceasefire and armistice were declared on November 11, 1918. The U.S. played a major role in providing much needed supplies, raw material, and money to the United Kingdom, France, and the other Allied powers, even well before 1917.
After declaring war, the U.S. mobilized over 5 million military personnel. General John J. Pershing commanded the American Expeditionary Force (AEF) in France, in which over 2 million American soldiers served.