Former England wicketkeeper James Foster is to leave Essex at the end of his contract and move into coaching.

The 38-year-old came through the Essex youth ranks and went on to captain the County Championship side, as well as making seven Test appearances for England, with 11 one-day international caps.

“It has been a real privilege to play for my home county and I am extremely proud to have represented England,” Foster said in an open letter.

“Whilst playing has now come to an end, I am incredibly excited about the next phase of my career.”

Foster has started to move into coaching roles, both with children at Forest School in East London as well as with Twenty20 sides the Sydney Thunder, the Khulna Titans and the Afghanistan Boost Defenders.

“Thank you to all the Essex players for making it such an enjoyable changing room and winning the County Championship in 2017 was one of my happiest memories,” continued Foster, whose England Test debut came against India in Mohali during December 2001.

“What I appreciated most at the club was the way coaches, management, support staff, stewards and supporters have always made my family feel so welcome at the club, for that, I am truly grateful.”

Foster, who made his County Championship debut against Glamorgan in August 2000, scored 18,321 runs, including 23 centuries, across all formats in a total of 638 games.

The wicket-keeper also took 839 first-class dismissals, second only to Brian Taylor in the Essex record books. Foster’s batting average was 36.69, with a highest score of 212 against Leicestershire in 2004.

James Foster (left). (PA)James Foster (left) praised the family atmosphere at Essex after confirming his retirement. (Chris Radburn/PA)

Essex Captain Ryan ten Doeschate said: “Fozzy has been the rock at Essex for all of the time I’ve played here, the most thorough professional and a cherished friend through thick and thin.

“Over the last 15 years he has been a big presence and a great example in the dressing room, we are going to miss him next season.”