With continuing improvements in X-ray optics, conventional techniques for measuring their performance are finding it hard to keep up. Iterative phase-retrieval algorithms for reconstructing an optical field at the focus of an optical element could not only solve this problem, but remove the need for such optics altogether.