The advice of just taking him back to bed and tucking him in is good and textbook. However, some children haven't read the sleep books and you have to find alternative solutions if they don't work.
I had this problem with my 2 yr old and we would be in and out, in and out every night and for weeks - so it did not work for us. What I had to do, contrary to all the sleep books, was stop his daytime nap, so he was completely and utterly knackered at bedtime and couldn't get out of the bed if he'd wanted to!! This got him into a good pattern, so now he has the odd daytime nap (we are 7 months on now) but still goes nicely to sleep as he has got used to the routine.
I doubt whether this advice is any good to you as your child probably doesn't have a nap at 3 yrs anyway but you need to do what you have to! If that means giving him a later bedtime, putting a stairgate on the bedroom door (if you stay upstairs, so he knows you're there, so won't be scared - eventually he'll go back to bed - or fall asleep where he stands!) then do it. Try everything you can but try it for some weeks.
Hope this is helpful to you! My own child now goes to sleep beautifully but gets up several times during the night and I am yet to solve this!!