Japanese Defense Minister Tomomi Inada has paid a visit to Tokyo's Yasukuni Shrine.
Thursday's visit to the shrine was her first since assuming the defense portfolio.
Yasukuni Shrine honors Japan's war dead. Those remembered include leaders convicted of war crimes after World War Two.
She later told reporters that she paid for an offering out of her own pocket and signed the visitors' registry as Defense Minister Tomomi Inada.
Inada said US President Barack Obama visited the atomic-bombed city of Hiroshima earlier this year, and the Japanese prime minister paid tribute to the war dead in Hawaii's Pearl Harbor on Tuesday.
She noted that Japan and the United States, which waged the harshest battles during the war, are now the strongest allies.
She said she paid her respects with these things in mind and in the hope of building peace for Japan and the world from a future-oriented viewpoint.
Asked about expected angry reactions to her Yasukuni visit from China and South Korea, Inada said she thinks the act of expressing gratitude, respect and condolences to those who dedicated their lives to their country will be understood by any people, regardless of their historical views and whether they are friends or foes.
Before becoming defense minister, Inada visited Yasukuni Shrine on August 15th, the day Japan marks as the end of World War Two, and on other occasions.
But she did not do so on August 15th of this year, as she was on an official overseas tour.