Profinite algebras are the residually finite compact algebras, whose underlying topological spaces are Stone spaces. We introduce Stone pseudovarieties, that is, classes of Stone topological algebras of a fixed signature that are closed under taking Stone quotients, closed subalgebras and finite direct products. Looking at Stone spaces as the dual spaces of Boolean algebras, we find a simple characterization of when the dual space admits a natural structure of topological algebra. This provides a new approach to duality theory which, in the case of a Stone signature, culminates in the proof that a Stone quotient of a Stone topological algebra that is residually in a given Stone pseudovariety is also residually in it, thereby extending the corresponding result of M. Gehrke for the Stone pseudovariety of all finite algebras over discrete signatures. The residual closure of a Stone pseudovariety is thus a Stone pseudovariety, and these are precisely the Stone analogues of varieties. A Birkhoff type theorem for residually closed Stone varieties is also established.