A defibrillator is a medical device used to treat cardiac emergencies, specifically cardiac arrest caused by ventricular fibrillation (VF) or pulseless ventricular tachycardia (VT). It delivers an electric shock to the heart to restore a normal heartbeat.