The crystal of the famous flavoring agent vanillin is known for its nonlinear optical activity. Density functional theory at B3LYP/6-31G(d) level has been used to compute energies of different conformers of vanillin to find their stability, the optimized geometry of the most stable conformer and its vibrational spectrum. The conformer VAN1 with torsion angles 0°, 180° and 0° respectively for C2–C1–C7–O14, C2–C1–C7–H13 and C3–C4–O10–H19 is found to be most stable. Geometry predicted by DFT and XRD reveals that geometrical parameters of hydroxyl group are altered substantially because of intermolecular hydrogen bonding. Vibrational analysis based on the NIR FT Raman, FT IR and computed spectrum reveals that the CH in-plane bending of the aldehyde group interacts with its stretching mode via Fermi resonance, and evidence for intermolecular hydrogen bonding can be observed as the broadness of the band in the stretching region in IR spectrum. The unusual lowering of carbonyl stretching wave number is attributed to the electron-releasing effect of CO group in the acceptor subunit due to intramolecular charge transfer, leading to NLO activity, in addition to the intermolecular interaction and π-conjugation. Other vibrational spectral contributions of NLO activity such as violation of selection rule for tangential CC stretching mode 8 and overlooking of complementarities are also observed. Nonbonded interactions affecting each vibrational mode are found, and the resulting shifting of band position is discussed. First-order hyperpolarizability, computed at HF/3-21G level, is used to analyze the conformation dependent NLO activity. Copyright © 2005 John Wiley & Sons, Ltd.