Ashcroft announced his resignation on Tuesday, along with Commerce Secretary Don Evans, a Texas friend of the president's.
Gonzales, the 49-year-old Texas confidant and one of the most prominent Hispanics in the administration, has long been rumoured as a leading candidate for a Supreme Court vacancy if one develops.
Gonzales' career has been linked with Bush for at least a decade, serving as general counsel when Bush was governor of Texas, and then as secretary of state and as a justice on the Texas Supreme Court.
Central to Bush policy
Gonzales has been at the centre of developing Bush's positions on balancing civil liberties with waging the so-called war on terrorism. But he opened the White House counsel to the same line of criticism that has dogged Ashcroft.
Former attorney-general John
Ashcroft resigned on Tuesday
For instance, Gonzales publicly defended the administration's policy, essentially repudiated by the Supreme Court and now being fought out in the lower courts, of detaining certain terrorism suspects for extended periods without access to lawyers or courts.
He also wrote a controversial February 2002 memo in which Bush claimed the right to waive anti-torture law and international treaties providing protections to prisoners of war. That position drew fire from human-rights groups, which said it helped lead to the type of abuses uncovered in the Abu Ghraib prison scandal.
Also staining his reputation is the fact that he once was a partner in a Houston law firm which represented the scandal-ridden energy giant Enron.
First Hispanic AG
But Gonzales would be the first Hispanic attorney-general and would replace the gospel-singing son of a minister, John Ashcroft.
Ashcroft is a fierce conservative who doesn't drink, smoke or dance. His critics said he gave religion too prominent a role at the Justice Department - including optional prayer meetings with staff before each work day.
"I believe that the Department of Justice would be well served by new leadership and fresh inspiration"
Former US Attorney-General
Ashcroft championed many of the most controversial government actions following the 11 September attacks, most notably the USA Patriot Act. It bolstered FBI surveillance powers, increased use of material witness warrants to hold suspects incommunicado for months and allowed secret proceedings in terrorist-related immigration cases.
"I believe that the Department of Justice would be well served by new leadership and fresh inspiration," said Ashcroft, whose health problems earlier this year resulted in removal of his gall bladder.
Senator John Kerry, issued a statement Wednesday, calling Ashcroft "one of the most divisive faces in this administration".
"With the end of the era of John Ashcroft, the president now has an opportunity to heal those divisions and make good on his promise of renewed bipartisan cooperation," the former Democratic presidential candidate said.