Gastric cancer (GC) is the fourth most common cancer globally. Recently, microRNAs (miRNAs) have been suggested to be closely associated with tumorigenesis. Aberrant expression of miR-509-3p has been reported in cancer studies. However, the expression and mechanism of its function in GC remain unclear. Here we showed that miR-509-3p was downregulated in GC specimens, which was associated with overall survival. Functional investigations demonstrated that the overexpression of miR-509-3p inhibited the migration and proliferation of the GC cells. Additionally, we identified X-linked inhibitor of apoptosis protein (XIAP) as a direct target of miR-509-3p. Knockdown of XIAP significantly attenuated the ability of proliferation, migration, and invasion of GC cells. The data therefore suggest that miR-509-3p plays an important role in the development and progression of GC, implicating possible applications in the clinic as a biomarker and a potential new target.