We have developed a nanoscopic force sensor with optical readout. The sensor consists of a single-stranded DNA oligomer flanked by two dyes. The DNA acts as a nonlinear spring: when the spring is stretched, the distance between the two dyes increases, resulting in reduced Förster resonance energy transfer. The sensor was calibrated between 0 and 20 pN using a combined magnetic tweezers/single-molecule fluorescence microscope. We show that it is possible to tune the sensor's force response by varying the interdye spacing and that the FRET efficiency of the sensors decreases with increasing force. We demonstrate the usefulness of these sensors by using them to measure the forces internal to a single polymer molecule, a small DNA loop. Partial conversion of the single-stranded DNA loop to a double-stranded form results in the accumulation of strain: a force of approximately 6 pN was measured in the loop upon hybridization. The sensors should allow measurement of forces internal to various materials, including programmable DNA self-assemblies, polymer meshes, and DNA-based machines.