The number one way I burn myself out is through forcing myself to work as a means of accomplishing something. The idea of just sitting down and starting to type seems like a good method of increasing output, but does not mean that anything valuable will be produced. I will, almost assuredly, leave the experience with less energy than when I started.
The difference between accomplishing something and having effectively null output is clarity. Clarity is also often the rarest of commodities when attempting to build something. Clarity of why or how or even what to solve. All of these can be near impossible to find because clarity is the sum of experience and intentionality which both take time to develop.
Intentionality is being purpose-driven. It is what narrows your scope until something becomes possible. It allows you to prioritize and quickly work through a series of problems because solutions also have intent. A good solution has to know what its problem is in order to effectively make a difference.
Experience tells you how to accomplish a goal and helps you sort through what is or isn't a good solution. We go to school to experience problems and start to internalize how to approach and solve them in the future. We iterate through problems to build experience to help us solve them again the 10th or 100th or 1000th time we encounter something similar. Experience is pattern recognition. It's learning how to make decisions quickly, instinctively, innately.
Until you find both of these, clarity is impossible and motivation becomes scarce. Output becomes misaligned to its purpose, or may lack purpose altogether. Output for no reason hurts you more than just the loss of time.
You lose energy and passion and drive.
You feel bad about yourself, your work, your ability.
You burn out.
There is an easy solution, though, and it's other people. If you're building by yourself, talk through your idea with others until you learn what the core of the problem is and can approach it intentionally. Talk to people who have solved pieces of your problem before and use their experience to find a path to a solution. If you're working with others, use their perspective to your advantage.
Take others' experience to build solutions. Use their problems to find intent. Build your clarity on their foundation.