Inhibition of gp41 protein was proposed as a possible mechanism for the anti-HIV-1 properties of some 4-aryl-1,2,3,4-tetrahydropyrimidine-2(1H)-one (thione) derivatives. Two different in silico approaches, namely quantitative structure activity relationship (QSAR) and molecular docking studies were performed to characterize the relation between the structural features and the anti-HIV-1 activity and investigating the mode of interaction of the compounds with gp41. In the QSAR approach, free least squares support vector machine was used to derive a non-linear model based on the most important descriptors responsible for the activity of the compounds selected by stepwise multiple linear regression method. Docking results proved that the studied molecules have the optimum key interactions including hydrogen bonding, hydrophobic, electrostatic, p-p and cation-p interactions with the specific inhibitor binding site of gp41.