Anpan was first made in 1875, during the Meiji period, by a man called Yasubei Kimura, a samurai who lost his job with the rise of the conscript Imperial Army and the dissolution of the samurai as a social class. The Meiji era was a period in which Japan was becoming increasingly westernized, and many samurai who lost their jobs were given work that was totally new to them. The Western role of baker was one such job.
One day, while wandering around the area where many people employed in Western jobs worked, Kimura Yasubei found a young man making breads and an idea was born; the starting of the bakery named Bun'eidō (文英堂). In 1874, He moved to Ginza and renamed the bakery Kimuraya (木村屋). At that time, however, the only recipe for bread known in Japan was for making a salty and sour-tasting bread, ill-suited to Japanese tastes at the time. Yasubei wanted to make a bread that was more to Japanese tastes. Finally, he figured out how to make bread in the way of the Japanese manju – raising the dough with the traditional sakadane liquid yeast. He then filled the bread with a bean paste wagashi and sold anpan as snacks. Anpan was very popular, not only because of its taste, but also because the Japanese were interested in anything new and foreign at this time.
Later, a man called Yamaoka Tesshū, a chamberlain of the Meiji emperor, who loved anpan, asked the Tokugawas, the rulers of Japan before the Meiji Period, to present anpans to the emperor when visiting him. So the Tokugawas asked Yasubei to make some for the emperor. Yasubei worked hard to make the anpan and, because he also cared about their appearance, he decorated them with a salt-pickled sakura in the middle of each bun. This anpan was presented to the Meiji emperor on April 4, 1875. The Emperor told Yasubei to present him anpan everyday, and because of the rumor that the Emperor ate anpan, the popularity of bread, and especially anpan, began spreading around the country.