Absolutely! A website’s loading speed is one of the most important factors taken into account by search engines. Having smaller in size, optimized images means your site will load faster and use less bandwidth. And search engines (a.k.a. Google) love that. 🙂
You can read more about it here.
Images often account for most of the downloaded bytes on a web page and also often occupy a significant amount of visual space. As a result, optimizing images can often yield some of the largest byte savings and performance improvements for your website: the fewer bytes the browser has to download, the less competition there is for the client’s bandwidth and the faster the browser can download and render useful content on the screen.