Stating simply, a Beacon is a small wireless device, which transmits continuous radio/Bluetooth Low Energy signals. Depending on the protocol being used, these signals package contextual information, which can then be intercepted by nearby Bluetooth Low Energy devices (which in most cases are smart phones), and then depending on the context and use case, the intercepted information is either presented to the user or sent to a backend for further processing or both.
Apart from the hardware itself, a protocol plays an important role and is one of the fundamental building blocks of any Beacon-related application use case. In very simple words, for the purpose of wireless communication, a protocol is a set of rules defining data transmission in a wireless channel.