In the late 19th century, Scott Joplin, a young African-American musician, moves to Missouri and to make ends meet finds a job as a piano teacher. He befriends Louis Chauvin, who plays piano in a brothel.
Joplin composes ragtime music. One day his "Maple Leaf Rag" is heard by John Stark, a publisher of sheet music in St. Louis. Stark is impressed, buys the rights to the composition and sells it, with Joplin sharing some of the profits. Joplin's new songs also achieve a great popularity.
Chauvin is equally talented, but contracts syphilis and dies in his 20s. Joplin, meantime, becomes obsessed with composing more serious music, yet is continually thwarted in his attempt to write and publish an opera.