The power of compounding works better the longer you're able to keep your money invested. If you have several decades left before you retire, investing just $300 a month at a 10% annual rate of return for 35 years would grow that small starting amount into just over $1 million. And with more brokers allowing investors to buy fractional shares, you don't need to feel limited if the stock you want to buy trades for a higher price than the cash you have on hand.

Past performance is no guarantee of future results, but investing $100 a month in each of these three dividend-paying stocks has a good chance of making you a millionaire if you have a few decades.

A person analyzes a stock.

Image source: Getty Images.

1. Aflac

The first stock to consistently dedicate $100 a month to buying is supplemental insurer Aflac (AFL 0.63%). Over the past 10 years, Aflac shareholders who have reinvested their dividends have gained 14.1% on an annual basis -- just ahead of the S&P 500's 13.7%. A one-time $1,000 investment 10 years ago would have nearly quadrupled to $3,700 during that time with reinvested dividends.

And unlike the S&P 500, which appears to be somewhat richly valued today at a forward P/E ratio around 22, Aflac is trading at a forward P/E ratio of just 12 at recent prices. What's more, Aflac is priced at a moderate discount to the industry average forward P/E ratio around 14. This is despite the fact that Aflac is the only stock in its peer group that has raised its dividend every year for nearly four decades straight, which comfortably makes it a Dividend Aristocrat.

Analysts expect that steadily growing demand for Aflac's life, disability, cancer, dental, and vision insurance product offerings will lead to 4% annual growth in earnings per share (EPS) over the next five years. This actually seems like a low estimate based on the company's 10% annual earnings growth rate in the past five years. Not to mention the fact that Aflac will soon be earning higher income on its $146 billion investment portfolio when the Federal Reserve begins raising interest rates later this year.

And while shareholders sit on their shares of Aflac, they are awarded with a market-beating dividend yield of 2.5%. And with a relatively low payout ratio of 30.2%, Aflac should have the ability to consistently grow its dividend in the years ahead. These factors make Aflac a great dividend stock to buy for the long haul.

2. General Dynamics

The next stock to allocate $100 a month to is defense contractor and aerodynamics stock General Dynamics (GD -3.97%), which has raised its payout for 30 consecutive years. In the past decade, General Dynamics has generated 14.3% annual returns with dividends reinvested. A single $1,000 investment in General Dynamics at this time in 2012 would have grown to nearly $3,800 by now with reinvested dividends.

Since the dawn of time, human conflict between countries and territories has, unfortunately, been a constant. The onset of the Information Age hasn't changed that -- it just changed the way that battles are fought. As the largest government information technology (IT) vendor, General Dynamics will be crucial to the U.S. government's efforts of defending itself against the threat of cyberattacks in the long term. The U.S. recently raised defense spending 5% to $768 billion.

The bipartisan recognition of the need for higher defense spending to keep up with geopolitical foes should bode well for General Dynamics. That's why analysts are forecasting General Dynamics' EPS growth will accelerate from 7% annually in the past five years to 9% through the next five.

Investors can lock up General Dynamics' 2.2% dividend yield at a forward P/E ratio of just 17 at recent prices, which is arguably a reasonable price to pay for the stock's growth potential. That's especially true given that General Dynamics' payout ratio will likely be in the low 40% range this year, which gives the stock plenty of room for future dividend growth.

Remember what I said above about fractional shares? A hundred-dollar investment will only buy about half a share of General Dynamics at recent prices, so make sure your broker allows for trading fractional shares.

3. Amgen

The third and final stock to set aside $100 each month to buy is pharma stock Amgen (AMGN -0.19%). In the past 10 years, Amgen has delivered 16.2% annual returns before considering dividend reinvestment. A $1,000 investment 10 years ago would have matured to nearly $4,500 without even reinvesting dividends.

And Amgen's tremendous returns over the past decade look set to continue. This is due to the expectation that global pharmaceutical spending will plow higher from $1.27 trillion in 2020 to $1.60 trillion by 2025, which should act as a rising tide that lifts Amgen's proverbial boat. Along with Amgen's track record of innovation, this is why analysts are predicting 5% annual earnings growth in the next five years for the stock.

Since Amgen's dividend payout ratio will be around 43% for this year, the company should be able to build on its 10-year streak of raising its dividend. Better yet, the stock's solid growth prospects can be purchased at a sensible forward P/E ratio of just 13. Pairing Amgen's mid to upper-single-digit annual dividend growth potential with its market-smashing 3.3% dividend yield makes the stock an attractive long-term pick.