Abstract: A lock with sensor comprises a housing defining a chamber and a latch mechanism located within the chamber of the housing. The latch mechanism is movable relative to the housing between a retracted position wherein the latch mechanism is substantially within the housing and an extended position wherein the latch mechanism extends at least partially outside of the housing. A sensor mechanism is provided and has a fixed switch portion located within the chamber and a movable switch activator portion, the switch activator portion being mounted so as to move with the latch mechanism and thereby activate and deactivate the switch portion respectively.