Reaction of K3[Fe(CN)6], NiCl2 and diethylenetriamine (dien) resulted in the formation of a cyanide-containing heterometallic compound [Ni(dien)2]2[Fe(CN)6]·4H2O 1. The structure consists of two octahedral [Ni(dien)2]2+ cations, one octahedral [Fe(CN)6]4− anion and four crystallization water molecules, which are held together by hydrogen-bonding interactions. Its TG curve exhibits two stages of mass loss. Compound 1 in DMF solutions has a very strong third-order non-linear optical (NLO) behavior with an absorption coefficient and refractive index α2 = 1.10 × 10−11 m w−1, n 2 = −3.05 × 10−19 m2 w−1, respectively, and third-order NLO susceptibility χ(3) 4.34 × 10−13 esu.