Skip to main content
This guide is aimed at advanced users who want to add Spree to an existing Rails application. If you are new to Spree, please follow the Quickstart guide.

Overview

If you already have a Ruby on Rails application, you can add Spree to it by following these steps.
Spree works with PostgreSQL, MySQL, and SQLite — whatever database your Rails app already uses. No database migration is needed.

1. Add Spree gems

Add these lines to your project Gemfile:
And run the following command to install the gems:

2. Run the install generators

Spree uses a modular installation approach. First install the core, then add optional components.

Install core Spree

This installs core models, API, CLI, and authentication:
Core installation options:

Install Admin Panel (optional)

Add sample data (optional)

To add sample data to your store, run:
This will add some products, categories and multiple markets to your store.

Accessing Admin Panel

Navigate to http://localhost:3000/admin and log in with the default credentials: Upon successful authentication, you should see the admin screen:

Spree Admin Dashboard


Congrats! You’ve set up your Spree Commerce and it’s looking amazing! Give Spree a GitHub Star, why don’t ya? Thank you for supporting Spree open-source! Need support or want to give some feedback? Join our Discord