A method, system and apparatus for controlling dispensing of medication isprovided.The system comprises: a device comprising: a sensor for detecting opening andclosing ofa dispenser; a memory storing a dispensing schedule; an alert device forproviding alerts;a short range wireless communication interface; and a processor configured to:controlthe alert device to provide alerts according to the schedule; and communicatesensor datausing the interface; and, a communication device comprising a processor, amemorystoring a dispensing application, a short range wireless communicationinterface; and along range communication interface, the processor configured to: receive thedispensingschedule using the application; and transmit the dispensing schedule to thedevice usingthe respective communication interface and the application, and transmit dataassociatedwith the application using the long range interface, the data comprising oneor more ofthe schedule and the sensor data.