One way to deal with procrastination is to bargain with it. When you get stuck, stop and ask yourself, “Self, what do you need?”
Typically, your demands aren’t too outrageous: maybe you need a walk, or a run, or you need to punch something (protip: punching bags are better than walls.) It could be that you need to get some mindless browsing out of your system, in which case you might want to set a timer. If you need a nap, take a nap. If you need coffee, brew some.
Give yourself whatever you need; then, get back to work.
I’m writing this while reclining in a chair because I was getting nowhere at my desk. That may not sound like a big deal, but it’s the difference between getting a post done and studying the walls while fighting the urge to get online.
In other words, be kind to yourself.