Having a routine is important.
Additionally, here are a couple of things that you might consider hacks that have worked for me:
1) Front-load your day - I start my day at 4am and I start work immediately. This has a couple of benefits. For me I know I am most productive the first half of my day. Starting early eliminates a long list of distractions and interruptions simply because no one else is up to bother me. Plus, if I find myself dragging between 4pm and 6pm I don't feel guilty about cutting out because I have already put in a pretty solid day overall. This is something I read not to long ago that validated what I was already doing: https://news.ycombinator.com/item?id=12346307
2) Walk - Any time I am feeling distracted or stressed I take a walk outside. It reboots my mind and I come back refreshed. If something was eluding me before the walk it typically reveals itself quickly after returning from the walk.
3) Diet - This is from my response to this post (https://news.ycombinator.com/item?id=12684180): "In order of volume and priority...Coffee, leafy greens(in all forms, especially cabbage - all types, kale, napa, green, etc.) and protein in all forms, diversity is important, animal and vegetable sources.
I mix in other fruits and vegetables for flavoring and variety. Also, I eliminated salt and that relieved my stress in a significant, noticeable way.
I start my day at 4am, if I eat heavier, carb-based items, I notice a crash somewhere around 3 or 4 pm and the last few hours of my day are a struggle. If I stick to what I listed above, I power through the afternoon and feel more balanced when I end my day."