A hierarchy on a set S, also called a total partition of S, is a collection H of subsets of S such that S∈H, each singleton subset of S belongs to H, and if A,B∈H then A∩B equals either A or B or ∅. Every exchangeable random hierarchy of positive integers has the same distribution as a random hierarchy H associated as follows with a random real tree T equipped with root element 0 and a random probability distribution p on the Borel subsets of T: given (T,p), let t1,t2,... be independent and identically distributed according to p, and let H comprise all singleton subsets of N, and every subset of the form {j:tj∈Fx} as x ranges over T, where Fx is the fringe subtree of T rooted at x. There is also the alternative characterization: every exchangeable random hierarchy of positive integers has the same distribution as a random hierarchy H derived as follows from a random hierarchy H on [0,1] and a family (Uj) of IID uniform [0,1] random variables independent of H: let H comprise all sets of the form {j:Uj∈B} as B ranges over the members of H.