The potentials of a nanophotonic platform, including compactness, low power consumption, integrability with other functionalities, and high sensitivity make them a suitable candidate for sensing applications. Strong light-matter interaction in such a platform enables a variety of sensing mechanisms, including refractive index change, fluorescence emission, and Raman scattering. Recent advances in nanophotonic devices include the demonstration of silicon and silicon-nitride microdisk resonators with high intrinsic Q values (0.5-2×106) for strong field enhancement and the realization of compact photonic crystal spectrometers (high spectral resolution at 100-µm length scales) for on-chip spectral analysis. These two basic building blocks, when combined with integrated fluidic channels for sample delivery, provide an efficient platform to implement different sensing mechanisms and architectures.