Question: What if one broke the fast before sunset, believing that sunset had occurred?
Answer: The fast becomes invalid, and one must make it up. (Ad-Durr al-Mukhtār, Kitāb aṣ-Ṣawm, vol. 3, p. 431).