WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I wish to restrict the user posting a new article to select only 1 category for that post. It doesn't matter which category he chooses as long as he chooses just one. This way posts are maintained under a hierarchy (and I want to avoid users clicking all categories so that their posts appear everywhere).

I don't want to restrict the user to a specific category, I just want to limit the number of categories the user can choose for a post to 1.

Is there any way to achieve this in Wordpress?

share|improve this question
Cleaned up. (filler text) – kaiser Oct 13 '12 at 0:54
up vote 2 down vote accepted

I've solved this in the past for a client by using remove_meta_box to hide the default categories meta box, then adding my own meta box via add_meta_box which outputs categories as a drop-down select list, which effectively limits selection to a single item.

share|improve this answer
Thanks. So I guess I could also output them as Radio buttons, and also not display Parent categories if I wish to only allow pages to be categorised with a leaf category? – jbx Oct 13 '12 at 11:48

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.