IOAs aim to spot and thwart attacks in progress by recognizing suspicious behaviors, while IOCs are employed for the post-event analysis, identifying and investigating security incidents based on artifacts and evidence left behind after a compromise.