Former samurai Yasubei Kimura found himself out of work following the dissolution of the samurai class and the rise of an all-conscript military during the Meiji Period (1868-1912). In 1869, he founded a bakery named Bun'eido in what is now the Shinbashi area of Tokyo, picking up on the staple that had been recently reintroduced to Japan, but which had yet to gain local popularity. A year later, he moved to Ginza and renamed his shop Kimuraya.
The only breads available in Japan at the time were salty and sour, which did not suit the Japanese palate. Kimura aspired to create bread that was better suited to local tastes. For inspiration, he looked to manju, traditional sweets made with red bean paste (an or anko) surrounded by mochi (glutinous rice cake). He substituted bread (locally known as pan) for mochi, raising the dough with sakadane liquid yeast derived from sake. The result, first created in 1874, was very close to the anpan we see today.
Anpan quickly caught on in Tokyo, a revolutionary new product at a time when Japanese people were eager to try new and foreign goods. It gained such a reputation that it was presented to Emperor Meiji on April 4, 1875, with Kimura adding a pickled cherry blossom in each bun to match the occasion of the cherry blossom season. It's said the emperor appreciated the treat so much that he asked for Kimura to continue to send him anpan every day, leading to an explosion in popularity that reached across the country by 1897.
More than a century later, Kimuraya (now officially Kimuraya Sohonten, Ltd.) stills sells the anpan that gained it fame and success. Beyond its basic anpan, Kimuraya has released innovative and delicious variants over the years, including seasonal anpan such as sakura (cherry blossom) anpan in spring and kuri (chestnut) anpan in autumn—not to mention creating jam pan in 1900, which you'll still find in bakeries to this day.