Difference between the potential form and 〜ことができる
Both mean “can” or “be able to.” The meaning is almost the same, and the difference is length and style.
The potential form (話せる, 食べられる) is short and used a lot in conversation. 〜ことができる is longer, sounds formal, and is common in writing, notices and instructions.