I do that quite often when I run out of 'Tap safe'. 24 hrs would be enough, 48 hrs will be perfect. Remeber to take off the lid of the container you are going to use.
I heard that leave water under sunshine for more than 5 hrs could do the same work, but I have never tried as there is not much sunshine in English.