- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
This guide will walk you through integrating Prerender into your Rails server, improving your SEO.
Video guide:
Prerender token
The location of the Prerender token has changed. You can find it under the Security and Access menu under Prerender Token.
You can find the required codes in the text guide.
Text guide:
- Navigate to your project's root directory. e.g.:
/home/rails/example/
- Add the middleware gem by inserting the line below into you project's Gemfile.
Usually located at/<project root directory>/Gemfile
gem 'prerender_rails'
- Then add the line below to your production config file usually located at
/<project root directory>/config/environments/production.rb
.
config.middleware.use Rack::Prerender, prerender_token: 'YOUR_TOKEN'
- Make sure to replace the YOUR_TOKEN place holder with your Prerender.io Token from the Security and Access menu
- Restart your rails server and check your Prerender integration by following this guide.
Was this article helpful?