While both male and female cats are liable to urinate outside of the litter box for a number of reasons, it's more prevalent in males -- particularly males that haven't been neutered. But the behavior doesn't have to be hormonally motivated, necessarily. Males and females often urinate inappropriately for other reasons you need to look into.
Unfortunately, inappropriate urination can be the result of a medical condition. For example, if your cat has a urinary tract infection that makes urination painful and inconsistent, he may dribble or squirt urine throughout the house. His failure to use the litter box could be the result of a separate health issue, even. For example, if the box is on a raised surface and your cat has arthritis or an injury, jumping up and down may be too painful, and he could start urinating at ground level on your carpet. Irregular behavior of any kind, including this, is a sign that you should see a vet.
Litter Box Problems
Sometimes, a male cat urinates on the carpet for the same reasons a female cat would. He may feel an aversion to the litter box based on the texture of the litter, its cleanliness or lack thereof, its location or the litter's scent. Cats generally prefer a fine-grained litter rather than a coarse one, which can be uncomfortable for their paws. If your cat is rejecting the litter box seemingly without provocation, consider recent changes -- for example, if you switched litter brands, he may be rejecting the new formula.
Spraying and Marking
Intact males and females both engage in territorial marking and spraying behaviors, and males are even more likely to do so. This is when a cat sprays his urine throughout his habitat -- in this case, your home -- as a way to label it his. Cats also mark to attract mates. Cats typically spray vertical surfaces rather than horizontal ones, like your walls. But your carpet isn't necessarily safe -- urine can collect and form puddles on the floor.
Neutering Your Male
If your male cat is urinating on the carpet and he has not been neutered, having the procedure performed gives you a strong chance at eliminating the behavior. Only about 10 percent of males continue marking after being neutered, and the earlier in life he's neutered the better the odds. In some cases, a mature cat will continue urine-marking, even after he's been fixed, simply out of habit. It's best to have the procedure done before it becomes a problem