Pompey have signed goalkeeper Craig MacGillivray on a two-year deal.
The 25-year-old will officially become a Blues player on July 1 when his contract with Shrewsbury expires.
Blues boss Kenny Jackett said: “He strengthens our goalkeeping department and will provide good competition for Luke McGee. They can drive each other on.
“Craig’s fiercely ambitious and excelled when he played last season, so we’re very pleased to bring him to the club.
"Craig’s fiercely ambitious and excelled when he played last season."
“He has been slightly unlucky in the past to be behind some top keepers, but he’s ready for the opportunity.
“His general game and shot-stopping are both good and he’s very brave, which is a quality that’s often underestimated.”
MacGillivray joined the Shrews in the summer of 2017 and made 14 appearances last season, keeping a clean sheet in their 1-0 victory at Fratton Park in January.
He was on the bench at Wembley as the Shropshire side suffered an extra-time defeat to Rotherham in the League One play-off final.
MacGillivray previously featured for Stalybridge, Harrogate Town and Harrogate Railway before being given a Football League chance by Walsall.