A magnetic lock (mag lock), consists of an electric magnet that can be installed along the top of a door frame and a metal plate is fastened to the door so it lines up with the magnet. When electrical power is supplied to the magnet, it creates a magnetic force that will keeps the door securely locked until power is interrupted.