The difference in one minute
An air purifier uses a fan and filters to capture some particles and, when designed for it, certain gases. A dehumidifier condenses water from the air and collects or drains it. They solve different problems.
Gearjury may earn a commission when you buy through a retailer link. Editorial conclusions are based on cited evidence.
Guide
Choose a purifier to filter airborne particles; choose a dehumidifier to lower excess humidity. For damp or visible mould, moisture control comes first.

An air purifier uses a fan and filters to capture some particles and, when designed for it, certain gases. A dehumidifier condenses water from the air and collects or drains it. They solve different problems.
A dehumidifier can help manage high humidity, but the cause of damp still needs fixing. The EPA states that portable air cleaners do not solve mould problems: remove the moisture source and clean up the mould. A purifier may capture some airborne particles after remediation, but it is secondary.
For pollen, dust-mite debris or pet dander suspended in the air, a suitable particle filter and CADR are the relevant purifier measures. A dehumidifier changes humidity, which may matter in a damp home, but it does not filter pollen or dander.
A humidifier adds moisture, so it is a different device again. Do not add humidity to a damp or mould-prone room. Measure relative humidity before choosing any humidity-control appliance.
A combined unit can save floor space, but check both functions separately: water extraction rate and operating temperature for dehumidification; CADR, filter type and replacement cost for purification. One strong function does not prove the other.
Common questions
Choose by problem: airborne particles point to a purifier; excess humidity, condensation or damp point to moisture control and possibly a dehumidifier.
Address moisture and visible mould first. A purifier does not remove mould growth or fix damp.
Yes, if the room has both excess humidity and an airborne-particle need. Leave enough clearance for both appliances and follow their instructions.
They do different jobs. A purifier filters some airborne particles; a humidifier adds moisture. Health outcomes depend on the person and condition, so seek clinical advice.