One of the most significant challenges involved in efforts to understand the equation of state of dense neutron-rich matter is the uncertain density dependence of the nuclear symmetry energy. In particular, the nuclear symmetry energy is still rather poorly constrained, especially at high densities. On the other hand, detailed knowledge of the equation of state is critical for our understanding of many important phenomena in the nuclear terrestrial laboratories and the cosmos. Because of its broad impact, pinning down the density dependence of the nuclear symmetry energy has been a long-standing goal of both nuclear physics and astrophysics. Recent observations of neutron stars, in both electromagnetic and gravitational-wave spectra, have already constrained significantly the nuclear symmetry energy at high densities. The next generation of telescopes and gravitational-wave observatories will provide an unprecedented wealth of detailed observations of neutron stars, which will improve further our knowledge of the density dependence of nuclear symmetry energy, and the underlying equation of state of dense neutron-rich matter. Training deep neural networks to learn a computationally efficient representation of the mapping between astrophysical observables of neutron stars, such as masses, radii, and tidal deformabilities, and the nuclear symmetry energy allows its density dependence to be determined reliably and accurately. In this work, we use a deep learning approach to determine the nuclear symmetry energy as a function of density directly from observational neutron star data. We show, for the first time, that artificial neural networks can precisely reconstruct the nuclear symmetry energy from a set of available neutron star observables, such as masses and radii as measured by, e.g., the NICER mission, or masses and tidal deformabilities as measured by the LIGO/VIRGO/KAGRA gravitational-wave detectors. These results demonstrate the potential of artificial neural networks to reconstruct the symmetry energy and the equation of state directly from neutron star observational data, and emphasize the importance of the deep learning approach in the era of multi-messenger astrophysics.