When you are not riding your bike, you should keep it securely locked. Make sure you use a good lock or two and use them effectively.
D-locks are sturdy, but consider using a cable lock as well to secure any parts of the bike which are quick-release, such as the saddle or front wheel.
Use locks to secure the frame, spokes and bike stand, ensuring there is little room for manoeuvre, to make it difficult for thieves to insert their tools.
Make sure the lock is not touching the ground, where it can be smashed with a sledgehammer.
Finally, make sure you are attaching your lock to an immovable object, such as a sturdy bike stand or railing.