  We work out the junction conditions for $f(R)$ gravity formulated in
metric-affine (Palatini) spaces using a tensor distributional approach. These
conditions are needed for building consistent models of gravitating bodies with
an interior and exterior regions matched at some hypersurface. Some of these
conditions depart from the standard Darmois-Israel ones of General Relativity
and from their metric $f(R)$ counterparts. In particular, we find that the
trace of the stress-energy momentum tensor in the bulk must be continuous
across the matching hypersurface, though its normal derivative need not to. We
illustrate the relevance of these conditions by considering the properties of
stellar surfaces in polytropic models, showing that the range of equations of
state with potentially pathological effects is shifted beyond the domain of
physical interest. This confirms, in particular, that neutron stars and white
dwarfs can be safely modelled within the Palatini $f(R)$ framework.
