Aluminum antimonide (AlSb), a semiconductor compound, finds its applications in optoelectronics because of its tunable bandgap and promising properties achieved by tailoring suitable dopants. To explore the effects of doping, thin films of pure AlSb and 10% magnesium (Mg)-doped aluminum antimonide (MgAlSb) were synthesized through compound solution deposition on a glass substrate using a low-cost chemical bath deposition (CBD) technique at varying bath temperatures with deposition time intervals ranging from 60 to 180 min. Optical microscopy was used to evaluate the surface roughness and morphology of the synthesized films, revealing the surface roughness and thin film uniformity at different deposition times. The structural characteristics of AlSb and Mg-doped AlSb thin films were further examined using the X-ray diffraction technique, which validated the formation of AlSb and Mg-doped AlSb thin films. This research enables large-scale low-temperature deposition for a variety of conceivable applications in the coatings, materials penetration, energy, and photonic sectors due to the novel properties of this material.