Nanomechanical biosensors have emerged as a promising technology for measurement of biomolecular interactions. Among the advantages are direct detection without need of labelling with fluorescent or radioactive molecules, small sensor area, high sensitivity and suitability for integration using silicon technology. Here we present two important applications: i) study of DNA immobilization for nucleic acid detection and ii) direct detection of the harmful pesticide dichlorodiphenyltrichloroethane (DDT). Single-stranded oligonucleotides were derivatized with thiol molecules for self-assembly on the gold-coated side of a microcantilever. The geometry of the binding and the surface density were studied and controlled by mixing derivatized oligonucleotides with spacer self-assembled monolayers. The hybridization signals were smaller than 10% of the immobilization signal. The molecular mechanisms responsible of the nanomechanical response due to hybridization are discussed. On the other hand, herbicide DDT was detected by performing competitive assays, in which the cantilever was coated with a synthetic DDT hapten, and it was exposed to different ratios between the monoclonal antibody and the DDT. The relevance of this technique in functional genomics and environmental control will be discussed.