WASHINGTON — President Trump’s embattled chief of staff, John F. Kelly, told his senior aides on Monday that the president had asked him to stay on in his job through 2020, and that he had accepted, according to three senior administration officials.

Mr. Kelly’s disclosure puts to rest, at least for the moment, the persistent rumors that the retired Marine Corps general would soon leave the White House. It came on his first anniversary in the job — a roller coaster tenure that has lately been marked by a perceptible downward slide in his authority and visibility.

Still, after months of questions about how long Mr. Kelly would last and who would replace him, officials said he and Mr. Trump had reached a détente. The president tweeted congratulations to his top aide on Monday for reaching the one-year mark, along with a photo of the two men, both wearing wide smiles.

The Wall Street Journal first reported Mr. Kelly’s comments, which were made at a staff meeting.

While Mr. Kelly seems safe for now, current and former officials note that nobody in the Trump administration — aside from the president and members of his immediate family — has long-term job security in a White House where fortunes rise and fall swiftly, largely at the pleasure of Mr. Trump.