rails db:rollback all code example Example: rails db:rollback rake db:rollback VERSION=n # n = the version you want to rollback to