He also paid the Blues the ultimate compliment by describing the club as ‘fantastic’ as he embarked upon the latest chapter of his 12-year career.
The midfielder completed the paperwork on his switch to the League Two side on Friday – an agreement that will see him link up once more with his former Millwall boss, Neil Harris, at Priestfield.
The move comes less than three weeks after his release from Fratton Park was confirmed last month.
'I don't think I realised how much it would mean': ex-Cardiff City and Bristol City man's Portsmouth admission as he chases winning Fratton feeling after homecoming
Former Portsmouth, Sunderland and Millwall ace Aiden O'Brien suffers setback as frustrating start to life at Shrewsbury continues
Danny Cowley makes Portsmouth team selection admission following Cheltenham win - and gives honest assessment of current squad amid early-season promotion hopes
The role ex-Leicester City, Birmingham City and Charlton Athletic man wants to maintain at Portsmouth after guiding city's young gems at Reading
Colby Bishop gives Spurs loanee and England youngster Dane Scarlett raving reviews after making Portsmouth league debut
Williams’ time at Pompey was brief, with the experienced campaigner’s stay lasting just the one season.
In that time he played 35 times, which represents an impressive total seeing as he missed two-and-a-half months of the campaign after fracturing his back against Charlton in January.
Five of those appearances came after recovering from his back injury, although the former Republic of Ireland was an unused substitute in the Blues’ last three games of the 2021-22 season.
That denied him the chance to say goodbye to the Fratton faithful, with his last game in blue coming at Morecambe in April.
Yet Williams took to Twitter to bid farewell.
And in doing so, he thanked the club, manager Danny Cowley and the fans for making his short stint on the south coast a memorable one.
Williams wrote: ‘Thank you @Pompey for welcoming me with open arms, also a big thanks to @dancowley1 and all the staff for giving me the opportunity to play for such a fantastic club and to the fans for all their support throughout the season!
‘Wishing you all the best for the season ahead #PUP’.
In return, Pompey fans have wished Williams luck at Gillingham and thanked him for
@GavinJones_14 wrote: ‘Nothing but absolute respect for you Shaun, breaking your back in two places and still making it back before the end of the season. Absolute warrior behaviour, all the very best to you mate’.
@PropPersonnel responded by saying: ‘Class tweet - best of luck in the future Shaun’.
@Jamesr02_ added: ‘Shame it didn’t work out as we hoped at Pompey, all the best at Gillingham’.
Meanwhile, @paul9lewis1 said: ‘All the very best Shaun, go well and enjoy your next challenge with the Gills’.
Blues fans won’t have long to wait for a Williams reuniuon.
Pompey take on Harris’ side in a pre-season friendly at Priestfield on Saturday, July 16.