Mansfield Town have been drawn away to 2008 finalists Cardiff City in the third round of the Emirates FA Cup.
We will travel to face the Bluebirds, who currently lie second in The Championship, in early 2018.
Stags have reached the third stage of the competition for the first time in five years, when they took on Premier League side Liverpool in 2013.
Manager Steve Evans' men have progressed to the third round thanks to a 3-1 win away to Evo-Stik side Shaw Lane in the first stage, before Sunday's 3-0 win over Guiseley in the second phase.
The tie will be played on the weekend of Saturday 06 January 2018. A confirmed date and ticket prices will be confirmed in due course.