One embodiment of the invention provides a cardiac assist device that is in direct blood contact with blood in the heart. It is linked to the heart by surgically coring a hole into the wall tissue of a pumping chamber of the heart, typically the left ventricle. The device includes a contractile element that is linked to the hole in the heart's pumping chamber. The contractile element comprises either an electroactive polymer or (ii) one or more pneumatic or hydraulic bladders. In the contracted state, the contractile element displaces fluid from the pumping chamber of the heart to assist with pumping of the heart and increase the ejection fraction of the pumping chamber.