The deal will be subject to FA and EFL approval, with the contract officially commencing on July 1st.
Josh joined the National League play-off semi-finalists this time last year, signing on a free from Maidstone United.
He made his debut for the Spireites on the opening day of the season against Solihull Moors and was a mainstay for the remainder of the campaign, racking up 45 appearances in all competitions.
His performances also earn himself a place in the National League 2018/19 Team of the Season.
Born in Canterbury, the 24-year old joined the academy of his most local Football League side Gillingham, where he rose through the ranks and signed his first professional contract in 2012.
In the 2014/15 season he returned on loan to Eastbourne Borough, where he had been two years prior, but also made three first team appearances for the Gills; two in League One and one in the League Cup.
Josh eventually moved permanently to Eastbourne in 2016, playing a season before moving on to Maidstone, where he enjoyed a second season of frequent football, prior to his move up to Eastleigh in the fifth tier and now to Rovers in the third.
Manager Graham Coughlan said, “Josh has made real progress over the last three years in his development and climbing up the football pyramid.
“He had a great season with Eastleigh, reaching the play-off semi-finals and being named in the National League Team of the Year.
“We are confident he is ready to take the step into the Football League and we are sure he will add healthy competition to the squad.”