If you work in a small company where everyone knows everyone then you get to be close to the people you work with and pretty much know what they like and dont like.
If the company is larger then you dont get to know everyone well but then you wouldnt be buying a gift for some one that you dont know very well.
You dont want to go over board on a a gift and spend a lot of money here. Some places like at Christmas you will draw a name of a person to buy for and there is a price limit set.
If they dont do this at your place of work it is a good idea to suggest and maybe have each person that participates write down things they like on the piece of paper that will be drawn.
There may be others that you work with that you have become good friends with but remember these gifts will be given at work. If they are a good friend and you want to give them a personal gift, give it to them outside of work, unless it is some thing that everyone can see.
A few ideas I can think of are coffee mugs with their names on them. Inside you can put flowers, flavored coffee packets, candy or whatever the person might like.
You may want to give a simple fruit basket, or even a gift certificate for a nice lunch at their favorite place to eat.
A nice pen and pencil set is something one can never have too many of and is another good choice.
If you know their musical taste a cd can be a good gift.
If they read a lot a certificate to a book store or a book itself if you know they have been wanting a certain one.
I would not go over$25.00 for a gift for a co-worker unless a higher limit is set and agreed to. You can get a lot of useful things in that price range.
Make a list of all the things you would like to get in whatever price range you determine and go from there as most people would have similar lists.
Happy shopping!