The interactions between the H2 antagonists cimetidine, ranitidine and famotidine with a basic molecular model for the histamine H2 receptor have been analyzed. The calculated potential energies of the antagonist-H2 receptor complexes follow an order consistent with the published binding data, indicating that famotidine is the best H2 receptor ligand. Comparison with the interactions found for histamine and this H2 receptor model suggests that the protonated imidazole moiety of cimetidine, the dimethylammonio moiety of protonated ranitidine and the protonated guanidinyl moiety of famotidine are bioisosteric with the protonated aliphatic amine group of histamine. Asp 98 in helix 3 appears to be the main residue for antagonist recognition, but some residues in helix 5 may be involved, apparently by serving to guide the antagonist into the binding pocket.