ImportanceThe optimum level and timing of poststroke physical activity interventions to enhance functional recovery remain unclear.ObjectiveTo assess the level of physical activity in the first 6 months after stroke among individuals with similar physical activity patterns over time and to investigate the association between physical activity trajectories and functional recovery at 6 months after stroke.Design, Setting, and ParticipantsThis cohort study obtained data from the Efficacy of Fluoxetine–a Randomized Controlled Trial in Stroke, which was conducted in 35 stroke and rehabilitation centers across Sweden from October 2014 to June 2019. Adult participants (aged >18 years) were recruited between 2 and 15 days after stroke onset and followed up for 6 months. Participants who withdrew or were lost to follow-up were excluded from the longitudinal analysis. Data analyses were performed between August 15 and October 28, 2022.ExposuresPhysical activity was assessed at 1 week, 1 month, 3 months, and 6 months. Multiple factors associated with physical activity trajectories were investigated. Association of the distinct trajectories with functional recovery was assessed in multivariable logistic regression.Main Outcomes and MeasuresThe primary outcomes were the distinct physical activity trajectories over time, which were identified using group-based trajectory modeling. The secondary outcome was the functional recovery at 6 months after stroke, which was assessed using the modified Rankin Scale.ResultsOf the 1367 included participants (median [IQR] age, 72 years [65-79] years; 844 males [62%]), 2 distinct trajectory groups were identified: increaser (n = 720 [53%]) and decreaser (647 [47%]). The increaser group demonstrated a significant increase in physical activity level (mean difference, 0.27; linear slope β1 = 0.46; P < .001) and sustained it at light intensity from 1 week to 6 months, whereas the decreaser group showed a decline in physical activity and eventually became inactive (mean difference, −0.26; linear slope β1 = 1.81; P < .001). Male participants and those with normal cognition had higher odds of being in the increaser group, regardless of stroke severity. Increasing physical activity and sustaining it at light intensity were associated with a good functional outcome at 6 months (adjusted odds ratio, 2.54; 99% CI, 1.72-3.75; P < .001).Conclusions ad RelevanceResults of this study suggest that increased physical activity was associated with functional recovery 6 months after stroke. Interventions targeting individuals with decreasing physical activity in the subacute phase of stroke may play a role in improved functional outcomes.