Tatsuya Naka demonstrates the shotokan heian (pinan) katas with his personal bunkai explanations.
The Heian (peaceful mind) kata are derived from the older Okinawan Pinan kata (which also means peaceful or calm mind). Sensei Gichin Funakoshi changed the name of these and many other Shotokan kata when he took karate to Japan in the early 1920s in a bid to make them more accessible to a Japanese consumer base. An interesting karate history fact is that the kata we know today as Heian Nidan was originally the first of the Heian kata until in the 1930s, Funakoshi switched Nidan with Shodan. Some styles still practice it the original way around though what Shotokan karate calls Heian Shodan is arguably a lot easier than Nidan, which is probably why they were switched in the first place.
They are practiced and seemingly designed so that students can learn increasingly difficult techniques as they progress in the art of karate and they were developed by Okinawan Master Anko Itosu at the turn of the twentieth century. However, the Heian kata probably have their origins in much older forms from China known as Channan or Kushanku (Kanku Sho and Dai may also originate from these kata). Legend has it that Master Itosu (or perhaps an older teacher, Tode Sakugawa) learned a kata called ‘Chiang Nan’(pronounced Channan in Japanese) from a Chinese diplomat and Kung Fu expert who lived in Okinawa called Kung Hsiang Chun. Though the original kata is lost, it is believed that it was very long so Itosu divided it into five as they would be easier to learn.
Another theory is that Itosu, who took the previously secretive martial art into the schools in Okinawa, found that children had difficulty learning kata so he devised the Pinan kata group to aid this. It is believed by some that he took moves from the Bassai and the Kanku sets in particular and arranged them so they gradually got more difficult through the various Pinan kata.