Jazz, like most music genres, is hard to pin down and define. One reason is that it is, as a musical form, a moving target. That's because over the years (and even today) the music continues to evolve. A big part of jazz music involves interpretation and improvisation. That in itself causes it to be in a perpetual state of flux. There is a good chance most people know jazz when they hear it, but each definition is likely to be different.
Understanding the origins of jazz is simpler than putting a box around a definition of jazz. Since traditional jazz reflects the music of the first periods of jazz, their origins are the same. The first music that was directly responsible for jazz was the "call and response" type of singing popular with slaves in the 1700s. Many will point to that music having roots in the music of their African homelands, though.
The call and response music was based heavily on the rhythmic sounds of Africa. As American influence entered in the form of folk and classical music, an evolution began. This first gave birth to the blues. Ragtime music emerged and, when it became Dixieland jazz (or "jass," as it was originally called), both jazz in general and traditional jazz were born. Dixieland jazz, coming out of New Orleans, was the first jazz music.
While jazz started in New Orleans around the start of the 20th century, it didn't stay there. As African Americans (the music was primarily an African American form by that point) moved elsewhere in the 1920s seeking better opportunities, the music went with them. This led to the start of traditional jazz forms based in Chicago, New York and other cities. At the same time, the music began to be played on radio, moving it into the wider American culture.
In the latter part of the 1920s, there was a movement in jazz toward larger groups of musicians and music that was less improvised. Scores were used with spaces for solos. This gave rise to the big band era of jazz and a new level of popularity. Traditional jazz as the only form of the musical genre came to an end in the 1930s. As some musicians moved away from the mainstream into more experimental forms, non-traditional jazz was born.