In 1901, William S. Harley, age 21, drew up plans for a small engine with a displacement of 7.07 cubic inches (116 cc) and four-inch (102 mm) flywheels. The engine was designed for use in a regular pedal-bicycle frame. Over the next two years Harley and his childhood friend Arthur Davidson labored on their motor-bicycle using the northside Milwaukee machine shop at the home of their friend, Henry Melk.
Work immediately began on a new and improved second-generation machine. This first "real" Harley-Davidson motorcycle had a bigger engine of 24.74 cubic inches (405 cc) with 9.75 inches (25 cm) flywheels weighing 28 lb (13 kg). The machine's advanced loop-frame pattern was similar to the 1903 Milwaukee Merkel motorcycle.
In January 1905, small advertisements were placed in the "Automobile and Cycle Trade Journal" that offered bare Harley-Davidson engines to the do-it-yourself trade. By April, complete motorcycles were in production on a very limited basis. That year the first Harley-Davidson dealer, Carl H. Lang of Chicago, sold three bikes from the dozen or so built in the Davidson backyard shed.
In 1917, the United States entered World War I and the military demanded motorcycles for the war effort. Harleys had already been used by the military in the Pancho Villa Expedition but World War I was the first time the motorcycle had been adopted for combat service. Harley-Davidson provided about 15,000 machines to the military forces during World War I.
By 1920, Harley-Davidson was the largest motorcycle manufacturer in the world. Their motorcycles were sold by dealers in 67 countries. Production was 28,189 machines. In 1921, a Harley-Davidson, ridden by Otto Walker, was the first motorcycle ever to win a race at an average speed of over 100 mph (160 km/h)
One of only two American cycle manufacturers to survive the Great Depression, Harley-Davidson again produced large numbers of motorcycles for the US Army in World War II and resumed civilian production afterwards, producing a range of large V-twin motorcycles that were successful both on racetracks and for private buyers.
In 1969, American Machinery and Foundry (AMF) bought the company, streamlined production, and slashed the workforce. This tactic resulted in a labor strike and a lower quality of bikes. The bikes were expensive and inferior in performance, handling, and quality to Japanese motorcycles. Sales declined, quality plummeted, and the company almost went bankrupt. The "Harley-Davidson" name was mocked as "Hardly Ableson", "Hardly Driveable," and "Hogly Ferguson", and the nickname "Hog" became pejorative.
In 1977, Harley-Davidson produced what has become one of its most controversial models, the Confederate Edition. The bike was essentially a stock Harley with Confederate-specific paint and details.
Building started on $75 million 130,000 square-foot (12,000 m2) Harley-Davidson Museum in the Menomonee River Valley on June 1, 2006. It opened in 2008 and houses the company's vast collection of historic motorcycles and corporate archives, along with a restaurant, café and meeting space.