A doorbell is a device that is typically installed near or on an entrance door to a building, such as a house or office. It serves two main purposes - firstly, it allows people outside to announce their presence by ringing the bell, which can be heard inside the building; and secondly, it provides a means for those inside to communicate with visitors through speech or sound (e.g., via an intercom system). The doorbell is often used as a security measure, allowing occupants of a building to determine who is at their front door before deciding whether to open it or not.