WASHINGTON — Rear Adm. John F. Kirby, the Pentagon press secretary and the public face of the American military for the past year, is stepping down, officials said Wednesday, the first casualty of a new defense secretary who has expressed reservations about having a uniformed officer represent the Defense Department in its daily dealings with the news media.

Unlike Chuck Hagel, the previous Pentagon chief, Ashton B. Carter, who was confirmed as defense secretary last Thursday, wants a civilian in the role of chief spokesman, administration officials said. Admiral Kirby was told in recent weeks that Mr. Carter wanted to bring in his own press secretary.

It was unclear on Wednesday who would replace Admiral Kirby, who has agreed to stay on for the next couple of weeks to help with the transition.

Cabinet members often bring in their own press secretaries and senior staff members. But Mr. Carter’s decision to replace Admiral Kirby, who is respected by reporters and military officials, came as a surprise because of his success in the role, administration officials said. Admiral Kirby has been credited with helping to heal the rift between the White House and the Pentagon over the troop buildup in Afghanistan during President Obama’s first term.