The Alabama Supreme Court said Monday that a panel of retired judges will hear suspended Chief Justice Roy Moore's bid to return to the bench.

The justices issued a 5-3 decision saying that they will recuse themselves from hearing Moore's appeal and describing how replacement judges will be picked.

"Because the Justices have personal knowledge of the facts and circumstances underlying this appeal, this appeal presents a situation in which all the justices' impartiality might be questioned," the majority wrote.

The court said Acting Chief Justice Lyn Stuart will work with the governor to randomly draw the names of 50 judges from a pool of retired appellate, circuit and district court judges. The first seven qualified and willing judges will serve as the special Supreme Court to hear Moore's appeal.

Associate Justice Tom Parker, an ally of Moore's who dissented in the Monday order, said elected judges should hear Moore's appeal because they are accountable to the public

A judicial panel last month suspended Moore for the remainder of his term after finding he urged state probate judges to defy the federal courts on gay marriage. The charges stemmed from a January order Moore sent, telling probate judges that a state order to refuse marriage licenses to gay couples remained in "full force and effect." Moore's writing came six months after the U.S. Supreme Court ruled gays and lesbians have a fundamental right to marry.

Moore disputed the charges, saying he was only giving judges a "status" update in the state case.

Moore's attorney objected to Stuart's involvement in the selection of replacement judges. Stuart earlier this month directed Moore to clear out his office at the Alabama Judicial Building in the wake of his suspension from the bench. Moore, as of last week, had not removed his personal items. His attorney said the directive was premature since Moore is appealing his suspension.

"He wants his case to be heard by an objective and fair panel of judges who will adhere to the rule of law," said Moore's attorney, Mat Staver.