In the present study, the welding of coarse- (CG) and ultrafine-grained (UFG) Al-Mg-Si alloy using friction stir welding (FSW) was attempted. The purpose of welding the UFG material was to check the possibility of applying FSW to materials with a thermally unstable microstructure, which is achieved by severe plastic deformation. This group of materials has significant potential due to the enhanced mechanical properties as a result of the elevated number of structural defects. The CG sample was also examined in order to assess whether there is an influence of the base material microstructure on the weld microstructure and properties. To refine the microstructure, incremental equal channel angular pressing was used. Plastic deformation resulted in grain refinement from 23 µm to 1.5 µm. It caused an increase in the microhardness from 105 HV0.1 to 125 HV0.1 and the tensile strength from 320 MPa to 394 MPa. Similar welds obtained using an FSW method exhibited good quality and grain size in a stir zone of 5 µm. For both welds, a decrease in the microhardness occurred in the stir zone. However, for the weld of UFG Al-Mg-Si, the microhardness distribution was homogeneous, while for the weld of the CG, it was inhomogeneous, which was caused by different characteristics of the second-phase precipitates. The tensile strength of the welds was lowered and equaled 269 MPa and 220 MPa for the CG and UFG welds, respectively.