Given a family of Galois coverings of the projective line, we give a simple sufficient condition ensuring that the closure of the image of the family via the period mapping is a special (or Shimura) subvariety of Ag. By a computer program we get the list of all families in genus g ≤ 9 satisfying our condition. There are no families with g = 8, 9, all of them are in genus g ≤ 7. These examples are related to a conjecture of Oort. Among them we get the cyclic examples constructed by various authors (Shimura, Mostow, De Jong-Noot, Rohde, Moonen and others) and the abelian non-cyclic examples found by Moonen-Oort. We get 7 new non-abelian examples.