An XXE attack can have severe consequences, including unauthorized access to sensitive data, server compromise, and even remote code execution. It can lead to data breaches, financial loss, and damage to the reputation of the affected organization.