Skip to content
railsengines.com

Field Test

A/B testing for Rails with a results dashboard and real statistics

Takes off your invoice

You would run instead $0/mo

No ratings yet
Gem
field_test
Repository
ankane/field_test
License
MIT
Stars
590
Added
August 10, 2026
Field Test mounted at /field_test
Field Test mounted at /field_test

About

A/B testing that stores assignments in your database and shows the results in a
mounted dashboard.

What you get

  • Experiments defined in a YAML file
  • Variant assignment that survives the anonymous-to-signed-in transition
  • Conversion tracking with one call
  • A dashboard with Bayesian probability that each variant wins

Mounting it

ruby
# Gemfile
gem "field_test"

# config/routes.rb
authenticate :user, ->(user) { user.admin? } do
  mount FieldTest::Engine, at: "field_test"
end
erb
<%%= field_test(:button_color) == "red" ? "Buy now" : "Get started" %>

The assignment problem, solved

The hard part of A/B testing is not splitting traffic — it is keeping a visitor in
the same bucket after they sign up. Field Test handles that because it can see both
the cookie and the user record.

Discussion (0)

Sign in to join the discussion.

No comments yet.