Heroku deployment failed because of sqlite3 gem error

Heroku can’t install the sqlite3 gem, for whatever reason. But you can tell bundler that it shouldn’t be trying to except when developing.

In your Gemfile, replace gem 'sqlite3' with:

group :development, :test do
  gem 'sqlite3'
end
group :production do
  gem 'pg'
end

Then bundler on heroku, running as production, won’t try to install it.

Leave a Comment