I need to create a script to remove some users from a WordPress DB. I would like to be able to remove those users without modify directly the database and just executing the script.

I would like to know if WordPress has a some kind of SDK or something to do this thinks without need to create a plugin.

Is it possible?

1 Answer 1


A number of ways to do this.

You could use wp-cli, WP REST API or even include wp-load.php from a custom script and use built-in wp_delete_user() function.


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.