Kelly cited the White House's lack of transparency in its decision, as well as the "irreparable harm" to Acosta.
Acosta attempted to ask another question, but Trump wouldn't answer. A lawsuit that CNN brought against the Trump administration over the issue is continuing. The network received the support of multiple other news organizations, including Fox News, in the form of amicus briefs filed with the court.
The White House had spelled out its reasons in a tweet from Mrs Sanders and in a statement after CNN filed its lawsuit.
Julian Assange charged in US
It was submitted to the federal court in the eastern district of Virginia, which handles many cases involving national security. Dwyer urged a federal judge to "keep confidential the fact that Assange has been charged", according to The Washington Post .
He left open the possibility, however, that the White House could seek to revoke it again if it provided that due process, emphasizing the "very limited" nature of his ruling and saying he was not making a judgment on the First Amendment claims that CNN and Acosta have made. "This doesn't end the legal battle over Acosta's access to the White House, it simply means that it is restored for now".
Outside the courtroom, Acosta spoke to reporters and thanked other journalists for their support in the case.
Boutrous argued that the Trump administration's views on the First Amendment are "warped", and that there's no First Amendment doctrine that says, "Because there are lots of other reporters you can ban one".
The news network was seeking an immediate restraining order that would force the White House to hand back Acosta's credentials, which grant reporters access into the 18-acre complex.
In response, CNN attorney Ted Boutrous said the government had a "warped view" of the First and Fifth amendments.
Indeed, Acosta often writes and broadcasts directly from the White House, working out of a booth in the press area known as the "lower press room" or from the "upper press office", in close proximity to the Oval Office and the offices of the Press Secretary.