I write out my goals, both goals for my own "career", and goals for the job/company I am with at the moment, and I break them down into short (say less than 1 year) and long term (within 5 years).
Then, I try to fit those pieces together so that not only am I growing as a professional, but I am also moving my company / group forward in some way at the same time. For example, I want a particular certification. I have come up with some projects at work that I can do that will utilize that cert. I justify that to my boss, I work on the project and cert, do good work, and when I seek a raise, I now have results that I can use to demonstrate my actual financial value.
By thinking strategically like that, I find I'm much more motivated to get solid work done at work, and not mess around. Occasionally, I do lose focus, we all do, but when I look at my goals, it helps me remember why I'm doing what I'm doing.
Another motivation that I use is that I like having a more clear delineation between work and home. I want my free time to be free time. I make that clear to my boss and my team, and then I proceed to bust my ass at work to make sure that I keep on top of everything and don't need to bring work home all the time. Being an example to my team helps a lot. They know I'm not going to spring some last minute BS on them with weekend work or something as long as they turn in a solid work week.
Finally, cut the dead weight. I hate it when someone is a slacker because it takes me forever to figure out why they screwed up their portion, and then fix it. . . instead of just doing it right the first time, and keeping me informed during the process of any problems. Procrastinating and botching it at the last minute is not acceptable. It also drags down morale of every other employee when they have to carry the weight of a slacker in the team. Get the slacker out, it will demonstrate to good employees that you are committed to them, and they'll turn in a good performance more consistently. That leaves me with more time to be productive, rather than spending it all fixing crap at the last minute.