Yes, it occurs in up to a quarter of people on treatment and is more common with some types of antibiotic, particularly broad-spectrum ones. It is due to an alteration in the balance of different bacteria in the gut.
Most cases are mild and self-limiting, stopping within a few days of finishing the treatment course, but sometimes you will need to stop the antibiotics and seek your GP’s advice. Make sure you drink plenty of fluids while you have symptoms. About 20-30% of cases are caused by Clostridium difficile infection which can be more serious.