Everybody has heard stories that feature an inventor who unwittingly sold out for pennies an idea that would go on to make millions. In some of these cases, it is just really difficult to determine the economic potential of your invention and this makes its value easy to underestimate. In most cases, it is preferable to license rather than sell your patent and by now the reason should be easy to understand. If you license your invention, you maintain control over it. You can constrain that license to a span of time or to a particular way of use. If you are lucky enough to see the market for your invention grow substantially, licensing will allow you to extend use rights to a variety of interested parties, thus making your income potential proportionately greater than if you had sold it outright since obviously that sale can happen but once.
Basically, if you sell the invention outright, you can expect to get just the net present value of the invention. Whereas, if you license it, you can get royalty returns for years to come and over that period of time you may actually end up making a lot more money, especially if the market is proven. In fact, some of the most successful people in the world are individual inventors who have taken their ideas and built successful businesses through licensing revenue.
That being said, another good option is to make the product yourself and manufacture and sell it, or if it happens to be a service, build the service and market it yourself. That is also a good way to monetize your idea. But absent that, if there are potential companies who want to license it or buy it, you should probably rally think about licensing it rather than selling it outright. Depending on your individual situation, you might consider selling it, but usually when that happens you sell it for much larger a discount than its future value if it becomes successful.