1 Introduction

There is much current interest in composite films containing WO3 and TiO2 because they are applicable in a variety of electrical, catalytic and optical devices. WO3 is an important multifunctional material that has a wide spectrum of applications in electrochromic devices, catalysts, gas sensors, optical switching devices, etc. [1, 2]. These applications are possible due to the structural flexibility of WO3 and its cation intercalated states [36]. Over the past three decades, intensive research has been carried out towards improving WO3 based electrochromic (EC) devices [710]. TiO2 has been widely used as a photocatalyst ever since Honda and Fujishima first demonstrated that it was possible to produce hydrogen from water via photocatalysis with titania under UV irradiation [11]. Owing to its low cost, strong redox power, high photocatalytic activity and high chemical stability, it has been accepted as an ideal photocatalyst [1214]. Its wide band gap energy (3.0–3.2 eV) allows absorption of UV light, generating electrons (ē) and holes (h+), which can subsequently induce redox reactions [15]. Recently, syntheses of composite films involving WO3 and another metal oxide have received much attention for providing improved electronic or photoelectrochemical characteristics [16]. Particularly promising WO3 composites may be formed with metal oxides such as TiO2, to enhance either the electronic or the ionic properties of the material. A higher photoresponse was observed for bilayered WO3–TiO2 films relative to single-component films. Electron injection into the bulk WO3 layer was invoked as a mechanism for reduced surface carrier recombination in the TiO2 component in these composites [17]. The photocatalytic activity of WO3–TiO2 films was found to be three times higher than that of pure TiO2 films for the gas-phase oxidation of 2-propanol [18]. A TiO2 coating was coupled with a WO3 “electron pool” in the design of a photoelectrochemical anticorrosion system with built-in energy storage capability [19]. A WO3–TiO2 buffer layer between the transparent conducting oxide substrate and a P25 TiO2 layer was found to be beneficial in the operation of a Ru(II)-dye sensitized solar cell [20]. A photovoltaically self-charging battery based on a dye-modified TiO2 film in contact with an inner layer of WO3 has also been described [21].

As far as the chromogenic properties are concerned, WO3 and TiO2 show complementary electrochromic properties. Hence, an electrochromic WO3 layer can be combined with a photoactive dye sensitized TiO2 layer and a photochromic device can be constructed [2224]. An enhanced or better photochromic performance can be obtained if WO3–TiO2 composite layers have: (1) A nanocrystalline feature, as nanocrystalline anatase titania, owing to its enhanced generation of charge carriers facilitates the capture of photoelectrons from the excited dye molecule, and nanocrystalline WO3, which provides high surface area for ion intercalation/deintercalation; and (2) a mesoporous structure that can provide a large surface area for redox reactions and facilitate ion and electron transport. With higher surface areas and ordered pore structures, mesoporous metal oxides may demonstrate better performances than conventional metal oxides in applications such as energy conversion and storage, catalysis, sensing, adsorption,separation, etc. Utilization of highly crystalline mesoporous metal oxides (e.g., CeO2, TiO2) in dye sensitized solar cells (DSSCs) has been reported recently [2530]. Corma et al. [25] found that ordered mesoporous CeO2 prepared using CeO2 nanoparticles (5 nm) as the building blocks showed a photovoltaic response, whereas conventional CeO2 did not. The better photovoltaic behaviour of mesoporous nanocrystalline CeO2 is probably due to its high surface/grain-boundary area that enhances the electronic transport properties of nanocrystalline CeO2. Zukalová et al. [26] demonstrated that disordered mesoporous TiO2 film enhanced solar conversion efficiency by about 50 % compared to traditional films of the same thickness made from randomly oriented anatase nanocrystals when used in conventional liquid DSSCs. Mesoporous β-MnO2 was prepared and used as cathode for Li-ion batteries [31, 32]. Bulk β-MnO2 is electrochemically inert; however, mesoporous β-MnO2 (rutile structure) with an ordered pore structure (3.4 nm pore diameter) and crystalline walls (8 nm) was capable of reversibly accommodating lithium, up to a composition of Li0.92MnO2 [32]. Brezesinski et al. used an evaporation-induced self-assembly (EISA) method to prepare crystalline WO3, and used it as an electrochromic electrode. The charge storage of crystalline mesoporous WO3 was highly reversible, over 95 %, and the coloration efficiency was ca. 40 mF cm−2 [33]. Cheng et al. compared the electrochromic properties of disordered mesoporous WO3 to standard sol–gel films of WO3. The results indicated that the mesoporous material exhibited better kinetics for coloration and bleaching in comparison to standard sol–gel derived tungsten oxide [34]. Thus, WO3–TiO2 composite films with nanocrystallinity and mesoporosity are desired structures for enhanced photochromism.

TiO2–WO3 composites films with great uniformity can be obtained by MOCVD or sputtering techniques [35, 36]. However, these methods have high costs, and the preparation of films in a large area is technically difficult. The sol–gel method is an economical process which enjoys unique advantages. Films prepared by this method have a porous structure, which enhances the transport of electrons and cations during the double injection, resulting in improved coloration and bleaching processes. In addition, the sol–gel method offers the advantages of employing structure directing agents for the construction of layers with controlled porosity.

In this context, we describe herein a sol–gel synthesis of mesoporous WO3–TiO2 composite thin films, in which varying the annealing temperature allows the WO3 and TiO2 particles to adopt different nanocrystalline (NC) phases. Further, the thus obtained mesoporous WO3–TiO2 composite films were dye sensitized and utilized for the construction of photochromic devices. The photochromic properties of these devices were also studied. The mesoporosity as well as the degree of crystallization of titania present in the WO3–TiO2 composite layer were found to be essential parameters affecting the photochromic performance of the device.

2 Experimental

All chemicals in the present work were used as purchased from Aldrich.

2.1 Preparation of solutions for sol–gel coatings

The sol–gel coating solutions used for film coating were prepared according to the following modified procedures:

Porous films of sufficient thicknesses were obtained using hybrid organically modified silicate (ORMOSIL) as a template precursor. It was prepared by an acylation reaction between poly(propylene glycol)bis(2-aminopropyl ether) (2-APPG) with isocyanatopropyltriethoxysilane (ICS) in tetrahydrofuran (THF) in the volume ratio 1:0.1:1. This solution was refluxed for 6 h at 65 °C. After this step, THF was removed from the solution. The final solution was transparent and thick.

WO3 solutions were made by dissolving 7.5 g of tungsten powder (99.9 %) in 40 ml of hydrogen peroxide (30 %). After the initial reaction, the solution was left to stir at room temperature for 8 h, resulting in a tungsten peroxy acid solution. Then, 40 ml of ethanol (EtOH) was added to the tungsten peroxy solution and refluxed for 4 h at a temperature of 80 °C to form a tungsten peroxyethylester solution. Finally, 1.5 g of the hybrid ORMOSIL dissolved in 15 ml of EtOH was added dropwise into the WO3 solution and stirred for 1 h. The final solution was used for the WO3 film coating [37].

Titanium oxide (TiO2) coating solutions were prepared by hydrolysis and condensation reactions of anhydrous titanium isopropoxide (TTIP) with EtOH. The polymeric solution was prepared by mixing TTIP with EtOH in the volume ratio 1:10. The solution was stirred for 30 min to allow the hydrolysis and polymerisation reaction to occur. This solution was added slowly to a mixture of 3.9 ml of ethylacetoacetate (EAA) dissolved in 10 ml of EtOH. The hybrid ORMOSIL, as mentioned above, was added dropwise into the TiO2 polymeric solution and stirred for 1 h. The final transparent solution was used for the TiO2 film coating.

2.2 Preparation of WO3–TiO2 composite thin films

The synthesis of WO3–TiO2 composite thin film involved two stages. First, WO3 films were deposited on indium tin oxide (ITO) glass substrates by dip coating using the WO3 solution, at a withdrawal rate of 4 mm s−1. The obtained films were annealed in a programmable mufle furnace (Fisher Scientific) at 450, 500 or 600 °C (heating rate of 1 °C min−1) in air. The samples were maintained at the peak temperature for 1 h, resulting in the formation of porous tungsten oxide thin films. In the second stage of the synthesis, the porous WO3 thin films obtained during the first stage were dip coated using the TiO2 coating solution at a withdrawal rate of 4 mm s−1. The obtained films were again annealed at 450, 500 or 600 °C, (heating rate of 1 °C min−1) in air. The samples were maintained at the peak temperature for 1 h, resulting in the formation of WO3–TiO2 composite layers.

2.3 Preparation of the ion conducting (IC) solution

First, 0.67 g of lithium iodide (powder, 99.9 %) and 0.127 g of iodine (99.8 %) were mixed with 2 g of ORMOSIL and 2 ml of EtOH, afterwhich the mixture was left to stir at room temperature for 3 h. Then, 0.35 ml of acetic acid was added and allowed to mix for a minimum of 4 h. The final transparent solution was viscous with a yellow/brown color, and was used for the ion conducting layers.

2.4 Fabrication of photochromic devices

The mesoporous WO3–TiO2 composite thin films coated on ITO substrate and annealed at 450, 500, and 600 °C were immersed in an ethanolic solution of ruthenium dye [(cis-bis (isothiocyanato) bis (2,2’ bipyridyl-4,4’ dicarboxylato) ruthenium (II)] to obtain dye sensitized WO3–TiO2 layers. These dye sensitized WO3–TiO2 layers were used as active electrodes for the construction of photochromic (PE) devices. Then, the ion conducting (IC) solution containing a redox couple (I and I3 ) and Li ions was spread over the dye sensitized WO3–TiO2 composite layer. Several PE systems were constructed with the following configuration:

$$ {\text{ITO}}{\text{-coated}}\,{\text{glass}}1/{\text{WO}}_{3} - {\text{TiO}}_{2} - {\text{Ru}}( {{\text{II}}}){\text{-dye}}/{\text{ICLayer}}( {{\text{ICL}}} )/{\text{ITO}}{\text{-coated}}\,{\text{glass}}2 $$

The photoelectrochromic device combines the principle of dye-sensitized solar cell with an electrochromic device. Such device becomes colored when illuminated, and the device can be bleached in the dark. If another ITO coated glass electrode is applied on the top of the ICL, the device can be bleached by applying a reverse potential.

2.5 Characterization

For scanning electron microscopy (SEM) characterization of WO3–TiO2 films, specimen cross-sections were prepared and mounted vertically on 32 mm diameter aluminum specimen supports with conductive copper tape and colloidal graphite (Electron microscopy systems, Hatfield, Pennsylvania, USA). The colloidal solution consists of graphite in an isopropanol base (Isoproponal 66 %, graphite 15 %, n-Butanol 5 %, hexylene glycol 5 %, propylene glycol methyl ether 5 %). The specimens were coated with ca. 150 nm of gold in a Hummer 6.2 sputtering unit (Anatech Ltd., Hayward, CA) and examined using a JEOL JSM-5600 SEM (JEOL USA, Peabody, MA) equipped with an Oxford Inca 200 EDS system (Oxford Instruments, High Wycombe, UK). Images were collected using an accelerating voltage of 10 kV, while EDS spectra were collected at 20 kV. Both images and spectra were collected at a working distance of 20 mm.

Raman spectra were recorded at room temperature with a Jobin–Yvon Labram HR microanalytical spectrometer equipped with a motorized xy stage and autofocus. The spectra were generated with a 17 mW, 632.8 nm He–Ne laser excitation and dispersed with the 1,800 grooves mm−1 grating across the 0.8 m length of the spectrograph. The laser power was 4 mW at the sample surface. The spectral resolution is estimated to be less than 0.5 cm−1 for a slit width of 150 μm and a confocal hole of 300 μm.

X-ray diffraction (XRD) measurements were carried out in reflection with a custom built theta–theta diffractometer equipped with pyrolytic graphite monochromator and analyzer crystals. Cu K-α radiation (λ = 0.154178 nm) was used for the measurements, and the data are shown as a function of the modulus of the scattering vector q = 4πλ −1 sin θ, where 2θ is the scattering angle. Air-scattering was avoided by evacuating the sample space.

Photochromic measurements were made using Newport (Oriel), stabilized ozone free 75 Watts xenon arc lamp with a 1.5 in. focusing lens system. The distance between the source and the sample is adjusted to 80 cm, so as to achieve the power equivalent to one sun on the sample. The transmission spectra were recorded using an Ocean Optics spectrometer S2000, with included acquisition and control software.

3 Results and discussion

3.1 Micro-Raman spectroscopic studies of the WO3–TiO2 composite thin films annealed at 450, 500 and 600 °C

The micro-Raman spectrum of the WO3–TiO2 film coated on ITO-coated glass and annealed at 450 °C is displayed in Fig. 1A. Several features originating from two crystalline phases can be identified [5]. The broad asymmetric band ~709 cm−1 and the strong band at 807.0 cm−1 are characteristic features of monoclinic (m) WO3, and assigned to the stretching ν(O–W–O) modes of the bridging oxygen of a WO6 octahedra. The band ascribed to a lattice vibration was observed at 134.5 cm−1. The band observed at 270.8 cm−1 is assigned to δ(O–W–O) deformation vibrations in m-WO3, while the shoulder at 252.9 cm−1 is assigned to the hexagonal (h-WO3) phase. The deconvolution of the broad asymmetric band ~709 cm−1 reveals three peaks centred at 644.4, 693.7 and 708.6 cm−1. The peaks at 644.4, and 693.7 cm−1 clearly evidence the presence of h-WO3 phase and that at 708.6 cm−1 is assigned to the m-WO3 phase. However, the presence of h-WO3 is strongly dominated by the monoclinic phase. Further, no residuals of the organic part of the hybrid ORMOSIL template are observed in the spectral range studied. None of the signatures of anatase can be seen, hence, it appears that the crystallisation of TiO2 is hindered when coated on top of the WO3 layer.

Fig. 1
figure 1

Micro-Raman spectra of the WO3–TiO2 thin films annealed at 450 °C (A), 500 °C (B), and 600 °C (C)

Figure 1B shows the Raman spectrum of the WO3–TiO2 composite thin film annealed at 500 °C. The Raman band at 133.3 cm−1 is attributed to a lattice mode. The band at 270.7 cm−1 is emerging from the O–W–O deformation vibration, whereas, the bands at 713.7 and 806.2 cm−1 are attributed to the O–W–O stretching vibrations. All these bands are the characteristic features of monoclinic WO3. Again, any band due to crystalline TiO2 was not noticeable.

In the WO3–TiO2 composite films, irrespective of crystalline structures of WO3, TiO2 was found to be amorphous for the films annealed at 450, and 500 °C. Depero et al. have observed that, in the case of co-sputtered W/Ti films in oxygen atmosphere, only the crystallization of WO3 was observed at 500 °C, with titania being amorphous [38]. Also they noted the formation of hexagonal WO3 along with m-WO3 when annealed at 500 °C, which essentially verifies our observation that, independent of the type of crystalline structure of WO3, TiO2 exist in amorphous phase. They observed the crystallization of both WO3 and TiO2 only after annealing at 800 °C. Krašovec et al. [39] have prepared titania overlayer to a WO3 layer by sol–gel method. They prepared WO3 layer and annealed it at 450 °C, followed by the TiO2 coating and again annealed at 450 °C. After this two stage annealing process, they observed that the amorphous TiO2 existed in the interfaces among m-WO3 crystallites. The amorphous nature of TiO2 was carefully carried out by a HRTEM combined EDS analysis. These two studies reiterate that in WO3–TiO2 system, TiO2 exist essentially as amorphous layer at least up to an annealing temperature of 500 °C. Although the exact mechanism of inhibition of crystallization of TiO2 layer is not known, we speculate that, at low temperatures up to 500 °C, the TiO2 layer envelops the WO3 crystallites as WO3 crystallites have been already formed in the first stage. Upon annealing, only the organic components associated with TiO2 are calcinated and TiO2 layers around WO3 crystallites do not get enough kinetic energy for the crystallization. In this case, the energy is required not only for the crystallization of TiO2 but also to severe the weak disordered bonds between Ti–O–W. Also any process of crystallization is further limited by the grain boundaries of WO3. Hence a temperature higher than 500 °C is required for TiO2 crystallization, whereas it can crystallize at 400 °C in the absence of WO3, as we have shown in one of our earlier works [40].

After the first stage of deposition of the WO3 layer and annealing at 600 °C, the film was found to be monoclinic-WO3. The Raman spectrum (Fig. 1C) of the WO3–TiO2 composite film heat treated at 600 °C shows peaks at 806.2, 712.6 cm−1[ν(O–W–O)], 328.1, 268.5 cm−1 [δ(O–W–O)], 133.6, 92.5 cm−1 (lattice modes) and a low intensity peak at 151.5 cm−1. It is well known that the peak positions corresponding to the stretching vibrations of O–W–O bonds are the same for the triclinic, monoclinic, and orthorhombic phases of WO3, whereas their lattice vibrations in the range 70–100 cm−1, show a difference in the Raman spectra [4144]. This is primarily due to the fact that the lattice vibrational bands arise from the (W2O2)n chains of WO3. As the low temperature phases of WO3 are less symmetric than the high temperature phases, the lattice vibrations between 70 and 100 cm−1 in Fig. 2A exhibit more Raman bands for the m-WO3 (89.6, 81.2, and 71.3 cm−1) and only one mode at 92.5 cm−1 for the o-WO3 (Fig. 2B). Pecquenard et al. have shown that o-WO3 can be crystallized at temperatures between 600 and 800 °C using titanium oxide as structure stabilizer [44]. They reported the lattice vibrational mode of o-WO3 at 91 cm−1, which is similar to our result for the WO3–TiO2 composite film annealed at 600 °C. In addition, in the Raman spectrum of the WO3–TiO2 composite film annealed at 600 °C (Fig. 1C), the mode emerging at 151.5 cm−1 is due to the crystallization of the TiO2 in the anatase form [45]. Also, the anatase main band is high-frequency shifted (151.5 cm−1) with respect to the value of commercial anatase TiO2 powder (142.5 cm−1), indicating that the TiO2 is constituted of TiO2 nanoparticles. A phonon confinement model has been applied to establish a relation between the crystallite sizes and the main Raman peak position of TiO2, and the observed shift corresponds to a crystallite size of ~5 nm [45]. Compared with the WO3 sample annealed at 500 °C, which had amorphous TiO2, formation of the orthorhombic phase of WO3 in the WO3–TiO2 composite film heat treated at 600 °C has been favored by the presence of crystalline anatase. This observation agrees with the report of Pecquenard et al. [44].

Fig. 2
figure 2

XRD patterns of the WO3–TiO2 thin films annealed at 450 °C (A), 500 °C (B), and 600 °C (C). The peak indicated by asterisk is emerging from the ITO layer

3.2 X-ray diffraction studies of the WO3–TiO2 composite thin films annealed at 450, 500 and 600 °C

Figure 2A shows the XRD patterns of the WO3–TiO2 composite film prepared at 450°. Tungsten oxide peaks in the WO3–TiO2 composite layer are mainly m-WO3, identified by the vertical solid bars (JCPDS file 43–1035). In accordance with the Raman spectroscopy results discussed above, there is a minor additional component of hexagonal h-WO3 present (dashed vertical bars, JCPDS file 85–2460). The crystallites size determined from the width of the Bragg peaks is 13 ± 2 nm. By fitting the diffraction pattern, we found the lattice constants of the monoclinic phase to be a = 0.7297, b = 0.7539, c = 0.7688 with β = 90.91°, and for the hexagonal phase to be a = 0.73242, and c = 0.76624. There are no signs of crystalline TiO2 phases. This suggests that TiO2 is indeed amorphous, which is in agreement with the Raman spectroscopy results discussed in the section above. Figure 2B shows the diffraction pattern of the WO3–TiO2 composite film annealed at 500 °C. It matches with the JCPDS card 43–1035 diffraction pattern of pure m-WO3. The lattice parameters obtained from the fitting of the diffraction pattern are a = 0.7351 ± 0.0002, b = 0.75396 ± 0.0005, c = 0.7712 ± 0.0002, with β = 90.3°. The crystallite size obtained from the XRD data is about 16.7 nm. Although the peaks are similar in Fig. 2B, C, the lattice parameters obtained from the fitting for the sample annealed at 600 °C are a = 0.7351 ± 0.0019, b = 0.7566 ± 0.0019, and c = 0.7724 ± 0.0021 nm, with β = 90° indicating that WO3 is in the orthorhombic phase, with 18 nm crystallites. When the β angle was varied, it resulted in a very large dispersion of the lattice parameters, which suggest that the data obtained from numeric fits are indeed appropriate. Thus, both the Raman and X-ray studies confirm the formation of orthorhombic tungsten oxide in the WO3–TiO2 composite film annealed at 600 °C. However, no anatase TiO2 phase can be seen in the XRD pattern corresponding to the WO3–TiO2 composite film annealed at 600 °C. Generally, Raman scattering is more sensitive than X-ray diffraction to anatase.

3.3 SEM and N2 adsorption–desorption isotherm of the WO3–TiO2 composite thin films

For demonstration purposes, the inset in Fig. 3 shows the cross-sectional SEM image of the porous structure of the WO3–TiO2 layer annealed at 450 °C. It is not possible to distinguish between the WO3 and the TiO2 layers. The thickness of the WO3–TiO2 layer was of 842 ± 50 nm.

Fig. 3
figure 3

SEM cross-section image of the photoelectrochromic device constructed by using a WO3–TiO2 thin film coated on an ITO glass substrate and annealed at 450 °C. The inset is a cross-sectional SEM image showing the porous structure of the WO3–TiO2 layer annealed at 450 °C

Furthermore, the porosity of the WO3–TiO2 layer annealed at 600 °C was examined using N2 adsorption–desorption isotherms which are presented in Fig. 4. The sample exhibits classical type IV isotherms which are indicative of mesoporosity, according to the IUPAC. The pore size distribution curve obtained by the BJH method using the adsorption branch of the isotherm is broad, and is centered at ~15 nm. Also it should be noted that there exists some macro pores above 50 nm in diameter (see inset in Fig. 3B). The BET surface area was found to be ~11.18 m2 g−1 with a pore volume of 0.046 cm3 g−1.

Fig. 4
figure 4

N2 absorption–desorption isotherms with pore size distribution shown in the inset of the WO3–TiO2 composite annealed at 600 °C

3.4 Photochromic application

The mesoporous WO3–TiO2 composite thin films coated on ITO substrate and annealed at 450, 500, and 600 °C were sensitized with a ruthenium based dye, and thereafter used as active electrodes in the construction of photochromic devices. Figure 3 shows the SEM cross-section image of the device constructed by using a WO3–TiO2 thin film coated on an ITO glass substrate and annealed at 450 °C. From bottom to top, Fig. 3 shows the glass substrate, the thin ITO layer (190 nm), the thick WO3–TiO2 composite layer (~800 nm) and the IC layer over the dye sensitized WO3–TiO2 composite layer. In this configuration, as the light (1 sun) is incident on the surface of the ICL, a dye molecule absorbs a photon. Then, an electron is rapidly injected from the excited state of the dye into the conduction band of the TiO2 present in the WO3–TiO2 layer, and diffuses to the WO3. Ionized dye molecules are reduced by I in the ICL according to the reaction: 3I → I3  + 2e. Li ions intercalate into the WO3 such that the charges balance. Because of the injection of electrons, the WO3 is reduced and changes its color from transparent to blue according to the reaction:

$$ \begin{array}{*{20}l} {{\text{WO}}_{3} + {\text{xLi}}^{ + } + {\text{x}}{\bar{\text{e}}}} & \leftrightarrow & {{\text{Li}}_{{\rm x}} {\text{WO}}_{3} } \\ {\text{transparent}} & {} & {\text{blue}} \\ \end{array} $$

As the above reaction is reversible, when another ITO coated glass electrode is applied on the top of the ICL, the device is bleached by applying a reverse potential.

Figure 5 shows the transmittance of the photochromic devices as a function of wavelength for time t = 0 and 600 s. The transmittance of all the devices at t = 0 were nearly equal, and the typical transmittance of the device based on the the WO3–TiO2 composite layer heat treated at 450° C is shown by the solid curve. At t = 600 s, the devices constructed using the WO3–TiO2 composite layers heat treated at 450, 500, and 600 °C show a contrast of 24.9 % (dashed curve + triangle), 35.7 % (dashed curve + stars), and 48 % (solid curve + squares), in the transmittance at the wavelength of 882.4 nm, respectively. This remarkably high transmittance response for the device constructed using the WO3–TiO2 composite layer heat treated at 600 °C is attributed to the nanocrystalline anatase TiO2 embedded in the orthorhombic WO3 matrix. It should be noted that annealing the WO3–TiO2 composite film at 450 °C only produces m-WO3 plus a minor amount of h-WO3 with amorphous TiO2. When this film was subjected to photochromism studies, it exhibited feeble photochromic effect in comparison to the composite layer which was obtained at 600 °C, as evidenced in Fig. 5A. Thus, the key aspect of this work is the formation of nanocrystalline anatase TiO2 embedded in the WO3 matrix, and hence differs in this aspect from the photochromic works reported by Krašovec et al. [39], and by Hauch et al. [23]. They both have reported that the WO3–TiO2 films heat treated at 450 °C were amorphous. Further, Palgrave et al. [46] have reported that the photochromic effect is not dominant if titanium oxide is amorphous in titanium doped WO3 films. They prepared a separate layer of titania and crystallised it by conventional calcination, followed by the preparation of a tungsten oxide over layer. Such a combination of layers exhibited better photochromic properties than the layer of WO3 having amorphous titania, supporting the results presented in this work. The composite WO3–TiO2 film prepared at 500 °C has shown intermediate optical coloration. This indicates, that the degree of crystallization of the TiO2 presente in the composite layer annealed at 500 °C is higher when compared with that of the sample annealed at 450 °C sample, which provides additional knowledge when compared with our previous WO3–TiO2 photochromic studies [47]. Thus, in this article, we demonstrate that the degree of crystallization of titania in the WO3–TiO2 composite layer is critical in its photochromic response. It may be summed that the degree of crystallization of TiO2 increases with annealing temperature, and hence photochromic response of the composite layers follows the order 450 °C < 500 °C < 600 °C.

Fig. 5
figure 5

Photochromic response of the photochromic devices based on the dye sensitized WO3–TiO2 composite layers annealed at 450 (triangle dashed line), 500 (star dashed line) and 600 °C (solid square line) under the irradiation of 1 sun power at time t = 600 s; the transmittance of all the devices at t = 0 were nearly equal, and the typical transmittance of the device based on the dye sensitized WO3–TiO2 composite layer heat treated at 450 °C is shown by the solid curve

From Fig. 6 it is evident that the variation in the transmittance of the device constructed using WO3–TiO2 composite layer annealed at 600 °C changes from 60.2 to 8.95 % at a wavelength of 881 nm, whereas at a wavelength of 621.8 nm the transmittance varies from 52.3 to 32.3 % in 1,400 s. This indicates that the optical modulation of the device in the near IR region is significant with a contrast of about 51 %, whereas in the visible region it is 20 %. Hence, the device response is favorable for the construction of a self-modulating smart window that transmits light in the visible region and blocks the IR part of the spectrum. These results thus demonstrate the importance of nanocrystalline anatase TiO2 in combination with o-WO3 in obtaining a better photochromic response.

Fig. 6
figure 6

The photochromic response of the photochromic devices based on the dye sensitized WO3–TiO2 composite layer annealed at 600 °C as a function of the time of irradiation for wavelengths 621.80 and 882.10 nm

The mechanism of the photochromic coloration of the device constructed using the WO3–TiO2 composite layer heat treated at 600 °C is shown in Scheme 1. As the flat band potential of nanocrystalline anatase TiO2 is −0.1 V and that of WO3 is 0.5 V, WO3 has a lower energy for the conduction band minimum than TiO2 [48]. Hence, the electrons injected from the dye into the conduction band of TiO2 can easily diffuse into the conduction band of WO3. From optical transmission studies, and using the Tauc relation, the band gap of the o-WO3 layer was found to be Eg (WO3) = 3.7 eV and that of TiO2 present in the o-WO3 layer, Eg(TiO2) = 3.8 eV [49, 50]. The obtained Eg value for o-WO3 is higher than that of bulk WO3, which is 3.2 eV [51]. Since the energy maximum of the valence band of the o-WO3 layer is lower than that of TiO2, the recombination of the charge carriers that diffuse into o-WO3 is prevented. o-WO3 acts as an effective charge separating center, owing to its nanocrystalline nature. As the electrons diffuse into o-WO3, Li+ from ICL also diffuse into o-WO3, due to charge compensation, and o-WO3 changes its color from transparent to blue.

Scheme 1
scheme 1

Photochromic coloration mechanism of the device constructed using the WO3–TiO2 composite layer heat treated at 600 °C

4 Conclusion

A two stage sol–gel process was adopted to prepare mesoporous WO3–TiO2 composite thin films on ITO coated glass substrates. The first stage involves dip coating of a tungsten oxide film using a tungstic acid sol in the presence of ORMOSIL as a templating agent, followed by annealing at 450, 500, or 600 °C for 1 h, resulting in the formation of a mesoporous WO3 thin film. In the second stage, the mesoporous WO3 film was dip coated with a titanium alkoxide based ethanol solution containing ORMOSIL, followed by another annealing step at 450, 500, or 600 °C. Raman and XRD studies show the formation of an orthorhombic WO3 thin film with embeded anatase TiO2. Raman and XRD studies show that annealing of the films at 450, and 500 °C resulted in mixed hexagonal (h) plus monoclinic phases, and pure monoclinic (m) phase of WO3, respectively, though, the degree of crystallization of TiO2 present in these composite films was not evident. The composite film annealed at 600 °C, however, consists of orthorhombic (o) WO3 and anatase TiO2. It was found that the nanocrystalline anatase TiO2 phase plays an important role in stabilizing the o-WO3 matrix. The mesoporous WO3–TiO2 composite films, after being sensitized with a ruthenium dye, were used as active photoelectrochromic electrodes in the construction of photoelectrochromic devices. The device constructed using the WO3–TiO2 composite layer heat treated at 600 °C showed an optical modulation of 51 % in the NIR region and 20 % in the visible region, whereas the devices based on the composite layers heat treated at 450, and 500 °C showed only a moderate optical modulation of ~24.9, and 38 %, respectively. This remarkable difference in the transmittance response is attributed to nanocrystalline anatase TiO2 embedded in the orthorhombic WO3 matrix of the WO3–TiO2 composite layer annealed at 600 °C.