Pigs are confronted with changes in farming practices that may affect performance and animal well-being. The sanitary conditions of the farm can have an impact on the ability of pigs to adapt to these changes. This study aimed to analyse how weaned pigs respond to common farming practices of changes in diet and housing in terms of performance, health and behaviour, and how these responses are affected by the sanitary housing conditions, qualified here as good or poor. At weaning at 4 weeks of age, 20 piglets were assigned to 10 blocks of two littermates and each pig within a litter was randomly assigned to one of two sanitary conditions. Pigs were housed individually and received a starter diet. A diet change occurred on day 12 post weaning (starter to weaner diets) and pigs were transferred to the grower unit on day 33 post weaning and continued to receive the weaner diet. From 43 days post weaning, pigs were offered a grower diet and were vaccinated against swine influenza on day 47 and 61 post weaning. On the basis of this design, three post-weaning phases were identified: phase I from day 1 to 11 (post weaning), phase II from day 12 to 32 (after the diet change) and phase III from day 33 to 42 (after the housing change). Individual BW was measured every 3 days, and feed refusals and faecal scores were recorded on a daily basis. Behavioural observations were performed during 28 days by using the instantaneous scan sampling method. Individual blood samples were collected at the end of each phase to analyse the plasma concentration of haptoglobin and on day 68 post weaning to analyse the anti-influenza immunoglobulins G (IgG). Poor sanitary conditions resulted in a decrease in daily gain, feed intake and gain to feed ratio of, respectively, 11%, 5% and 7% (P < 0.05). Pigs in poor sanitary conditions had higher faecal scores (P < 0.05), tended to have higher plasma haptoglobin concentration in phase II (P = 0.06) and had a higher anti-influenza IgG titre (P = 0.11). The diet change affected performance and behavioural responses of pigs in poor but not in good sanitary conditions. Housing change resulted in a 30% decrease in growth and an increase in behaviour oriented towards exploration and excitement. The results of this study show an effect of sanitary conditions on the responses of pigs to a diet change, whereas those to a housing change were little affected by the sanitary conditions.