SharedPreferences preferences = getSharedPreferences("Mypref", 0); preferences.edit().remove("text").commit();