Spring REST Service: how to configure to remove null objects in json response January 20, 2023 by Tarik Since Jackson 2.0 you can use JsonInclude @JsonInclude(Include.NON_NULL) public class Shop { //... }