Ferroelectricity at a PbTiO 3 junction structure of a 180° domain wall and a (001) surface with [010]-directional spontaneous polarization parallel to the surface has been investigated by ab initio (first-principles) density functional theory calculations within the local density approximations. At the junction area of the domain wall and the surface, the [010]-directional polarization distortion is nearly the same as that of the 180° domain wall, which suggests that the domain wall has a dominant effect on the local polarization distortion in the junction area. However, a non-trivial in-plane polarization (normal to the [010]-direction) is found at the junction area, due to the effect of the surface. Antiferrodistortive (AFD) oxygen rotation is found at the junction area of the domain wall and the surface, indicating the coexistence of ferroelectric and AFD distortions. Moreover, an applied tensile strain along the polar axis increases the ferroelectricity and suppresses the AFD distortion at the junction area of the domain wall and the surface.