Everyone has deadlines which keeps us motivated to work. Personally I can not seem to work without one. The problem is that when a deadline approaches quality seems to decline. You start coding faster, testing less, and missing some of the minute points of spec in my experience. Although it is semantics I like to have a target window for a task that allows the developer to feel they have a bit of room to move other than a set date in time.
Clients and deadlines are when things get ugly. When something does not get delivered by that date then you are in trouble. I do give my clients a completion date for their problem but if I feel that there is a delay I tell them so that they are prepared when it is not ready for the initially expected date. For most projects I recommend to give a deadline past when you think you will have it done. If something is delivered a little early the client is usually happier (if it is months early they will feel ripped off though).