Yes, alarms can deter a burglar from attempting a break in, however it is recommended that you display warning signs that the alarm is in use and you also use other security measures to work alongside the alarm because although it is a deterrent,  an alarm alone will not stop a burglar from breaking into your property.