Web Applications Stack Exchange is a question and answer site for power users of web applications. 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

On Wikipedia, is it possible to automatically merge multiple existing categories into a new category (for example, automatically moving all items in the category [[Flying animals]] and [[Birds]] to the category [[Flying birds]])? (i.e., all items that belonged to both of those categories would be moved to the new category).

share|improve this question
This idea occurred to me today because I've been sorting through some overcrowded categories on Wikipedia (which need to be sub-divided into more specific categories), and I've been searching for a way to automatically categorize items based on the categories that they already belong to. – Anderson Green Mar 29 '13 at 15:29
Probably, but such a merger would have to be discussed at Categories for Discussion before anything happened. – Al E. Mar 29 '13 at 15:51
up vote 2 down vote accepted

Yes, it is possible, but not directly on Wikipedia itself. You would need to use Pywikipedia for this.

There is a script in Pywikipedia called category.py. Lets say "foo" is the original category and "bar" is the category you want to merge into. Use the following command:

python category.py move -from:"foo" -to:"bar"

This would move all the pages in the "foo" category to the "bar" category. So, if you have multiple categories to merge, you would have to run this script multiple times for all the categories you have.

share|improve this answer

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.