diff --git a/Gemfile b/Gemfile
index fbc3ad9e298fdb92602e87acd79fc66b31f4b256..c0d36ba5b91617f3623f01a35f86c6540181b3d4 100644
--- a/Gemfile
+++ b/Gemfile
@@ -66,5 +66,5 @@ group :production do
 end
 
 group :development, :production do
-  gem 'rack-mini-profiler'
+  gem 'rack-mini-profiler', require: false
 end
diff --git a/app/assets/javascripts/mastodon-logo.coffee b/app/assets/javascripts/mastodon-logo.coffee
index bcf52f3781a9e04b573a718d8f547a635de7ecf9..0b4e67e798a7e91bec17f9d6e8dc651a24f7c2c0 100644
--- a/app/assets/javascripts/mastodon-logo.coffee
+++ b/app/assets/javascripts/mastodon-logo.coffee
@@ -44,5 +44,5 @@ work = ->
   if runs == stop_at_run
     stop()
 
-$ ->
+$(document).on 'turbolinks:load', ->
   setTimeout(start, 100)
diff --git a/app/assets/javascripts/profiler.coffee b/app/assets/javascripts/profiler.coffee
new file mode 100644
index 0000000000000000000000000000000000000000..bcdcc1e59aaa8977a6b52b6aaada96d05d18b234
--- /dev/null
+++ b/app/assets/javascripts/profiler.coffee
@@ -0,0 +1,2 @@
+$(document).on 'turbolinks:load', ->
+  window.MiniProfiler.pageTransition() unless typeof window.MiniProfiler == 'undefined'
diff --git a/app/assets/stylesheets/application.scss b/app/assets/stylesheets/application.scss
index e34f0ba324f68ed3dff3888bfee3c54ab0a1a18c..1f35053a1182485c80b3361bd49ece33a56163e3 100644
--- a/app/assets/stylesheets/application.scss
+++ b/app/assets/stylesheets/application.scss
@@ -279,6 +279,10 @@ body {
   }
 }
 
+.turbolinks-progress-bar {
+  background-color: #2b90d9;
+}
+
 .mastodon {
   $head: #282c37;
   $tusk: #d9e1e8;
diff --git a/app/models/status.rb b/app/models/status.rb
index 59c94aacaab44fa17244db6802da44d947a0194a..439cd305310738547b209ec5150ed41816147fad 100644
--- a/app/models/status.rb
+++ b/app/models/status.rb
@@ -17,7 +17,7 @@ class Status < ActiveRecord::Base
   validates :text, presence: true, if: Proc.new { |s| s.local? && !s.reblog? }
 
   scope :with_counters, -> { select('statuses.*, (select count(r.id) from statuses as r where r.reblog_of_id = statuses.id) as reblogs_count, (select count(f.id) from favourites as f where f.status_id = statuses.id) as favourites_count') }
-  scope :with_includes, -> { includes(:account, :mentions, reblog: [:account, :mentions], thread: [:account, :mentions]) }
+  scope :with_includes, -> { includes(:account, :mentions, :stream_entry, reblog: [:account, :mentions], thread: [:account, :mentions]) }
 
   def local?
     self.uri.nil?
diff --git a/config/application.rb b/config/application.rb
index 1fbd8f7f6dcba1f32463c7d5e3555f65fbcc62fd..7d6182ecca3659785265d46dc2aa36bcfb46540d 100644
--- a/config/application.rb
+++ b/config/application.rb
@@ -37,5 +37,6 @@ module Mastodon
     end
 
     config.middleware.use Rack::Attack
+    config.middleware.use Rack::Deflater
   end
 end
diff --git a/config/initializers/rack-mini-profiler.rb b/config/initializers/rack-mini-profiler.rb
new file mode 100644
index 0000000000000000000000000000000000000000..b1d45e257ec1de6d9cd27ae3d0f0c3e731159d1e
--- /dev/null
+++ b/config/initializers/rack-mini-profiler.rb
@@ -0,0 +1,6 @@
+require 'rack-mini-profiler'
+
+Rack::MiniProfilerRails.initialize!(Rails.application)
+
+Rails.application.middleware.delete(Rack::MiniProfiler)
+Rails.application.middleware.insert_after(Rack::Deflater, Rack::MiniProfiler)