Rails meets Solana
Build Solana dApps with Ruby on Rails 8. Modular gems for wallet auth, RPC, tokens, transactions, and real-time updates.
$
bundle add solrengine
Add Solana login in under a minute
One gem, one generator, one Stimulus controller. Watch the whole Sign In With Solana flow — challenge, signature, verify — wired into a Rails 8 app.
$
rails generate solrengine:install
RubyGems downloads across 10 gems · MIT licensed
Powering 8 showcase apps — wallets, savings, voting, token sales
The full stack — not just an RPC client
Other Ruby gems stop at RPC calls and keypairs. SolRengine ships every layer of a Solana dApp — wallet auth, RPC, tokens, transactions, and real-time updates — as modular, documented Rails gems.
Why Ruby for Solana?
A million Rails developers, and almost none of them onchain. The fastest path from idea to working dApp isn't a new stack — it's the framework you already know.
Convention over configuration, onchain
Wallet auth, RPC, tokens, transactions, real-time updates — solved problems in Rails-land,
now solved problems on Solana. One rails generate away instead
of a week of wiring.
Server-rendered beats SPA for most dApps
Read on the server, sign in the browser. Turbo Streams push balance changes to your views — no wallet-adapter boilerplate, no client-side state machine, no separate API layer to maintain.
Two decades of production maturity
Auth, background jobs, caching, migrations — Rails ships the boring parts every real dApp needs. SolRengine adds the Solana layer as modular gems, so you keep all of it.
Real code, not promises
Production examples from our showcase apps. Copy, paste, ship.
# Gemfile
gem "solrengine-auth"
# routes.rb — mounts at /auth
mount Solrengine::Auth::Engine => "/auth"
# User model — wallet address as identity
class User < ApplicationRecord
include Solrengine::Auth::Authenticatable
end
# Any controller — protect routes
class DashboardController < ApplicationController
before_action :authenticate!
end
# Gemfile
gem "solrengine-rpc"
# Get wallet balance
client = Solrengine::Rpc.client
balance = client.get_balance("wallet_address")
# => 4.2 (SOL)
# Token accounts
tokens = client.get_token_accounts("wallet_address")
# => [{mint: "...", ui_amount: 100, decimals: 6}]
# Latest blockhash
blockhash = client.get_latest_blockhash
# => {blockhash: "...", last_valid_block_height: 123}
# Gemfile
gem "solrengine-transactions"
# Transfer model with status tracking
class Transfer < ApplicationRecord
include Solrengine::Transactions::Transferable
end
# Status flow:
# pending → submitted → confirmed → finalized
# Background confirmation with exponential backoff
Solrengine::Transactions::ConfirmationJob
.perform_later(transfer.id)
# Generate from Anchor IDL
$ rails generate solrengine:program PiggyBank config/idl/piggy_bank.json
# Account model — reads on-chain state
class PiggyBank::Lock < Solrengine::Programs::Account
program_id "ZaU8j7X..."
account_name "lock"
borsh_field :dst, :pubkey
borsh_field :expiration, :u64
end
# Query accounts from chain
locks = PiggyBank::Lock.for_wallet(current_user.wallet_address)
Modular by design
Use what you need. Each gem works independently or together as a full framework.
solrengine-auth
Sign In With Solana — wallet authentication for Rails. Works with Phantom, Solflare, Backpack, and any Wallet Standard wallet.
gem "solrengine-auth"
solrengine-rpc
Solana JSON-RPC client. Balances, token accounts, signatures, blockhash, and transactions with SSL CRL tolerance.
gem "solrengine-rpc"
solrengine-tokens
SPL token metadata and portfolio management. Jupiter API integration for USD prices with intelligent caching.
gem "solrengine-tokens"
solrengine-transactions
SOL transfers with confirmation tracking. Background job with exponential backoff and full status lifecycle.
gem "solrengine-transactions"
solrengine-realtime
Real-time Solana account monitoring via WebSocket. Broadcasts balance changes to your views with Turbo Streams.
gem "solrengine-realtime"
solrengine-programs
Anchor program interaction. Parse IDL files to generate Ruby account models, instruction builders, and Stimulus controllers.
gem "solrengine-programs"
solrengine-ui
20 ViewComponents for Solana dApps — wallet buttons, token lists, balances, modals, cards, and more. Styled with Tailwind CSS, dark/light mode, and Lookbook previews.
gem "solrengine-ui"
Or install everything at once
The solrengine meta-gem bundles all components with a single install generator.
$
bundle add solrengine && rails generate solrengine:install
Two ways to hold a wallet
Your users bring their own wallets, or you hold wallets for them. SolRengine covers both — and they mix in one app.
Your users bring wallets
Non-custodial. Users sign in with Phantom, Solflare, or any Wallet Standard wallet and keep their own keys. Wallet auth (SIWS), RPC, token portfolios, transfers, and real-time updates — the gem family above.
gem "solrengine"
Quickstart
You hold wallets for your users
Wallet-per-User on the Solana Developer Platform (SDP). Users sign up with an email; the app provisions a custody wallet for each of them. The solana-sdp client gem plus the solrengine-sdp Rails engine: provisioning at signup, tracked transfers, live balance updates.
gem "solrengine-sdp"
Two reference apps: Lamport (wallets & payments) and Kudos (token issuance).
Wallet-per-User docsThe two paths mix in one app — custody wallets for everyday users, connected wallets for power users. Lamport, a neobank demo on devnet, is the worked example of the mix.
Built with SolRengine
Real applications showcasing what you can build.
Browse all case studies
SolRengine Starter
Your first Solana dApp in Rails. Wallet authentication, token portfolio, SOL transfers, dark/light mode, and 20+ UI components from solrengine-ui. The Rails equivalent of create-solana-dapp.
WalletTrain
Full Solana wallet with SIWS authentication, token portfolio with USD values, SOL transfers, and real-time balance updates via WebSocket.
How it's built
Deep dives into the architecture decisions behind SolRengine.
Server-Side RPC, Client-Side Signing: The Split Behind Every SolRengine dApp
The server never holds a key, the browser never holds your RPC credentials.
ComparisonThe Infrastructure a Solana dApp Needs: Four Services in Next.js, Four SQLite Files in Rails 8
RPC caching, confirmation tracking, and real-time push — with and without the microservices.
TutorialIssuing a Solana Token from Rails, Without Touching a Wallet
Register, deploy, mint, and burn a real SPL token through the Solana Developer Platform.