Abd Al-Qādir had begun using northeastern Morocco as a refuge and a recruiting base as early as 1840, and French military movements against him heightened border tensions at that time.
By early 1844 French troops had constructed a fortification at Lalla-Maghnia, the site of a Muslim shrine near Oujda, and clearly not within territory traditionally claimed by the Ottoman Regency of Algiers.