(CNN) A number of Russian-linked Facebook ads specifically targeted Michigan and Wisconsin, two states crucial to Donald Trump's victory last November, according to four sources with direct knowledge of the situation.

Some of the Russian ads appeared highly sophisticated in their targeting of key demographic groups in areas of the states that turned out to be pivotal, two of the sources said. The ads employed a series of divisive messages aimed at breaking through the clutter of campaign ads online, including promoting anti-Muslim messages, sources said.

It has been unclear until now exactly which regions of the country were targeted by the ads. And while one source said that a large number of ads appeared in areas of the country that were not heavily contested in the elections, some clearly were geared at swaying public opinion in the most heavily contested battlegrounds.

Michigan saw the closest presidential contest in the country -- Trump beat Democratic nominee Hillary Clinton by about 10,700 votes out of nearly 4.8 million ballots cast. Wisconsin was also one of the tightest states, and Trump won there by only about 22,700 votes. Both states, which Trump carried by less than 1%, were key to his victory in the Electoral College.

The sources did not specify when in 2016 the ads ran in Michigan and Wisconsin.