The nitrogen-doped carbon nano-onions (NCNOs) were prepared by annealing the ultra-dispersed aminated-nanodiamond solution under He gas at 1150°C followed by calcination at 400°C. The nanostructures of CoWO4, MnO2, CoWO4-MnO2, and CoWO4-MnO2-NCNO were synthesized through the simple precipitation method under ultrasonication followed by calcination at 450°C. The morphology, structure, and optoelectronic properties of the samples were examined by scanning electron microscopy (SEM), X-ray diffraction (XRD), Fourier transform infrared (FTIR) spectroscopy and Z-scan method. The homogeneous distribution of the tiny aggregated plate-like and spongy particles throughout the nanocomposite created a highly porous nanostructure with a large surface area. The nonlinear absorption (NLA) coefficient and nonlinear refractive (NLR) index were of the order of 10-3(cm/W) and 10-8(cm2/W), respectively. In different incident intensity of laser, all synthesized samples show TPA effect implying the positive sign of NLA coefficient. MnO2 and NCNO structure have positive NLR index indicating the self-focusing optical nonlinearity. The self-defocusing effect and the negative sign of nonlinearity in the CoWO4 nanoparticles, MnO2-CoWO4, and MnO2-NCNO-CoWO4 nanocomposites are vivid. The porous structure of CoWO4 nanoparticles and trapping the light into CoWO4 nanoparticles are the main reasons for nonlinearity of this nanoparticles. Porosity is also one of the most important reasons for the nonlinear optical responses of NCNO structure. The NLR index and NLA coefficient of MnO2 decreased by increasing the incident intensity. Moreover, an increase in the incident intensity improved the nonlinear responses in the rest of samples. The present nonlinear optical results of the synthesized samples can be applied in optical devices.