A repeat offender has avoided a prison sentence on the condition that he leaves Mandurah and relocates to Broome after an aggravated burglary at BWS Halls Head in June.

Dillon Jessy Lee Grosser appeared in Mandurah Magistrates Court via video link from Hakea Prison on Tuesday.

The 24-year-old pleaded guilty to one count of aggravated burglary, as well as a number of other offences, and had been in custody since September 20.

Police prosecutor Mick Fallows told the court Grosser was with three other males at the unattended shop about 11pm on Wednesday, June 6 when he threw a block of concrete at the window and stole more than $200 worth of alcohol.

The offence was captured on CCTV footage.