It goes to the account you have registered at your broker. It's a good idea to reinvest it into the stock market, that is where compound interest comes into play. A lot of companies also offer DRIPs, dividend reinvestment plans, where the cash dividend is automatically converted to new shares.
Yeah, I am really nervous about tax time next year. This year is my first year of serious investing, and already I have made some short term gains that will have to be paid next year. Next year might be the first time I pay someone to do my taxes!