PROBLEM TO BE SOLVED: To provide an optical semiconductor device which includes a compact obtained by molding of a white curable composition for the optical semiconductor device and produces less migration at a metal part.SOLUTION: An optical semiconductor device 1 according to an embodiment of this invention comprises: a lead frame 2; an optical semiconductor element 3 mounted on the lead frame 2; and a compact 4 arranged on the lead frame 2. The compact 4 is obtained by hardening of a white curable composition for an optical semiconductor. The white curable composition for the optical semiconductor contains an epoxy compound, a curative agent, a titanium oxide, a filler different from the titanium oxide, a hardening accelerator and an antioxidant. A molecular mass of the antioxidant is 600 or larger and less than 2000. Constituent atoms of the antioxidant are only three kinds, a carbon atom, an oxygen atom and a hydrogen atom.