Police located several guns, a stockpile of ammunition and a shopping list for bomb materials in the home of a Western Australian man arrested after pledging support for the Bondi attackers, a court has heard.

Martin Glynn, 39, appeared in a Perth court on Wednesday charged with racial harassment, possessing a prohibited weapon and failing to store firearms correctly.

Prosecutors allege flags of Hamas and Hezbollah, both declared terrorist groups by Australia, were located during a police raid sparked by a tip-off from the public.

In a statement, Prime Minister Anthony Albanese said “there is no place in Australia for antisemitism, hate and violent ideologies”.

The court heard that Mr Glynn posted on Instagram just hours after two gunmen killed 15 people in a targeted attack on a Hanukkah event at Sydney’s Bondi Beach on 14 December to endorse their actions.

“A community member saw a post from the man online, recognised it wasn’t right, and reported it to police,” acting Western Australia premier Rita Saffioti told reporters on Christmas Eve.

Police subsequently searched Mr Glynn’s home in Yangebup, a suburb of Perth, allegedly finding a notebook including antisemitic comments and references to Nazi ideology.

Three flags, six rifles and around 4,000 rounds of ammunition were also seized, prosecutors say.

There is “nothing illegal or improper” with supporting the Palestinian cause, Magistrate Benjamin Tyers told the court on Wednesday.

“What is not proper is posting online comments supporting a massacre of innocent civilians,” he said, according to The Sydney Morning Herald.

In court, Mr Glynn, who represented himself, said he had been “opinionated” about the war in Gaza, but was “hoping to raise the hypocrisy” by creating the Instagram post.

He said he was a doomsday prepper, and that the alleged “bomb-making material” was actually fire-starting material.

“I don’t intended to harm anyone,” he said.

Western Australia Police Commissioner Col Blanch told media it is early days in their investigation, but there was no previous “record of concern for this individual”.

Mr Glynn, a former mine worker, was denied bail and will face court again on 3 February.