The advent of generative Artificial Intelligence (AI) has disrupted many areas, but particularly the field of education. Chatbots powered by Large Language Models (LLMs), trained with massive volumes of data to recognize and generate content as a response to natural language queries, have become the fastest-adoption technology in history, quickly making their way into classrooms. The role of technology in mathematics education has long been a matter of discussion. While some authors argue that computers and calculators can hinder reasoning processes because students need to first understand mathematical knowledge, others argue that technology can introduce new forms of teaching mathematics and serve students in different contexts. Ramirez (2020) stated that instead of assuming that the mere use of technology would lead to changes in learning, teachers who wish to use AI technology effectively must transform it into a valuable asset for teaching and, therefore, learning. Most of the discussion about this issue has, so far, occurred in the context of traditional Information and Communications Technology with traditional software (e.g. Geogebra). Generative AI is, in many regards, a distinctive technology both in its relation with mathematics and in social matters. Here we discuss the novel challenges it poses and the new possibilities it opens to teaching and learning mathematics.