This rhythm pattern seems very famous and is oftenly used to knock on someone's door, sometimes as a code:


Does it have an history? Where does it come from?

2 Answers 2


This pattern comes from a fanfare often used at the end of a musical performance called "Shave and a Haircut- Two Bits" I found this reference to it on Wikipedia: Shave and a Haircut score

In music, the call "Shave and a Haircut" and the associated response "two bits" is a simple, 7-note musical couplet, riff or fanfare popularly used at the end of a musical performance, usually for comic effect. It is used both melodically and rhythmically, for example as a door knock. "Two bits" is an archaism in the United States for 25 cents, a quarter. "Six bits" is occasionally used. The final words may also be "get lost", "drop dead" (in Australia), or some other facetious expression... although words are now rarely used to accompany the rhythm or the tune.

An early occurrence of the tune is from an 1899 Charles Hale song, "At a Darktown Cakewalk". Other songs from the same period also used the tune. The same notes form the bridge in the "Hot Scotch Rag", written by H. A. Fischler in 1911.

The former prisoner of war and U.S. Navy seaman Doug Hegdahl reports fellow U.S. captives in the Vietnam War would authenticate a new prisoner's U.S. identity by using "Shave and a Haircut" as a shibboleth, tapping the first five notes against a cell wall and waiting for the appropriate response.


According to @Rodrigo (from a deleted answer)

In Mexico, people say "Chinga Tu Madre" followed by "Cabron." It's offensive in a comical way and is often used when people honk their automobile horns or whistle .

According to @PatDobson (from the comments)

This was used in great effect in the film Who framed Roger Rabbit to tempt the pesky rabbit from his hiding place in the speakeasy.

  • 1
    Hi! Thank you, Sir! I still wonder how did you find this question, and the answer, but nice find!
    – Bebs
    Mar 1, 2017 at 13:53
  • 1
    Well, as for the question I subscribe to the music group inside of the top of the list. The answer? Just one of those things that was lodged in my head LOL I don't remember where I first saw it Mar 1, 2017 at 15:30
  • *and saw it at the top of the list Mar 1, 2017 at 15:30
  • I 'knew' the answer even though our restrictive work network didn't show the image ! This was used in great effect in the film 'Who framed Roger Rabbit' to tempt the pesky rabbit from his hiding place in the speakeasy.
    – Pat Dobson
    Mar 3, 2017 at 8:01
  • "Shave and a haircut - two bits" is well known in the US, at least for those of us older than 50 or 60.
    – jrw32982
    Oct 10, 2019 at 18:10

In the Netherlands a comical music group, called The Cocktail Trio, had a hit in 1965 with a song about a flea circus. Ultimately a flea makes the biggest jump ever to the moon. The song ends with the "Shave and a haircut... two bits" riff with the Dutch line "Die zien we nooit meer... terug" wich translates as "We'll never see him... again". Everybody in the Netherlands knows this text to the riff, even if they don't know the original song.

The music to the song was composed by Ad van der Gein and Hans Ninaber. The Cocktail Trio also recorded an instrumental version with the international title Tiddley Winks. I don't think the notes of "Shave and a haircut" were invented by them. To me it sounds like something more traditional.

Not the answer you're looking for? Browse other questions tagged or ask your own question.