basically since January of 2013. There have been a few pullbacks but generally the direction has been up. If you had pulled your money out waiting for the market to dip back below previous market highs, you would have missed out on ~97% returns.
Lesson learned: do not try to time the market. I recommend dollar cost averaging. You put X dollars into the market each month. When the market goes up, your dollars will get you less shares. When it goes down, your dollars will get you more shares. So you're naturally grabbing up more shares as the market gets cheaper and less as it gets more expensive. Also keep in mind, if you need a specific amount of money within less than ~1 year, don't put it in the market. Just let it sit in a high yield savings account (WealthFront offers 2.57% returns right now for a cash account) and you wont have to risk losing that money you'll need within the year.