Any answer to "What is Swing?" whether your looking at the music, the dance, or both, begins with understanding syncopation. In a "straight" beat rhythm, the beats of music are each evenly spaced. You can set a timer to the music's beats per minute and each beat of music would coincide with a tick of the timer. Before the 20th century, most European music was in this "straight time" rhythm, but this began changing shortly before the beginning of the 20th century with the introduction of ragtime.
Ragtime (or, ragged time) was the beginning of what is now called "swing time," or "swing rhythm," with the introduction of syncopation. With a syncopated rhythm, all the beats are not evenly spaced in time. Some beats will fall slightly before, or slightly after the expected time of when a straight beat would have landed. This rhythm is described as swinging rather than being straight. For example, in straight time, a rhythm could go "dum, tihh, dum, tihh, dum" while in a sincopated rhythm, this could go as "dum, ti-dum, dum, ti-dum".
It's this kind of syncopated rhythm that would soon become the jazz rhythm of the 1920s, and later, the swing rhythm of 1930s swing jazz. It is this rhythm that made both swing music and swing dance possible.
Swing Jazz was the style of music that began when a syncopated rhythm was added to Jazz music in the mid-1920s. Louis Armstrong is often credited for this introduction. Armstrong was a trumpet player and singer who heavily influenced both jazz music, and all music that came after him. The syncopated rhythm made the music sound more lively, and also had the psychological effect of causing listeners to want to move with the music. The Charleston was a dance that was quite popular during the 1920s, and as jazz music took on stronger syncopations, the music began influencing how the dancers danced their dance. This caused a feedback with the live bands who would begin playing their music influenced by how the dancers in front of them were dancing. By the end of the '20s, this feedback between live bands and dancers evolved both the music and the dance into new forms: swing jazz (also called "swing music" or "big band jazz"), Lindy Hop (also called "swing dancing" or "the Jitterbug").
As the jazz music and dancing entered the 1930s, jazz music and dance had started becoming what would be generally called "swing." The Lindy Hop was the big "in" dance and was starting to slowly spread across the United States from its origin at the Savoy Ballroom in Harlem New York. Many cities adapted the Lindy Hop to their own unique flavour, and Hollywood had its own version of the Lindy Hop which was more presentable on film. Local dance studios began adapting the dance to be more easily taught to the higher paying but less dedicated dancers they catered to. This process continued until the Lindy Hop had evolved into several varieties of swing dancing, some of which were no longer being danced exclusively to swing jazz music.
After the end of World War II, both swing music and the Lindy Hop quickly began to fade away. One of Lindy's decendant dances, East Coast Swing, was being adapted for the new Jump Blues music (which lead into early Rock & Roll in the 1950s). But by the end of the '50s, partnered dancing (which included all the swing dances) nearly died out completely with The Twist (a dance which could be danced by oneself).
Things improved for partnered dancing two decades later with the 1970's hustle danced to disco music. In the early 1980s, two California dancers, and a group from Sweden sought out any surviving Lindy Hop dancers and had them teach them how the dance was done. They, in turn, began teaching others. By the mid-1990s, a fairly large number of new Lindy Hop dancers had grown which lead to a swing revival that lasted from 1997 to the early 2000s. Classic styled swing jazz music came back with it, and many bands put a modern twist on some of the music creating what some call "neo-swing" music, or "jump swing." This neo-swing music combined classic swing jazz and jump blues music with modern punk, ska, hip-hop, and rock music. By the middle of the first decade of the 2000s, the bubble of new dancers and new bands had dwindled, but neither have died off like it had in the middle of the previous century. Large communities of swing dancers can be found in many medium to large cities across the United States and other countries, and networks of dancers, musicians have been established to keep the communities connected with each other. Many swing dance events are currently held across the world keeping swing alive.