Self-oscillation is a phenomenon studied across many scientific disciplines, including the engineering of efficient heat engines and electric generators. We investigate the single electron shuttle, a model nanoscale system that exhibits a spontaneous transition towards self-oscillation, from a thermodynamic perspective. We analyse the model at three different levels of description: The fully stochastic level based on Fokker-Planck and Langevin equations, the mean-field (MF) level, and a perturbative solution to the Fokker-Planck equation that works particularly well for small oscillation amplitudes. We provide consistent derivations of the laws of thermodynamics for this model system at each of these levels. At the MF level, an abrupt transition to self-oscillation arises from a Hopf bifurcation of the deterministic equations of motion. At the stochastic level, this transition is smeared out by noise, but vestiges of the bifurcation remain visible in the stationary probability density. At all levels of description, the transition towards self-oscillation is reflected in thermodynamic quantities such as heat flow, work and entropy production rate. Our analysis provides a comprehensive picture of a nano-scale self-oscillating system, with stochastic and deterministic models linked by a unifying thermodynamic perspective.