Trump made the announcement via Twitter Wednesday afternoon, less than a day after the U.S. midterm elections.
Trump said on Twitter that Matthew Whitaker, who is the current chief of staff to the attorney general, will take over the position temporarily.
“We thank Attorney General Jeff Sessions for his service, and wish him well!” the president added. “A permanent replacement will be nominated at a later date.”
WATCH: Former U.S. attorney general Jeff Sessions greeted by applause as he leaves Justice Department
Asked specifically about the future of Sessions just hours earlier, Trump avoided the question, “I’d rather answer that at a little bit different time.”
It had long been speculated that Sessions would be replaced following the midterm elections.
Sessions’ resignation letter clearly states the departure was demanded by the president. In it, the outgoing attorney general boasts his accomplishments during his time in the position.
WATCH: Kellyanne Conway comments on Sessions resignation, praises acting attorney general Whitaker
“Most importantly, in my time as Attorney General we have restored and upheld the rule of law—a glorious tradition that each of us has a responsibility to safeguard,” Sessions writes.
The resignation was the culmination of a toxic relationship that frayed just weeks into the attorney general’s tumultuous tenure, when he stepped aside from the investigation into potential coordination between the president’s Republican campaign and Russia.
Trump blamed the decision for opening the door to the appointment of special counsel Robert Mueller, who took over the Russia investigation and began examining whether Trump’s hectoring of Sessions was part of a broader effort to obstruct justice and stymie the probe.
The full implications Sessions’ exit may have on Mueller’s investigation were not immediately clear.
WATCH: Schumer says protecting Mueller investigation top priority after Sessions’ departure
However, a spokeswoman for the Department of Justice said Wednesday that Whitaker will oversee all matters, including the Russia probe.
“The Acting Attorney General is in charge of all matters under the purview of the Department of Justice,” spokeswoman Sarah Isgur Flores said when asked if Whitaker would oversee Mueller’s investigation of Russian actions during the 2016 presidential campaign.
WATCH: Schumer says timing of Sessions’ departure is “very suspect”
Whitaker has spoken out in criticism of the probe in the past.
In an opinion piece for CNN published in August 2017, he wrote: “Mueller has come up to a red line in the Russia 2016 election-meddling investigation that he is dangerously close to crossing.”
He called for the Mueller investigation’s scope to be narrowed.
Because of his criticisms of the probe, Democratic Sen. Chuck Schumer tweeted Wednesday that like Sessions, Whitaker should also recuse himself.
“Given his previous comments advocating defunding and imposing limitations on the Mueller investigation, Mr. Whitaker should recuse himself from its oversight for the duration of his time as acting attorney general,” the Senate minority leader wrote.
WATCH: Trump avoids question on Sessions’ job security
The senator also tweeted that the president’s forceful resignation of Sessions means he “has something to hide.”
— With files from The Associated Press, Reuters