This study aimed to investigate the trajectory and predictors of family function in caregivers of stroke survivors during the first 6 months after the first episode of stroke. Longitudinal study. A total of 288 primary caregivers of patients with first-time stroke were recruited from seven tertiary hospitals in China between July 2020 and March 2021. The following characteristics were assessed by caregivers at hospitalization (T0) and at 1 month (T1), 3 months (T2) and 6 months (T3) after the stroke: family function, general self-efficacy, social support, coping style, caregiver burden, and sociodemographic and clinical data. Family function scores among caregivers of stroke survivors were highest in the resolve dimension and lowest in the growth and adaptation dimensions within the first 6 months. The percentages of families with low functioning were 34.7%, 33.3%, 24.8% and 17.7% at T0, T1, T2 and T3, respectively. The generalized estimating equation model revealed that family function in caregivers increased over the first 6 months (Exp(B) = 1.415-2.689, p < .05). The following factors were identified as predictors of family functioning: caregiver's age, education, residential district, self-efficacy, social support utilization and caregiver burden. Family function of caregivers of stroke survivors gradually increased during the first 6 months after stroke. However, some families demonstrated poor functioning. Caregivers' age, education, caregiver burden, self-efficacy and social support utilization could predict family function over time. Empirical data on family function in families of stroke survivors are important for developing psychosocial interventions that can help families adapt to stroke. This study found that families of stroke survivors were likely to be dysfunctional in the first 6 months after stroke, particularly in family growth and adaptation. Therefore, reducing caregiver burden and promoting self-efficacy and social support utilization can help restore family functioning early after stroke. Stroke caregivers from seven hospitals in China were involved in this study and had the right to be informed of the main findings. A few patients were informed of the research results, who contributed to the dissemination.