AI refers to the ability of machines to perform tasks that normally require human intelligence, while IoT refers to the network of physical devices connected to the internet.