The integration of ferroelectric oxide films into microelectronic devices(1,2), combined with the size reduction constraints imposed by the semiconductor industry, have revived interest in the old question concerning the possible existence of a critical thickness for ferroelectricity. Current experimental techniques have allowed the detection of ferroelectricity in perovskite films down to a thickness of 40 Angstrom (ten unit cells), ref. 3. Recent atomistic simulations(4,5) have confirmed the possibility of retaining the ferroelectric ground state at ultralow thicknesses, and suggest the absence of a critical size. Here we report first-principles calculations on a realistic ferroelectric-electrode interface. We show that, contrary to current thought, BaTiO(3) thin films between two metallic SrRuO(3) electrodes in short circuit lose their ferroelectric properties below a critical thickness of about six unit cells (similar to24 Angstrom). A depolarizing electrostatic field, caused by dipoles at the ferroelectric-metal interfaces, is the reason for the disappearance of the ferroelectric instability. Our results suggest the existence of a lower limit for the thickness of useful ferroelectric layers in electronic devices.