After waking up and often sending her first emails of the day around 4:30 a.m., Ms. Hicks would squeeze in a workout. Then, for much of the work day, she could usually be found in her closet-size office, where she would wait for the president’s inevitable call: “Hopester,” Mr. Trump would say, or “Hopey!” He sought her advice on any number of unfolding crises facing the White House, but also to check his instincts against hers.

She never cultivated a life outside the White House.

Several current and former aides praised Ms. Hick’s political instincts and understanding of Mr. Trump’s messaging. She often drafted his public statements, adopting his tendency to speak in simple declaratives peppered with Trumpian favorites — “incredible,” “unmatched.”

From time to time, she advised him on whether an angry Twitter post he wanted to send would be in his best political interests. From time to time, according to a former White House official, she would tell him that it was.