I am trying to create a new term in topic taxonomy. Since I am writing in Bangla Unicode instead of English, the slug is created with lesser/broken text.

Is there any hook to update the length for the taxonomy term slug?

enter image description here

1 Answer 1


By default WordPress sets the length of that field to 200 when the database tables are created.

Now you could change that by running this SQL command in your console (change the tabe prefix to your setting, and make a backup first):


But … the nice name, the first field in your screenshot, has the same restriction, and it's not truncated. Also I don't see anything in the WordPress code that enforces a restriction on the slug before it is inserted into the database. It's possible I missed that in the callback hell that WP is.

So do a test run for this in a safe, exact copy of your site and see if it fixes your issue. Also make sure you don't insert invalid characters, because they will lead to truncated values. This can happen when you are using copy&paste from a software that isn't completely Unicode compatible, like Word.

The other "solution" is just to use shorter slugs.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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