how to delete all user defined database in mongodb code example Example: delete collection mongodb db.collection.drop()