Up until recently, I enjoyed going into work most days. Lately, not so much because of feeling underappreciated and underpaid. See the software engineer seeks feedback asking for raise for details, if curious.
As a software engineer, creating software to help other people be better at x, y, and z is a large factor in my work enjoyment. Also, collaborating with co-workers, clients, and partners. For me, I sometimes have sleepless nights because I keep thinking about work, how much work there is to do, and how it'll be tackled.
To me, how much do you dread work and why are key questions. At another job, I was so stressed and unhappy that I had many sleepless nights and it had a very negative impact on my quality of life. My relationship with my wife, family, and friends became strained and my performance at work declined. This led to more stress and a seemingly perpetual downward spiral. After months of this and trying different options to resolve the stressors, I had enough and was done without another job. It took me about a month of just relaxing to unwind enough before I felt comfortable looking for another job which only took a month to find. Having savings to live on was awesome during that time because I didn't worry about finances and could have gone for more months without worry. I actually considered delaying the job search longer but decided not to because I thought that would make me look more undesirable.
Reasons why I've dreaded work in the past are bad bosses, unenjoyable technology being used, and company culture. Switching teams to work for other bosses and other projects has worked successfully. For me, sometimes getting another job was the best option.