The 23-year-old former Bath wing spent three-months at the Arms Park before his stint ended in early January.
He has since played for Northampton, but is relishing a return to Cardiff.
"I just want to get back into the team, keep building the momentum, helping the team collectively to get better and hopefully push on to Wales," he said.
"I was obviously disappointed to leave Bath [at the end of 2022-23] but the amount of learning experience I have gained to bring here, and the more time I spend with Cardiff, will really improve me as a player."
Hamer-Webb added: "I'm immensely pleased. My family are all from here so it's brilliant to get back to my roots."
Cardiff head coach Matt Sherratt said: "We were really impressed with Gabriel during his spell here earlier this season and we are pleased to secure his services for 2024-25.
"He is a superb athlete, a great professional and he offers us a bit of versatility in his ability to play wing and full-back."