A multiscale model for the analysis of the in-plane response of periodic masonry walls is presented. The overall constitutive behavior of the composite material is derived through a homogenization procedure based on the Transformation Field Analysis properly extended to the case of interfaces. At micro level, masonry is modeled as the assembly of expanded units and interfaces representing both mortar and unit-mortar interaction. A nonlinear constitutive law accounting for damage and friction phenomena is considered for joints, whereas a linear elastic constitutive relationship is assumed for the blocks. The proposed multiscale procedure is implemented into a Finite Element code, where the mesh-dependency occurring in presence of strain soft...