This region has been a wrestling mat for native, Central Asian, and Iranian powers and people throughout the study period. In 1 CE, It was ruled by local aristocrats, many of whom could trace ancestry to Alexander's Macedonians. There seems to have been a constant Persian (Iranian) cultural presence in Afghanistan dating back before Alexander's career, that persists to this day, especially in Afghanistan's northwest, including the city of Herat. In northern Afghanistan, the dominant ethnic group is the Uzbeks, a Turkic nationality centered in Central Asia.
50: A mysterious group from Xinjiang (Western China today) called the Yu-Chi established the Kushan Empire. The Yu-Chi also conquered and ruled Northern India. Thus, if your ancestors were in Afghanistan in 500 CE, their ancestors could have lived anywhere in the Kushan Empire or in Xinjiang in 1 CE. The Yu-Chi formed the aristocracy until...
5th century: Around 400, Central Asian/Mongolian nomads variously called White Huns, Hepthalites, and Huna, (presumed related to the Huns who invaded Europe at the same time) invaded and established themselves permanently as an aristocratic class. They also conquered the Indus-Ganges, but their rule was backward, not a cosmopolitan empire that was conducive to commerce in goods or genes.
6th century: The Sassanian (Persian/Iranian) Empire annexed Afghanistan to the Persian heartland of Iran, breaking the power of the White Huns. This was a cosmopolitan Empire and the annexation probably facilitated considerable gene flow. If your ancestors were in Afghanistan in 1000 CE, their ancestors could have come from anywhere in the Sassanian Empire in 1 CE. But watch out. The Central Asians were hardly finished.
8th century: The expanding Muslim Umma made it to Afghanistan, replacing the Iranians with a tiny Arab ruling class. Numerically they would have been a tiny minority, so unless your family folklore asserts that you have Arab ancestry, you probably don't.
962: Ghaznavid Turks (also Muslims) from Central Asia take over as the new Aristocracy
1140: Ghorid Turks from Central Asia oust the Ghaznavids in turn. The Ghorids were like the White Huns in that they went on to conquer most of Northern India. They did it in a much more civilized way, bringing North India into the Islamic Umma. Thus, if your ancestors were in Afghanistan in 1490 CE, their ancestors could have come from anywhere in Afghanistan, Northern India, or Central Asia in 1000 CE.
1219: Genghis Khan takes over Afghanistan on his way to conquer Iran and Iraq. Afghanistan becomes part of the diverse Mongol Empire. Now a Mongolian upper class rules. The Mongols were noteworthy for promoting an excellent communication system and for recruiting talented people from all over thier empire for important posts. Thus, if your ancestors were in Afghanistan in CE 1490, they could have been from anywhere in the Mongol empire in CE 1000. Particularly if you trace your ancestry to the Hazara nationality, who are widely believed to be descended from the Mongols.
In 1350, as the Mongol Empire disintegrated, the Ghorids resurfaced, kicking out the Mongols, but their days were numbered.
1370 Like Iran, the Indus-Ganges region was hit by the Timurid Turkic invaders under Timur (Tamerlane) who supplied yet another upper class of Central Asian origin.
1504 - The Mughals (= Moguls = Mongols) invade from Central Asia. Like the Timurids, they were Turkic. Of all the Central Asian conquerors, they were the most successful, conquering Northern India. They established the Mughal Empire, which retained cohesion until the mid 18th Century and added most of Southern India to its heartland in Afghanistan and Indus-Ganges. The upshot is that if your ancestors were in Afghanistan in 1800 CE, it's possible that their ancestors were anywhere in the Mughal Empire or in Central Asia or Mongolia in 1490.
16th through 18th centuries. The Mughals were eventually replaced by an indigenous aristocracy. Regardless of who was in charge, Afghanistan was in regular conflict with Persia, providing regular opportunities for the movement of people and genes.
More recently, the British and Russians have had their brief opportunities to throw their genes into the interesting Afghani mix.