1 Introduction

Most scientists are now concentrating on developing efficient materials for solar energy. Despite silicon technology’s commercial dominance, thin films like CdTe and Cu (In, Ga) Se2 may present practical alternatives (Wang et al. 2021, 2022). The severe toxicity of cadmium and the scarcity of indium material present problems, though low-cost and earth-abundant materials are essential to meet the demands of researchers. The discovery has therefore prompted a renewed interest in metal sulfide compounds (Gao and Zhao 2022; Li et al. 2022).

Metal sulfides have received extensive study due to their applications in various devices, including lithium-ion batteries, solar cells, optical sensors, light-emitting diodes, nonvolatile memory devices, fuel cells, and thermoelectric devices. Metal sulfides are a significant group of materials that provide n-type and p-type semiconductors for research due to their various structural types since they are typically found in various forms as binary, ternary, and quaternary metal sulfides (Kajana et al. 2022; Vakalopoulou et al. 2022a; Verma et al. 2022).

Binary metal sulfide (BMS) is a great and inexpensive material that can be used in solar cells as n-type and p-type semiconductor materials. BMS such as copper sulfide (CuS), pyrite (FeS2), zinc sulfide (ZnS), cadmium sulfide (CdS), bismuth sulfide (Bi2S3), and indium sulfide (In2S3) are abundant and inexpensive (Karsandık et al. 2022; Vakalopoulou et al. 2022b). Zinc sulfide (ZnS) is a vital metal sulfide with n-type conductivity, high transmittance, high refractive index, good chemical stability, and a wide direct bandgap. So, it can be used to create electroluminescent phosphors, sensors, photocatalysis, and light-emitting diodes (Hathot et al. 2022; Jrad et al. 2022). Copper sulfide (CuS) compound is one of the essential materials used in various applications like hydrogen storage, optoelectronic devices, photocatalysis, and photovoltaic absorbers because it has a low energy gap, p-type conductivity, and a high absorption coefficient. Further, indium sulfide (In2S3) drew particular attention among various chalcogenides due to its abundance on earth, nontoxicity, wider optical absorption, and narrow bandgap (Habiboglu et al. 2022; Vinotha et al. 2022).

On the other hand, ternary metal sulfide (TMS) is a significant semiconductor material that can be utilized in a variety of applications because it displays exceptional physical and chemical characteristics that make them suited for a variety of uses, such as solar panels, IR sensors, IR lasers, window coatings, energy systems, and optical fiber and light-emitting diodes (LEDs). TMS like CuInS2, CuSbSe2, CuBiS2, CuSbS2, and CuInSe2 are important absorbers with narrow band gaps, p-type conductivity, and an absorption coefficient of more than 10–4 cm−1 (Chalapathi et al. 2022; Surucu et al. 2022).

Copper antimony selenide CuSbSe2 is a vital absorber layer characterized by a low energy gap, abundance on earth, and p-type conductivity (Abouabassi et al. 2022; Vázquez-Barragán et al. 2022). The CuSbSe2 display good photovoltaic performance in different devices. Further, high-quality p-type CuSbSe2 thin films were successfully created by Elradaf et al. These films helped fabricate ITO/CdS/CuSbSe2/Au solar cells that produce solar conversion efficiency of about 1.66% (El-Bana and El Radaf 2022). Also, tin-antimony sulfide (SnSb2S4) is a vital ternary chalcogenide with good optical and electrical properties. El Radaf et al. success in fabricating SnSb2S4 by spray pyrolysis procedure. This compound displays good absorption coefficients, optical conductivity, refractive index, nonlinear optical parameters, and small bandgap energy (El Radaf 2020a).

On the other side, researchers have recently concentrated on creating novel quaternary metal sulfide (QMS) thin films due to their intriguing optoelectronic, electrical, and optical characteristics. The development of QMS thin films into a new type of material has led to applications in photovoltaics, phase change materials, thin film solar cells (TFSC), optical fibers, holography, inorganic photoresists, reversible optical recording, and infrared devices (Akcay et al. 2022; Liu et al. 2022).

The Ag2ZnSnS4, Cu2ZnSnS4, and Cu2ZnGeS4 compositions are important QMS that exhibit interesting optical and electrical features. In prior literature, it was reported that these films exhibited good photoelectric properties as significant absorption layers. They are also inexpensive to manufacture, stable, non-toxic, and abundant on Earth (El Radaf 2020b; El Radaf and Al-Zahrani 2020; Tian et al. 2014). According to previous studies, Ag2ZnSnS4 films have good optical conductivity, suitable nonlinear optical parameters, and a high absorption coefficient. So, Ag2ZnSnS4 films make an excellent absorber layer (Das and Mahanandia 2022).

On the other hand, Cu2ZnSnS4 (CZTS4) is important QMS material and displays good optical and electrical performance. CZTS4 thin films make an excellent absorber layer, according to prior research. The Mo/CZTS4/CdS/ZnO/Al-doped ZnO/Al/LiF2 solar cell has an efficiency of 11%, according to Chang et al. (Yan et al. 2018). On the other hand, Fouad et al. (2018) successfully created high-quality CZTS4 films with good optical conductivity, nonlinear optical characteristics, and an increased absorption coefficient. The Al/n-Si/CZTS4/Au heterojunction they created also had a solar efficiency of 3.37% (Fouad et al. 2018). Cu2ZnSnSe4 thin films are also adequate absorber layers for the Mo/Cu2ZnSnSe4/CdS/ZnO/Al-doped ZnO/Ni/Al/MgF2 solar cells, which display an efficiency of 12.5% (Yin et al. 2022). Previous studies have focused on various quaternary metals sulfides like Ag2ZnSnS4, Cu2ZnSnS4, Cu2FeSnS4, and Cu2MnSnS4 thin films, but no research has been done on the physical characteristics of CuNiBiS3 thin films. So, in the current study, the novel CuNiBiS3 thin films are being created using the chemical bath deposition process. Also, the authors investigated the impact of layer thickness on the optoelectrical and optical characteristics and linear and nonlinear parameters.

2 Experimental details

A low-cost chemical bath deposition approach was utilized in this study to create the CuNiBiS3 thin films. We initially carried out a substrate cleaning technique to produce CuNiBiS3 thin films of higher quality. For cleaning, the glass sheets were submerged in pure acetone (CH3COCH3) in an ultrasonic bath for 15 min. Following that, the glass slides were immersed in isopropanol for 15 min. After being thoroughly cleaned with deionized water, the glass slides were air dry. Four solutions interacted with one another to form the CuNiBiS3 solution: 20 ml of deionized water was dissolved in 0.06 M copper chloride (CuCl2) to make the first solution. In order to make the second solution, 0.06 M nickel acetate (Ni(OCOCH3)2) was also dissolved in 20 ml of deionized water. To make the third solution, 0.06 M of bismuth nitrate (Bi(NO3)3) was dissolved in 10 ml of deionized water. In order to prepare the fourth solution, 0.18 M thiourea (SC(NH2)2 was dissolved in 60 ml of deionized water. All used chemicals are Sigma Aldrich-99.99%). The final solution’s pH was raised to 11 by adding a few drops of an ammonium hydroxide solution. The glass substrates were cleaned and placed vertically inside the glass beaker at room temperature. After the chemical reaction had taken place for 3, 5, 7, and 9 h, the slides were removed from the beaker, cleaned with deionized water, and dried in the air. A Philips-X’Pert X-ray diffractometer extensively inspected the structural features of the CuNiBiS3 layers. Further, the field emission scanning electron microscope (Quanta-FeG-250 USA) was utilized to study the morphology and composition of the CuNiBiS3 films. On the other hand, a Shimadzu spectrophotometer (type UV-3600 Plus UV–VIS–NIR) was utilized to list the optical data in the wavelength range of 400–2500 nm.

3 Results and discussions

3.1 Morphological and XRD studies

The FESEM equipment has been used to analyse the CuNiBiS3 surface morphology. Figure 1a, b, c, and d depicted the morphological characteristics of CuNiBiS3 films 1 µm.

Fig. 1
figure 1

SEM of the CuNiBiS3 layer of thickness: a 165 nm, b 232 nm, c 349 and d 437 nm

According to these FESEM micrographs, the surface of these layers is nearly homogeneous and uniform. Moreover, boosting the layer thickness enhanced the surface uniformity of the investigated layers due to the space between film grains getting less as they get bigger.

On the other hand, the chemical composition of the CuNiBiS3 layers has been explored using energy-dispersive X-ray spectroscopy as presented in Fig. 2a and b. According to the reported data, the respect ratio utilized to create the CuNiBiS3 samples was nearly identical to 1:1:1:3.

Fig. 2
figure 2

EDAX spectra of the a CuNiBiS3 layer of thickness 165 nm, b CuNiBiS3 layer of thickness 437 nm

Figure 3 displays the XRD results of the CuNiBiS3 layers deposited at different thicknesses. These illustrations show that these layers are polycrystalline, and the standard JCPDS file no. 46–1319. The displayed peaks belonged to a single CuNiBiS3 phase with an orthorhombic structure.

Fig. 3
figure 3

XRD charts for the CuNiBiS3 layers

The average crystallite sizes (DW–H) and the microstrain (\(\varepsilon\)) of the CuNiBiS3 layers were assessed using the Williamson–Hall (W–H) relationship (Akl et al. 2021; Akl and Hassanien 2014):

$$\beta\, \mathrm{cos}\,\theta =\frac{k\lambda }{D}+4\,\varepsilon \mathrm{sin}\,\theta$$
(1)

where β refers to the experimental full width at half maximum intensity.

Using the integral breadth of the sample and the gaussian distribution function, the values of β were evaluated. Figure 4 shows the Williamson–Hall plots for the CuNiBiS3 layers. According to this plot, the data points were fit to a straight line, where the slope gives the microstrain of the CuNiBiS3 layers, and the inverse of the y-intercept gives the grain size of the CuNiBiS3 layers. In Table 1, the DWH and \(\varepsilon\) values of the CuNiBiS3 layers were recorded. This table shows how the crystallite size of the CuNiBiS3 layers rose when the layer’s thickness was boosted. On the other hand, as the thickness was boosted, the values of \(\varepsilon\) decreased.

Fig. 4
figure 4

The plot of 4sin(θ) against βcos (θ) for the CuNiBiS3 layers

Table 1 Structural indices for the CuNiBiS3 layers

Additionally, the following relationships were utilized to estimate the number of crystallites (\({N}_{C}\)), and the dislocation density (\(\delta\)) of the CuNiBiS3 layers (Hassanien et al. 2021; Hathot et al. 2022):

$$N_{C} = \frac{t}{{D^{3} }}$$
(2)
$$\delta = \frac{1}{{D^{2} }}$$
(3)

Moreover, crystallite sizes (DS) of the CuNiBiS3 layers can be evaluated using Scherer relationships (Akl et al. 2020; Akl and Hassanien 2021; Das et al. 2023; Hassanien and El Radaf 2020; Priyadarshini et al. 2021; El Radaf 2023):

$$D_{S} = \frac{0.9 \lambda }{{\beta \cos \theta }}$$
(4)

Table 1 shows the \(\delta\), DS, DW–H, NC, and ε for the CuNiBiS3 layers, displaying that as the film thickness of the CuNiBiS3 samples increased, the DS, and DW–H values were expanded while the \(\delta\), NC, and ε values were reduced. According to this table the evaluated values of the DS, and DW–H of the CuNiBiS3 layers are near to each other.

3.2 Linear optical studies

In the current work, the optical transmittance (T) and reflectance (R) of the CuNiBiS3 films were obtained using a double-beam spectrophotometer. Using the T and R, the linear optical parameters of the CuNiBiS3 have been computed. The T and R spectra of the novel CuNiBiS3 layers in the 400–2500 nm wavelength range are shown in Fig. 5a and b. This graph shows that the CuNiBiS3 layers have high optical transmittance of up to 86% and that the T of the CuNiBiS3 layers is reduced by boosting the layer thickness. This trend was related to increasing the thickness of the samples increasing the absorbance value in the films, which decreased the transmittance value in the films (Behera et al. 2020; Naik et al. 2013; Naik and Ganesan 2014). Further, the R of the CuNiBiS3 films improved by enlarging the layer thickness.

Fig. 5
figure 5

a The spectral alterations of T as functions of λ for the CuNiBiS3 samples, b the spectral variations of R as functions of λ for the CuNiBiS3 films

The absorption coefficient of the studied films is a very relevant factor that illustrates how deep into the substance can travel the light when absorbed. In this report, the absorption coefficient of the CuNiBiS3 films was computed using the below formula (El Radaf and Al-Zahrani 2022):

$$\alpha =\frac{1}{d}ln\left[\frac{{\left(1-R\right)}^{2}}{2T}+{\left(\frac{{\left(1-R\right)}^{4}}{{4T}^{2}}+{R}^{2}\right)}^{1/2}\right]$$
(5)

where d refers to the thickness of the sprayed CuNiBiS3 films.

Figure 6a shows the reliance of \(\alpha\) on the in λ for the novel CuNiBiS3 films. It is revealed that the CuNiBiS3 layers have large values of the \(\alpha\). By raising the layer thickness of the CuNiBiS3 layers, the values of \(\alpha\) were boosted.

Fig. 6
figure 6

a The absorption coefficient \(\alpha\) of the novel CuNiBiS3 layers versus \(\lambda\), b the (αhν)2 against for the CuNiBiS3 samples, c the alteration of ln (α) with the \(h\nu\) for the CuNiBiS3 samples

On the other side, the energy gap (Eg) of the sprayed CuNiBiS3 films was obtained by Tauc’s relationship (Mohamed et al. 2019b; Qasem et al. 2020; Tauc et al. 1966):

$$\alpha h\nu =R{\left(h\nu -{E}_{g}\right)}^{g}$$
(6)

Here, R is Tauc parameter, and f designates the optical transition kind, either direct allowed (g = 0.5) or indirect allowed (g = 2).

A good match has been identified for g = 2, indicating the allowed direct transition state. Figure 6b depicts the relationship between (hv)2 against hv for the novel CuNiBiS3 layers. The Eg values of the novel CuNiBiS3 layers are listed in Table 2. The k selection rule and the disorder-induced spatial correlation of optical transitions between the valence and conduction bands are both reflected in the constant R, which also contains information about the convolution of the valence and conduction band states and the matrix element of optical transitions. Not only that, but R is extremely bond type dependant. When compared to the intense absorption in the band gap region, the loss due to reflection was relatively little (Ghosh et al. 2023). It is obvious that the Eg values decreased from 1.43 to 1.31 eV as the layer thickness was raised. This tendency results in the film energy gap narrowing, which may be explained by the correlation between the increasing layer thickness and the rise in localized states inside the gap (Dughaish and Mohamed 2013; Hassanien et al. 2016; Mohamed et al. 2010). Typically, film thickness increases concurrently with the creation of defects in the layer that result in localized states along the valence band and conduction band boundaries.

Table 2 The optical and dispersion constants of the CuNiBiS3 samples

Additionally, we compute the Urbach energy (Eu) of the novel CuNiBiS3 films using the Urbach relation (Qasem et al. 2022):

$$\mathrm{\alpha }={\mathrm{\alpha }}_{\mathrm{o}}\mathrm{exp}\left(\mathrm{h\upsilon }/{\mathrm{E}}_{\mathrm{u}}\right)$$
(7)

A plot of the ln (α) of the innovative CuNiBiS3 films against hv is provided in Fig. 6c. This graph indicates how the values of Eu for CuNiBiS3 films can be obtained using the slope of a straight line. Likewise, Table 2 lists the Eu of the novel CuNiBiS3 films. It is apparent from the table that the Eu values increased as the film thickness. This trend was related to increasing the annealing the number of defect states in the confined region and the degree of disorder, both of which lead to a smaller band gap, as reported by this and other studies (Naik et al. 2009; Sahoo et al. 2020).

Furthermore, the extinction coefficient of the novel CuNiBiS3 layers (k) was computed by the below formula (Hassanien et al. 2020b):

$$k = \frac{\alpha \lambda }{{4\pi }}$$
(8)

Figure 7a implies the alteration of k of the CuNiBiS3 layers with \(\lambda\). It was evident that when thickness rose, the values of the extinction coefficient, k, were also boosted. This trend may be attributed to enlarging these samples’ absorption coefficient by boosting the thickness (Mohamed et al. 2019a).

Fig. 7
figure 7

a The relationship between the k and λ of the CuNiBiS3 layers, b The variance of the n with λ of the CuNiBiS3 layers

On the other side, the refractive index (n) of the novel CuNiBiS3 layers was estimated according to the Kramer-Kroning relationship (El Radaf et al. 2020):

$$n = \frac{1 + R}{{1 - R }} + \left( {\frac{4R}{{\left( {1 - R} \right)^{2} }} - k^{2} } \right)^{1/2}$$
(9)

The variation in the n of the CuNiBiS3 layers with λ is established in Fig. 7b. It is noted that the \(n\) was boosted as the layer thickness enlarged. This behavior might be ascribed to enlarging of these samples’ reflectance by boosting the thickness (Naik et al. 2020).

Likewise, the Wemple–DiDomenico relations was employed to determine the dispersion parameters of the novel CuNiBiS3 films (Wemple 1973; Wemple and DiDomenico 1971):

$$n^{2} = 1 + \frac{{E_{o} E_{d} }}{{E_{o}^{2} - \left( {h\upsilon } \right)^{2} }}$$
(10)

where Ed refers to the dispersion energy of the CuNiBiS3 layers, and Eo stands for the oscillator energy of the CuNiBiS3 layers.

Figure 8 illustrates the plot of the (\(({n}^{2}-1{)}^{-1}\) versus \((h\upsilon {)}^{2}\) for the novel CuNiBiS3 films. The values of the Eo and the Ed of the novel CuNiBiS3 films were computed from this plot. Table 2 lists the values of the Eo and the Ed of the novel CuNiBiS3 films. According to this table, Ed values climbed while Eo values dropped as film thickness grew.

Fig. 8
figure 8

The alteration of \({\left({n}^{2}-1\right)}^{-1}\) as function of \({\left(h\nu \right)}^{2}\) for the CuNiBiS3 layers

Additionally, we compute the oscillator parameter of the novel CuNiBiS3 films (the static high-frequency dielectric constant, \({\varepsilon }_{s}\) refers to the static refractive index, no and the oscillator strength, f) by the Wemple-DiDomenico relations (Aly 2010; Hassanien 2016; Mohamed et al. 2019a):

$$f = E_{o} E_{d}$$
(11)
$$n_{o} = \sqrt {1 + \frac{{E_{d} }}{{E_{o} }}}$$
(12)
$$\varepsilon_{s} = n_{o}^{2}$$
(13)

Table 2 shows the magnitudes of the \({\varepsilon }_{s}\), no and f of the novel CuNiBiS3 layers. It can be detected that as the layer thickness of the CuNiBiS3 layers boosted, the \({\varepsilon }_{s}\), no, and f values were enlarged.

3.3 Optoelectrical characterization

The optoelectrical characteristics of the substances under study, such as lattice dielectric constant, optical carrier concentration, optical conductivity, plasma frequency, and electrical conductivity, play a critical role in assessing whether the materials will be employed in optoelectronic devices. In this paper, the below optoelectrical relations were employed in order to evaluate the lattice dielectric constant \({\varepsilon }_{L}\), plasma frequency \({\omega }_{p}\), and the values of charge carrier concentration to effective mass ratio \({N}_{opt}/{m}^{*}\) of the CuNiBiS3 films (Sharma et al. 2022; Sharma and Katyal 2008):

$$n^{2} = \varepsilon_{L} - \left( {\frac{{e^{2} }}{{4\pi^{2} c^{2} \varepsilon_{0} }}} \right)\left( {\frac{{N_{opt} }}{{m^{*} }}} \right)\lambda^{2}$$
(14)
$$\omega_{p} = \sqrt {\frac{{e^{2} N_{opt} }}{{\varepsilon_{0} \varepsilon_{\infty } m^{*} }}}$$
(15)

where \({\varepsilon }_{0}\) refers to the free space electric permittivity, \(c\) stands for the speed of light, \(e\) stands for the electronic charge.

The fluctuations of \({n}^{2}\) versus \({\lambda }^{2}\) for the CuNiBiS3 films can be seen in Fig. 9a. From this plot, we deduce the \(\left({N}_{opt}/{m}^{*}\right)\) and \({\varepsilon }_{L}\) values. Table 3 provides the values of the \(\left({N}_{opt}/{m}^{*}\right)\) and \({\varepsilon }_{L}\). It has been established that as the film thickness is raised, the \(\left({N}_{opt}/{m}^{*}\right)\) enlarged. This performance could possibly be attributed to the rise in lone-pair electrons of sulfur atoms in the layer. On the other hand, as the film thickness is raised, the values of \({\varepsilon }_{L}\) improve. The possibility of ordering CuNiBiS3 films, which would improve the film’s atom arrangement in comparison to other investigated films, may be the cause of this pattern. The in \({\varepsilon }_{L}\) value of the studied layers enlarged. Moreover, the values of \({\omega }_{p}\) of the CuNiBiS3 layers reduced by enlarging the layer thickness.

Fig. 9
figure 9

a The variation of \({n}^{2}\) with \({\lambda }^{2}\) for the CuNiBiS3 layers, b the credence of the ε2 on \({\lambda }^{3}\) for the CuNiBiS3 layers

Table 3 The optoelectrical parameters of the CuNiBiS3 layers

Likewise, the relaxation time τ of the novel CuNiBiS3 layers was estimated according to the below relationship (Sharma and Hassanien 2020):

$$\varepsilon_{2} = \frac{1}{{4\pi^{3} \varepsilon_{0} }}\left( {\frac{{e^{2} }}{{c^{3} }}} \right)\left( {\frac{{N_{opt} }}{{m^{*} }}} \right)\left( {\frac{1}{\tau }} \right)\lambda^{3 }$$
(16)

Figure 9b implies the alteration of the ε2 on the λ3 for the CuNiBiS3 films. It was evident that when thickness rose, the values of τ were reduced.

Furthermore, the following equations were employed to compute the optical resistivity and optical mobility of the CuNiBiS3 films (El-Denglawey et al. 2022; Hassanien and Sharma 2021):

$$\rho_{opt} = \frac{1}{e}\mu_{opt}$$
(17)
$$\mu_{opt} = \frac{e\tau }{{m^{*} }}$$
(18)

Table 3 lists the magnitudes of the µopt and ρopt for the CuNiBiS3 layers. It can be detected that as the film thickness of the CuNiBiS3 layers enlarged, the µopt and ρopt values were boosted. These findings exhibit good consistency with the other papers that have already been published (Hassanien et al. 2020a).

Depending on the values of the n and α of the novel CuNiBiS3 layers, the values of the optical conductivity (σopt) and the electrical conductivity (σe) can be estimated according to the below relations (El Radaf et al. 2018; El Radaf and Abdelhameed 2018):

$$\sigma_{opt} = \frac{\alpha nc}{{4\pi }}$$
(19)
$$\sigma_{e} = \frac{{2{\uplambda }\sigma_{opt} }}{{\upalpha }}$$
(20)

A plot of the σopt versus hv for the CuNiBiS3 layers can be seen in Fig. 10a. It was evident that as layer thickness expanded, optical conductivity values also steadily enlarged. The improvement of charge carriers was related to this performance. Likewise, when the incident photon energy grew, so did the optical conductivity. Increased photon energy-induced electronic charge excitation is the cause of this pattern (Wassel and El Radaf 2020).

Fig. 10
figure 10

a The alteration of the \({\sigma }_{opt}\) with the \(h\upsilon\) for the CuNiBiS3 samples, b the \({\sigma }_{e}\) against the \(h\upsilon\) for the CuNiBiS3 samples

The relationship between electrical conductivity and photon energy is seen in Fig. 10b. The graph clearly indicates that the electrical conductivity values of the CuNiBiS3 films enhance with film thickness while diminishing with incident photon energy.

Additionally, we compute the imaginary and real components of the optical dielectric constant (\({\varepsilon }_{1} \mathrm{and} {\varepsilon }_{2} )\) of the novel CuNiBiS3 layers using the below relations (Ali et al. 2018; El Radaf et al. 2019):

$$\varepsilon_{1} = n^{2} - k^{2}$$
(21)
$$\varepsilon_{2} = 2nk$$
(22)

Figure 11a and b indicate the alteration of the ε1 and ε2 of the novel CuNiBiS3 layers with λ. It can be observed that the ε1 and ε2 of the novel CuNiBiS3 layers were supposedly enhanced by boosting the layer thickness. This performance may be related to enlarging the values of n and k by boosting the film thickness.

Fig. 11
figure 11

a The plot of ε1 against the λ for the CuNiBiS3 samples, b the ε2 versus the λ for the CuNiBiS3 samples

3.4 Nonlinear optical indices

On the other side, Miller’s relations can also be used to predict the third-order nonlinear susceptibility \({\upchi }^{\left(3\right)}\), the first-order nonlinear susceptibility \({\upchi }^{\left(1\right)}\), and the nonlinear refractive index \({n}_{2}\) of the CuNiBiS3 layers by (Alzaid et al. 2020; Hassanien 2022; Hassanien et al. 2021; Shaaban et al. 2019):

$$\upchi^{\left( 1 \right)} = \frac{{{\text{n}}^{2} - 1}}{4\uppi }$$
(23)
$$\upchi^{\left( 3 \right)} = B\left[ {\frac{{{\text{n}}^{2} - 1}}{4\uppi }} \right]^{4}$$
(24)
$${\text{n}}_{2} = \frac{{12\uppi \upchi^{\left( 3 \right)} }}{{{\text{n}}_{0} }}$$
(25)

Figure 12a–c indicates how the nonlinear indices of the novel CuNiBiS3 films rely on the photon energy. These figures indicate that increasing the thickness of the explored layers boosted the values of the \({\upchi }^{(1)}\), \({\upchi }^{\left(3\right)}\), and \({\mathrm{n}}_{2}\). This may be connected to the improvement in film refractive indices, which helps to expand the three-dimensional network of the films. The obtained values for the indices \({\upchi }^{(1)}\), \({\upchi }^{\left(3\right)}\), and \({n}_{2}\) are also roughly higher than those for earlier described semiconductors (Das et al. 2022; Naik et al. 2020; El Radaf 2020c; El Radaf and Al-Zahrani 2021; El Radaf and Wassel 2021; Sahoo et al. 2021a, 2021b). This would suggest that there are additional carriers in the CuNiBiS3 material under study. The bound electrons’ nonlinear reaction to the light’s electric field in the material is enhanced.

Fig. 12
figure 12

ac: The alteration of the \({\upchi }^{(1)}\), \({\upchi }^{\left(3\right)}\), and \({\mathrm{n}}_{2}\) with \(h\nu\) for the CuNiBiS3 samples

3.5 Identifying the majority carriers in the CuNiBiS3 layers

The hot-probe procedure is crucial for identifying the semiconductor type. The hot-probe technique reveals p-type conductivity in the CuNiBiS3 layers. During this process, a soldering iron and a sensitive multimeter are used. Figure 13 indicates how to do a hot probe. The heated side of the CuNiBiS3 film was attached to the positive multimeter terminal, which was attached to the multimeter’s negative terminal. The n-type semiconductor is represented by the positive voltage that was recorded on the multimeter after the experiment, whereas the p-type semiconductor is represented by the negative voltage (Göde 2011; Golan et al. 2006). Our studies have shown that all CuNiBiS3 films generate a negative voltage when heated. This demonstrates that the films frequently behave as p-type semiconductors.

Fig. 13
figure 13

The hot-probe experiment applied to the CuNiBiS3 samples

4 Conclusion

This study presented the fabrication of the CuNiBiS3 layers of various thicknesses using the chemical bath deposition method. The XRD measurements investigated the structure of the as-deposited CuNiBiS3 samples to be orthorhombic. The composition of the CuNiBiS3 layers was confirmed by the EDAX measurements, which show stoichiometric composition. Additionally, the novel CuNiBiS3 layers show a direct energy gap, and by increasing the layer thickness from 165 to 437 nm, the energy gaps of these layers were reduced from 1.43 to 1.31 eV. The extinction coefficient, refractive index, Urbach energy, and absorption coefficient values also increased as the layer thickness was boosted. Also, increasing the thickness of the investigated layers boosted the optoelectrical indices, such as optical mobility, optical carrier concentration, optical conductivity, relaxation duration, and optical resistivity. The nonlinear optical investigation showed that enlarging the thickness improved the nonlinear optical characteristics. The hot prob method also proved the p-type semiconducting characteristics of our samples.