We had purchased this since our pup had figured out how to open our other motion senor trash can. This one has a lock.  Only short coming is this one stays open a little longer than the other. Just have to keep Frankie from sneaking in before it closes.