XF 1.1 Purge all members

Adam Howard

Well-known member
I'm wondering if there is away to delete all the members except for the Super Admin (myself).

Such a command would make things easier when I reload a test site (rather than delete 1 by 1).

Jake Bunce

XenForo moderator
Staff member

Adam Howard

Well-known member
There isn't a mass user prune feature. And it's not a simple query either.

Is the purpose to import again into the same database? That is not recommended. You should install fresh or restore a backup from before the import. There is no easy way to deal with duplicate content from multiple of the same import. With that said, it has been done:


But it's a dirty thing to do.
I seem to "self destruct" my test site regularly.

Sometimes I just have the stock install and I'm developing it for a new add-on and so need it to be fresh and clean. Other times it is to see how something looks and works alone or with a combination of add-ons. And yet other times, it is an exact copy of my current site for full testing.

It is the last part of that which is my concern.

What I'll do is copy all the files into the test folder and then backup the database and import it into an empty database. Thus now I have a full exact copy as the live site which I can play around with and see if things would go "boom" if I did X value.

This works for me, but of course I've got to delete all those users now.