This is a common question and there is no fixed answer.
In general, the filter should be replaced more frequent if it is used for virus or during a flu pandemic.
For anti-pollution purpose, the color of the filter give an indication of the remaining effectiveness. Therefore one can decide when to replace the filter based on the color of the filter.
Test on used filters from users from India, Vietnam, USA and Singapore shows that it is possible to use the color of the filters to determine, apporximately, the remaining effectiveness of the filters. These used filter samples coming from different countries, and different shades of grey is observed. It also show the relative level of air pollution, for example, 7 hours of use turns the filter almost black and the remaining effectiveness left only with 50%. On the other hands, 17 hours of use in California turns the filter to the second level of grey and still have 70% of effectiveness remain.
Depends on individual needs one can change the filter according to the remaining effectiveness. In any case, the filter should not be used for more than 14 days after removing the pack.