Facile and green sol–gel method was used to synthesize carbon-containing titania nanopowder, and diethanolamine (DEA) was used as the in situ carbon source. The titania gel was heat treated at temperatures ranging from 300 to 700 °C. X-ray diffraction (XRD), thermal analysis, and Raman spectroscopy reported no crystalline phase at <325 °C. Crystallization of the anatase phase with traces of brookite phases was observed at T > 325 °C, followed by a transformation to anatase/rutile in the range of 400 °C < T ≤ 650 °C. Finally, the complete phase transformation to the rutile phase occurs at temperatures of T > 650 °C. High-resolution electron microscopy (HREM) micrographs confirm the coexistence of anatase and rutile nanocrystals and amorphous carbon clusters in the composite samples. Chemical element analysis via X-ray photoelectron spectroscopy (XPS) indicated nonstoichiometry in the O/Ti ratio, the presence of (Ti3+) oxidation state, and elemental carbon. Thermogravimetric (TG) measurements are the most accurate method to measure the carbon content in samples. UV-vis spectroscopy demonstrated considerable enhancement in the optical absorption properties and electronic structure of prepared samples compared to the pure anatase and rutile. This enhancement is strongly correlated with the structure and composition of prepared samples and consequently depends on the preparation method as well as conditions. Innovative features such as self-cleaning action was demonstrated in carbon containing titanate nanocomposite.