The invention relates to a UV filter based on polyhydroxybutyrate containing polyhydroxybutyrate particles in size ranging from 0.2 to 500 µm, which are functionalised by at least one organic UV filter of natural origin at a total concentration of 2 to 10%.The invention also relates to the method of preparation of this UV filter.