How a history of inﬂuenza virus infections contributes to protection is not fully understood, but such protection might explain the contrasting age distributions of cases of the two lineages of inﬂuenza B, B/Victoria and B/Yamagata. Fitting a statistical model to those distributions using surveillance data from New Zealand, we found they could be explained by historical changes in lineage frequencies combined with cross-protection between strains of the same lineage. We found additional protection against B/Yamagata in people for whom it was their ﬁrst inﬂuenza B infection, similar to the immune imprinting observed in inﬂuenza A. While the data were not informative about B/Victoria imprinting, B/Yamagata imprinting could explain the fewer B/Yamagata than B/Victoria cases in cohorts born in the 1990s and the bimodal age distribution of B/Yamagata cases. Longitudinal studies can test if these forms of protection inferred from historical data extend to more recent strains and other populations.