What are two of the best criteria for making money in investing? Buy stocks that are priced attractively, and buy stocks that pay you to own them through dividends.

Three stocks, in particular, meet those two criteria and then some right now: HP (HPQ 0.11%), International Business Machines (IBM) (IBM -8.25%), and Valero Energy (VLO 0.08%). Here's why these are dividend stocks you can buy on sale.

dividends tab on twig next to roll of $100 bills

Image source: Getty Images.

HP

HP is one of the granddaddies of the tech world. The company literally started in a garage back in 1939, and now claims a market cap topping $33.5 billion. HP's dividend currently yields 2.66%. Although the tech giant cut its dividend in late 2015, HP appears to be in great shape to keep dividends rolling with a payout ratio of less than 38%.

The stock is a bargain right now, as well. Shares trade at 11.4 times expected earnings -- nearly 50% below the industry average. That's actually higher than HP's valuation over the last several years, but there's a good reason for it: The company's prospects are brighter.

While some might have written off the PC industry, HP actually increased PC shipments last quarter. The company saw especially strong growth in sales of notebooks and workstations. HP's printer business is also turning things around, posting a respectable 6.3% year-over-year revenue increase in the second quarter. With its business improving, a solid dividend, and low valuation, HP appears to be a great one for investors to consider. 

IBM

If HP is a granddaddy of technology, IBM might be considered a great-granddaddy. IBM was founded in 1911 after a merger of three companies. It paid its first dividend two years later and has kept them coming ever since. IBM's dividend yield now stands at 4.16%.

IBM stock is also attractively valued. Shares trade at 10.6 times expected earnings. This level is definitely on the low end historically for IBM. However, the company has faced significant headwinds recently, with revenue falling for 21 consecutive quarters. Unfortunately, the bad news isn't in just one area: All five of IBM's business segments reported year-over-year revenue declines in the last quarter.

Don't count out IBM, though. The company remains a leader in several key technologies, including artificial intelligence, blockchain, cloud computing, data analytics, and IT security. In addition, IBM is launching a new powerful mainframe, System z13, which should provide a boost to revenue.

IBM has hit rough patches in the past and always adapted successfully. I expect this technology pioneer will continue to do so. 

Valero Energy

Valero Energy is the young whippersnapper of these three stocks. The company was founded in 1980, although its roots date back earlier than that. Valero now is the largest independent refiner in the the world and pays out a nice dividend, yielding 3.85%.

The company's shares trade at less than 14 times expected earnings. What makes Valero's valuation even more appealing is its growth prospects. Wall Street analysts project the company will increase earnings by 20% annually over the next several years.

Valero appears to be rock solid financially. There aren't any yellow flags with its balance sheet: Valero has a cash stockpile of more than $5 billion with net debt of $2 billion. It's generating strong cash flow. And the company's revenue and earnings are growing.

Valero's fortunes are obviously linked to the broader oil market, which can make the stock volatile. Over the long run, though, this stock appears to be a good pick for investors who seek reliable dividends and the opportunity for growth.