This could be a number of things, really. Different ages may require different approaches.
My first suggestion, is to make sure your child doesn't have any kind of hearing loss! I know of a 4 year old boy who was always getting in trouble for not listening. He seemed to ignore, or would only respond when his mother yelled at him. Problem was this, when she thought he was ignoring her, he usually had his back to her, and the only reason he did respond when she yelled was because that is when he could actually make out what she was saying! Worth a check up if in doubt.
Sometimes this can be a sign of inconsistencies. This may be a reflection of how things are handled at childcare, for example "if I ignore it, it will go away or someone else will do it". It may be a "game" to push buttons. It may be a cry for attention, because to a child even negative attention is attention. It could simply be that he is unsure how to proceed.
That being said, children need clear boundaries and above all be consistent! If the rules change from one time to the next (pick up your toys today, because someone is visiting, but leave them out the rest of the time) the child may not see the need to act. If the child is being defiant, then I would try these steps: FIRST - make sure they are not absorbed in something and tuning other things out, such as being really focused on a game or movie. SECOND - ask them to repeat what you said, this assures that they heard you. If they can't tell you, then ask them to look at you so you know they are listening and then have them repeat your words. THIRD - ask them if they have any questions if they need clarification on directions. FOURTH - give them time to react. Some kids will do and get it over with (DREAM!), some kids need a bit to think it through, some kids feel the need to finish something they might be in the middle of, and/or some kids need a time limit (I need it done in the next "5 minutes" or "half hour" or "before Dad gets home"). After this if it is still an issue, discipline may be necessary. Discipline doesn't have to mean a spanking! It can mean sit until you are willing to listen and do it, and if action isn't achieved maybe losing a favorite activity or item (maybe just until it is done, or - depending on age - for an hour per year of age, a day per year of age, or a week per year of age), just make sure "the time fits the crime" and is age appropriate. Sometimes a simple promise of your time in return will work, "if you can get this done now, we can go to the park later".
One last thought, if directions are given just for the sake of parent laziness (go and get me the chips out of the kitchen), please keep in mind, that consideration begets consideration. 'Enuf said! Keep some humor in it if you can, be flexible when possible, and be consistent. Good luck!