A guilty plea can be withdrawn all the way up until the point during court where the judge “accepts” the guilty plea. After that point, there is no right to withdraw the plea. However, I have seen cases where the judge will voluntarily allow the plea to be withdrawn after this point, although there is no guarantee that he or she would. Usually, this only happens when some unforeseen circumstance unfolds after the plea has been accepted.