Numerical simulations based on the fundamental laws of quantum mechanics lead to invaluable insights into the microscopic behavior of molecules and materials. In the past decades, quantum mechanical simulations are becoming an increasingly important component for chemical and materials science and industry. In this dissertation, I will present several advancements in the development and application of quantum mechanical methods for first-principles simulations of molecular and condensed systems. First, I will present a finite-field algorithm for evaluating density response functions based on density functional theory calculations under finite electric fields. The finite-field algorithm enables accurate many-body perturbation theory calculations beyond the random phase approximation. Based on the finite-field approach, we demonstrated GW and Bethe-Salpeter equation calculations of excitation energies of molecules and materials beyond the random phase approximation. Next, I will present a quantum embedding theory for the study of strongly-correlated electronic states in condensed systems. The quantum embedding theory is capable of constructing a simple, effective model for a selected part of a physical system, where the rest of the system acts as a dielectric screening media that renormalizes the electron-electron interactions in the effective model. We demonstrated quantum simulations of effective models using both classical and quantum computers. This development helps bridge the gap between the systems sizes required to study realistic materials science problems and those that can be tackled with the resources of near-term quantum computers. In addition to electronic properties, I will present a novel approach to predict certain spin properties (e.g. the hyperfine coupling) for paramagnetic systems using density functional theory calculations on finite-element basis sets. We demonstrated all-electron finite-element DFT calculations of spin properties for both finite and periodic systems. We showed that the results of such calculations can be systematically converged with respect to the basis set size. This development enables robust all-electron calculations of spin properties for paramagnetic molecules and materials. Finally, I will present several applications of first-principles methods for the study of spin-defects in semiconductors. Spin-defects in semiconductors are promising physical realizations of quantum bits for quantum information technologies. We present a number of theoretical predictions on various properties of spin-defects that are important for their operation as quantum bits. In particular, we applied density functional theory and many-body perturbation theory to predict the stability and excitation energies of several novel spin-defects in silicon carbide and aluminum nitride; we applied the quantum embedding theory to predict the strongly-correlated excited states of group-4 vacancy centers in diamond; we applied DFT and group theory to construct a microscopic theory for spin-phonon coupling of divacancy defects in silicon carbide; we performed quantum dynamics simulations using the cluster correlation expansion method to predict the coherence time of divacancy spins in the environment of other electron spins and nuclear spins. These studies greatly expanded our understanding of various physical properties of existing spin-defects as well as novel ones, and provided important guidance for the experimental realization and manipulation of these spin-defects as solid-state quantum bits.