Author Salman Rushdie has appeared in a New York court to give evidence against the man charged with stabbing him in a frenzied knife attack.

Hadi Matar, 27, is charged with attempted murder and assault for attacking Rushdie as he was preparing to give a speech in August 2022, stabbing him more than a dozen times.

Matar has pleaded not guilty.

Salman Rushdie poses for a portrait to promote his book ‘Knife: Meditations After an Attempted Murder’ in Berlin (Ebrahim Noroozi/AP)

The 77-year-old author was blinded in one eye in the attack and spent months recovering, a process he detailed in a memoir released last year.

A speaker who was to appear with Rushdie was also wounded.

Jurors in the western New York trial heard opening statements on Monday, followed by evidence from workers at the arts institution where the attack took place.

Matar has been in custody since he was subdued by spectators after the attack.

He has pleaded not guilty to attempted murder and assault.

The trial is projected to last up to two weeks.

Jurors are expected to be shown video and photos from the day of the attack.

They are unlikely, however, to hear about a fatwa issued by the late Iranian leader Ayatollah Ruhollah Khomeini calling for Rushdie’s death, according to district attorney Jason Schmidt.

In this courtroom sketch, lawyer Lynn Shaffer asks her client Hadi Matar, left, to stand while giving her opening statement in a court in New York (Elizabeth Williams via AP)

Rushdie, the author of “Midnight’s Children” and “Victory City”, spent years in hiding after Khomeini announced the fatwa in 1989 following publication of the novel “The Satanic Verses”, which some Muslims consider blasphemous.

Mr Schmidt has said discussing Matar’s motive will be unnecessary in the state trial, given the attack was seen by the live audience that was present to hear Rushdie speak.

“This is not a case of mistaken identity,” Mr Schmidt said during his opening statements on Monday.

“Mr Matar is the person who attacked Mr Rushdie without provocation.”

A public defender representing Matar, however, told jurors that the case is not as straightforward as prosecutors made it out to be.

“The elements of the crime are more than `something really bad happened’ — they’re more defined,” Lynn Schaffer said.

“Something bad did happen, something very bad did happen, but the district attorney has to prove much more than that.”

In a separate indictment, federal authorities allege that Matar was driven to act by a terrorist organisation’s 2006 endorsement of the fatwa.

A later trial on terrorism charges will be scheduled in a court in Buffalo.