A 2021 study found that N95 masks were more effective against COVID-19 than KN95 masks, if their fit was correct.
Having a correct fit is crucial. The CDC recommends checking for any gaps that allow air flow around the sides of the mask. People with beards may find it more difficult to get a correct fit, so they may prefer to shave or trim their beard, wear two masks, or wear a mask brace to improve the fit.