  The interaction between the magnetic fields of late-type stars and their
close-by planets may produce stellar flares as observed in active binary
systems. However, in spite of several claims, conclusive evidence is still
lacking. We estimate the magnetic energy available in the interaction using
analytical models to provide an upper bound to the expected flare energy. We
investigate three different mechanisms leading to magnetic energy release. The
first two can release an energy up to $(0.2-1.2) B^{2}_{0} R^{3}/\mu$, where
$B_{0}$ is the surface field of the star, $R$ its radius, and $\mu$ the
magnetic permeability of the plasma. They operate in young active stars whose
coronae have closed magnetic field lines up to the distance of their close-by
planets that can trigger the energy release. The third mechanism operates in
weakly or moderately active stars having a coronal field with predominantly
open field lines at the distance of their planets. The released energy is of
the order of $(0.002-0.1) B^{2}_{0} R^{3}/\mu$ and depends on the ratio of the
planetary to the stellar fields, thus allowing an indirect measurement of the
former when the latter is known. We compute the released energy for different
separations of the planet and different stellar parameters finding the
conditions for the operation of the proposed mechanisms. An application to
eight selected systems is presented. The computed energies and dissipation
timescales are in agreement with flare observations in the eccentric system HD
17156 and in the circular systems HD 189733 and HD 179949. This kind of
star-planet interaction can be unambiguously identified by the higher flaring
frequency expected close to periastron in eccentric systems.
