England spinner Monty Panesar will leave Sussex at the end of the season and will immediately go out on loan to Essex for the remainder of the summer.
Panesar landed himself in hot water after a nightclub incident in Brighton recently.
The club investigated it and, after a discussion with Panesar, it has been agreed that he should leave for pastures new.
He will officially leave the club in the summer but will immediately go out on loan to Essex, who he could make his debut for against Northants on Tuesday.
Panesar could debut alongside Indian opener Gautam Gambhir as Essex kick off the Colchester Festival, with coach Paul Grayson saying: "We are delighted to welcome Monty to the club for the remainder of the season.
"He is a world-class spinner and we are confident that he will have a positive impact on the team. He will join us from today and will hopefully be playing on Tuesday at 11am against Northants."
Essex revealed Panesar would replace Tom Craddock in the squad, and he could miss the rest of the season for personal reasons.
The 31-year-old has released a statement and said: "I have endured a challenging time this year off the field and my frustrations have sometimes got the better of me professionally.
"I apologise for letting the club, my colleagues and my fans down.
"I am determined to do whatever it takes to gain selection for England this winter. I want to become the best I can be."
A Sussex statement read: "The club's investigation into the recent incident which took place on Monday 5th August has been concluded, and both parties have reached agreement. He will become a free agent as of Friday 27th September 2013.
"Additionally, Sussex has agreed to Monty's request that he be allowed to play on loan for a club in Division Two of the LV=County Championship until the end of this season."
Zac Toumazi, the county's chief executive, said: "Clearly this season has been a very difficult time for Monty Panesar.
"Having reviewed the whole situation the club has agreed that Monty be released from his contract. This will give him every opportunity to put his personal and professional life back on track."
Sussex's Cricket Manager Mark Robinson added: "Monty has been an integral part of the professional cricket team and has been a valuable contributor to the overall performance of the club during his time at Sussex. He is an outstanding bowler.
"I would like to thank Monty for his contribution and wish him well for the future."