Rails: ActionView::MissingTemplate (Missing template users/show, application/show with {:locale=>[:en], :formats=>[:html], :handlers=>[:erb, :builder, :raw, :ruby, :jbuilder]})
The action tried to render a view that doesn't exist for the requested format/handler.
ActionView::MissingTemplate (Missing template users/show, application/show with {:locale=>[:en], :formats=>[:html]})Missing template users/showActionView::MissingTemplate: Missing partial shared/_headerActionController::MissingExactTemplate: UsersController#show is missing a template for request formats: text/htmlMissing template with {:locale=>[:en], :formats=>[:html], :variants=>[], :handlers=>[:raw, :erb, :html, :builder, :ruby, :jbuilder]} Meaning
Create app/views/users/show.html.erb (matching controller/action names), or render explicitly (render :other, render json:). Check the file extension (.html.erb), the folder naming (plural), partial names start with _, and API-only apps lacking a renderer (render json:).
Common causes
- View file missing or misnamed
- Wrong extension/handler (.erb vs .haml gem missing)
- API action with no explicit render (expects 204 or JSON)
- Partial name without underscore
- Wrong controller path (namespaced)
⚡ Quick fix
- Create the template with the right path/name
render json:/head :no_contentfor API actions- Verify gems for handlers (haml, slim, jbuilder)
Detailed fix by platform
Rails
ls app/views/usersandbin/rails routes -c users
How to diagnose
- Path — Template exists?
- Format — html/json?
- Handler — Gem present?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
- AbstractController::DoubleRenderError Rails: AbstractController::DoubleRenderError (Render and/or redirect were called multiple times in this action. Please note that you may only call render OR redirect, and at most once per action)
- ActionController::RoutingError: No route matches Rails: ActionController::RoutingError (No route matches [GET] "/users/new")
- ActionController::UnknownFormat Rails: ActionController::UnknownFormat — UsersController#show is missing a template for this request format and variant
Most viewed in Ruby / Rails
- ActiveRecord::PendingMigrationError Rails: ActiveRecord::PendingMigrationError — Migrations are pending. To resolve this issue, run: bin/rails db:migrate
- undefined method for nil Ruby: NoMethodError: undefined method `x' for nil (nil:NilClass)
- ActionController::InvalidAuthenticityToken Rails: ActionController::InvalidAuthenticityToken (Can't verify CSRF token authenticity)
Other ways to find it
Where this error sits
Origin: Application & API. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 5 Nov 2026