Jurgen Klopp’s side have had to watch in recent years as the Spanish giants have signed their greatest stars, such as Luis Suarez and Philippe Coutinho.
Speaking to The Mirror, he said: “I just don’t see Salah following in the footsteps of Suarez and Coutinho.
“For South American players, signing for Barcelona or Real Madrid is a huge thing for them to do because of the links to their culture.
“I haven’t met Salah, but from what people have told me about him he seems to be someone who loves being loved like he is by the Kop.
“I think that he has found a home, somewhere he is respected and appreciated, and he’s also working with a manager who was brave enough to pay a lot of money for him when others looked at what had happened at Chelsea.”
Hamann also thinks that a move to La Liga would signal a change of status for the 25-year-old.
“Klopp has brought the best out of Salah and he is now No.1 at Liverpool,” he said.
“At Barcelona and Real Madrid, unless you are Lionel Messi or Cristiano Ronaldo, then you just another good player.
“I think the emotional side of football is very important to Salah. If he is happy – and he looks to be very comfortable at Liverpool – then he strikes me as a player who will be very loyal.
“I don’t think it is any coincidence that the shackles have come off playing for Jurgen Klopp at Liverpool.
“It just looks like a perfect fit. When you become a hero at Liverpool, the fans love you like you are a member of their family.
“I don’t think that should be underestimated if a club like Barca or Real tried to sign him.”
Salah is currently fighting to be fit for World Cup 2018, where he hopes to appear with his country, and the signs are positive that he is winning his battle to be ready.