Cyber security expert Dr Daniel Thomas, of the University of Strathclyde, said the community council websites would be attractive as links to their URLs appeared on the Scottish Borders Council website.
"When someone is looking for the community council and are met with this gambling portal they will think something is wrong and of course not engage with the site," he said.
"But when someone is searching for these sites, the now re-directed community council site will be at the top of list, as it appears a local group is giving out suggestions on the best offshore gambling sites to use."