We analyze the magnitude-redshift data of type Ia supernovae included in the Union and Union2 compilations in the framework of an anisotropic Bianchi type I cosmological model and in the presence of a dark energy fluid with anisotropic equation of state. We find that the amount of deviation from isotropy of the equation of state of dark energy, the skewness delta, and the present level of anisotropy of the large-scale geometry of the Universe, the actual shear Sigma_0, are constrained in the ranges -0.16 < delta < 0.12 and -0.012 < Sigma_0 < 0.012 (1sigma C.L.) by Union2 data. Supernova data are then compatible with a standard isotropic universe (delta = Sigma_0 = 0), but a large level of anisotropy, both in the geometry of the Universe and in the equation of state of dark energy, is allowed.