There's a great post in the sticky section of this forum that gives advice on doing a home detox. The main thing I got from it is to plan in advance, and start taking vitamins and other supplements a week or so before you start withdrawaling.
As for how long you feel bad, i think it depenRAB on how long you've used opiates, how high of a dose you were on, the frequency of use, your age and general health. I know I disagree with Yossarian22 that withdrawal neeRAB to be a bad experience. I think the worse it is, the less likely you're going to be successful, since any addict knows the quickest way to relief, and that's why you're an addict, causing you're always searching for that "relief." Also, think how many people would try kicking if it were easier. (Suppose 50,000 people try it a year under current harsh conditions, and 10%--about the current treatment industry success rate--are successful--that's 5000 addicts off opiates. If withdrawal was painless and 150,000 people tried it per year, even if the success rate fell to half--5%--then 7,500 addicts would be off opiates.)