Let \(\mathcal {B(\mathcal {H})}\) and \(\sigma (A)\) denote the algebra of all bounded linear operators acting on an infinite-dimensional complex Hilbert space \({\mathcal {H}}\) and the spectrum of any operator \(A\in \mathcal {B(\mathcal {H})}\) , respectively. In this paper, we show that a surjective map \(\Phi :\mathcal {B(\mathcal {H})}\rightarrow \mathcal {B(\mathcal {H})}\) satisfies \(\begin{aligned}\sigma \left( \Phi (A)^{*}\Phi (B)+\Phi (B)^{*}\Phi (A)\right) =\sigma \left( A^{*}B+B^{*}A\right) \qquad (A,B\in \mathcal {B(\mathcal {H})}),\end{aligned}\) if and only if there exist a unitary or anti-unitary operator \(U\in \mathcal {B(\mathcal {H})}\) and a unitary operator \(V \in \mathcal {B(\mathcal {H})}\) such that \(\begin{aligned}\Phi (A)= UAV\qquad (A\in \mathcal {B(\mathcal {H})}).\end{aligned}\)