# Bulk deactivation of inactive users

**URL:** https://meta.discourse.org/t/bulk-deactivation-of-inactive-users/64562
**Category:** Support
**Created:** [6월 15, 2017, 4:26오후 UTC](https://meta.discourse.org/t/bulk-deactivation-of-inactive-users/64562 "2017-06-15T16:26:38Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [6월 15, 2017, 4:37오후 UTC](https://meta.discourse.org/t/bulk-deactivation-of-inactive-users/64562/2 "2017-06-15T16:37:02Z")

</div>

A simpler solution might be to adjust `suppress digest email after days`. They’d still be “active” but they’d stop getting notices.

But, if you want, it’s something like this:

```plaintext
cd /var/discourse
./launcher enter app
rails c
User.where("last_seen_at < '2016-01-01'").update_all(active: false)
exit
exit

```

---

_[View the full topic](https://meta.discourse.org/t/bulk-deactivation-of-inactive-users/64562)._
