It can be like someone has to wash hands compulsively (think about the character Monk!) or make sure if the doors are locked (repeatedly, even after checking a few times) or other 'rituals', or people can have 'Pure-O' which is unwanted thoughts that keep repeating themselves, even if people really don't want to think that...
Some people may clean too much, or may be afraid of cleaning.. (for exaggerated or mostly unreasonable reasons mostly) Or they don't know if concerns are reasonable or not, that may be part of OCD too..
For Pure-O, for example some people might be afraid that they would be homosexual, or that they would kill someone, or something completely random... Even when they themselves can be completely shocked at the thought of it and would never harm anyone in real life.. (Real criminals would mostly just do it and not worry about it...) It's basically like the thought would get stuck in the head, like an old record 'skipping'...
They can worry about something religious or about leaving their partner even if they love him/her, and would be miserable without them.. (That's called 'relationship OCD') It's distorted thinking, similar like with depression or anxiety, some thoughts get exaggerated and repeated over and over..
Some people online say it can be because of vitamin/mineral nutritional deficiencies or such too (similarly to depression or anxiety), some nutritional changes or supplements might be helpful, and CBT or ERP can be helpful..
You have some good explanations on Wikipedia and elsewhere online too..