Very good! Is there another similar function that does similar things when variables (rather than just numbers) are involved?
For example, there is the function
denestSqrt[e_, domain_, x_] := Replace[y /. Solve[Simplify[Reduce[Reduce[y == e && domain, x], y,
Reals], domain], y], {{r_} :> r, _ -> e}]
written by @CarlWoll (denestSqrt).
Here is an example:
denestSqrt[Sqrt[(1 - 2 x) (1 - x - 2 x^2) (2 - x + 2 Sqrt[1 - x - 2 x^2])], 1/3 < x <= 1/8 (2 + Sqrt[2]), x]
(* 1 - x - 2 x^2 + Sqrt[-(1 + x) (-1 + 2 x)^3] *)