Ans. The String class in Java is immutable, meaning that its value cannot be changed once it is created. StringBuilder and StringBuffer, on the other hand, are mutable classes that can be used to manipulate strings. The main difference between StringBuilder and StringBuffer is that StringBuilder is not thread-safe, while StringBuffer is. StringBuilder is generally preferred for single-threaded applications, while StringBuffer is used in multi-threaded environments.