The 30-year-old, who played through the pain barrier for the last two months of the season, is expected to join pre-season training when the squad return ahead of their trip to Holland on July 3.
Swansea head physio, Kate Rees, said on the club's official website: "Everything went well and Leon is due to return to Swansea on Thursday."
Britton, who also had a hernia operation back in 2006, said: "My groin has felt quite tight, but I wanted to play through the pain and finish the season.
"I missed parts of training in that time, but it was necessary to ensure I was available for the games, although I did struggle a little bit in the last four to six weeks.
"I've had one hernia since December and a scan around four weeks or so ago showed I had another one.
"Next season will be huge for us as we will be involved in four competitions, so I want to make sure I'm fit and ready when we report back for pre-season."