...
Magnetic lock doors often found in hotels.
...
How Magnetic Locks Work

Components

...
A safe has magnetic locks.

A magnetic lock, often referred to as a mag lock, consists of an electromagnet and an armature plate. The magnet is mounted inside of the door opening, which prevents tampering, while the plate is installed on the face of the door. When the magnet is connected to an electrical source, it produces a strong magnetic attraction that holds the magnet tight to the plate, effectively locking the door. The lock is typically powered using either the building's electrical system or a separate battery pack. Because a mag lock can only be used with DC power, a converter unit must be added when relying on building power. These locks are said to be "fail-safe," meaning that once the power goes out, the door will remain unlocked, allowing occupants to exit safely.

Electromagnetic Theory

...
Iron tubes.

Mag locks are based on the science of electromagnetism. Based on the principles of electromagnetism, when a current is run through a loop of wire, or solenoid, a magnetic force will be produced. This magnetic force is of sufficient strength to prevent the door from opening under a specified amount of pressure. To increase the strength of the magnetic force, multiple solenoids may be used, or they may be placed around a core made of iron. The magnetic effect of the solenoids not only produces its only force, but also amplifies the natural magnetism of the iron. Mag locks are rated based on the amount of force they are able to withstand without failing. For example, a 1,200 pound Mag Lock can withstand 1,200 pounds of force while still keeping the building secure.

Operations

...
Cylinder lock with key.

One of the biggest advantages to using a mag lock is that it can't be picked or tampered with like a traditional lock cylinder. No keys are used, as the lock is generally tied into an electrical security system. These systems rely on one of four basic methods to operate the lock. They are often connected to a buzzer, which must be manually released by someone inside the building before the door will open. A mag lock may also be used with a keypad system, where occupants enter a numerical code to activate the lock and open the door. In many commercial settings, card readers are used with these locks, making it easy to deactivate a card in the event an employee is terminated or loses his/her key card. Finally, in high-security situations, the mag lock may be activated by scanners that read fingerprints, retinas, or facial features of an occupant before they are permitted to enter.