  This paper addresses the so-called inverse problem which consists in
searching for (possibly multiple) parent target Hamiltonian(s), given a single
quantum state as input. Starting from $\Psi_0$, an eigenstate of a given local
Hamiltonian $\mathcal{H}_0$, we ask whether or not there exists another parent
Hamiltonian $\mathcal{H}_\mathrm{P}$ for $\Psi_0$, with the same local form as
$\mathcal{H}_0$. Focusing on one-dimensional quantum disordered systems, we
extend the recent results obtained for Bose-glass ground states [M. Dupont and
N. Laflorencie, Phys. Rev. B 99, 020202(R) (2019)] to Anderson localization,
and the many-body localization (MBL) physics occurring at high energy. We
generically find that any localized eigenstate is a very good approximation for
an eigenstate of a distinct parent Hamiltonian, with an energy variance
$\sigma_\mathrm{P}^2(L)=\langle\mathcal{H}_\mathrm{P}^2\rangle_{\Psi_0}-\langle\mathcal{H}_\mathrm{P}\rangle_{\Psi_0}^2$
vanishing as a power law of system size $L$. This decay is microscopically
related to a chain-breaking mechanism, also signalled by bottlenecks of
vanishing entanglement entropy. A similar phenomenology is observed for both
Anderson and MBL. In contrast, delocalized ergodic many-body eigenstates
uniquely encode the Hamiltonian in the sense that $\sigma_\mathrm{P}^2(L)$
remains finite at the thermodynamic limit, i.e., $L\to+\infty$. As a direct
consequence, the ergodic-MBL transition can be very well captured from the
scaling of $\sigma_\mathrm{P}^2(L)$.
