The white gunman who killed 10 black people at a Buffalo supermarket has pleaded not guilty to hate-motivated domestic terrorism and other charges, as a prosecutor called the evidence against him overwhelming.

A lawyer entered the plea for Payton Gendron, 18, in the first case to make use of New York's domestic terrorism hate crime law.

Gendron did not speak during the brief hearing with a heavy security presence.

Witnesses, police and Gendron's own writings and livestreamed video have incriminated him as the gunman who used an AR-style semi-automatic rifle on May 14 to target shoppers and employees of a Tops Friendly Market, and he surrendered at the crime scene after putting his rifle to his neck.

Authorities said he chose the store because of its location in a predominantly black neighbourhood.

"There is overwhelming proof of the defendant's guilt," assistant district attorney John Fereleto said. "The defendant was caught at the scene of the crime with the weapon in his hands."

Gendron has been held without bail since the shooting and is due back in court July 7.

He was charged with murder shortly after the attack. On Wednesday, a new indictment expanded the case to include the domestic terrorism charge, along with 10 counts of first-degree murder, 10 counts of second-degree murder as a hate crime, criminal possession of a weapon and three counts of attempted murder as a hate crime.

"When you hear the phase 'throw the book at' someone, well, in this case right here, the defendant just got War And Peace," district attorney John Flynn said at a news conference after the arraignment.

The domestic terrorism hate crime charge - officially, domestic acts of terrorism motivated by hate in the first degree - was added to state law two years ago after a mass shooting targeting Mexicans at a Walmart store in El Paso, Texas. The offence carries an automatic life sentence.

In Gendron's case, the charge accuses him of killing at least five people "because of the perceived race and/or colour" of his victims.

Outside court, Buffalo mayor Byron Brown called Gendron "a racist, hate-filled outsider who came to our community with the stated intent to kill as many black people as possible".

Prosecutors said Gendron drove about three hours to Buffalo from his home in Conklin, New York, to target African Americans. Shortly before opening fire, he posted documents that outlined his white supremacist views and revealed he had been planning the attack for months.

Federal authorities are investigating the possibility of hate crime charges against Gendron.

The victims ranged in age from 32 to 86. Three other people were wounded.

The bloodshed, followed 10 days later by a mass shooting that killed 19 children and two teachers inside a primary school in Uvalde, Texas, has renewed a national debate about gun control.