An idea: avoid the worst part of the troubles in Andalus around the first half of the 11th century. More specifically, avoid Cordova being sacked.
That gives you a stabler, agriculturally stronger Andalus, though probably the Umayyad Caliphate is doomed anyway. You'll probably butterfly away both the Almoravids and the Almohads, though something similar to the latter would likely appear around.
Now, thank to butterflies, have some scholar from there, let's say Ibn Tufayl just because I like him
(of course, it would not be the same person) start
questioning dominant Aristotelianism instead of further developing it as the OTL Almohad age philosophers were committed to do. This line of thinking gets official support for religious reasons - let's say that the alt-Ibn Tumart TTL develops a religious ideology that needs to oppose both theologians' Atomism and philosophical Aristotelian views. At the same time, this more philosophy-friendly rule embraces some of the more "progressive" ideas of Farabi's about uplifting the people through scientific and moral education, so that education is even more widespread than OTL (and Andalus had rather impressive literacy rates for the time even IOTL). Now you have the basis for an agricultural and scientific revolution. Fast-forward, handwave these Andalusians discover America somehow, say around 1300; more or less at the same time, you have massive paradigm shift in astronomy, that helps.
From here onwards it's anyone's guess, but you have established the fundamentals for a Industrialized Andalus-Maghrib down the line. The main problem I see with this, if the relative lack of raw resources. You can fix that by conquering America for good, but at this point, it's really impossible to say what happens....