How can I force Safari to perform a full page reload, without using the mouse?

44

6

I'm using Safari to preview web pages as I develop them on my local server. I've got 'Disable Caches' checked in the Develop menu. And yet Safari is still working from a cached version of a stylesheet that's linked from the HTML file being displayed.

I can sometimes override this by Option-clicking the reload button in the location bar, but I want to refresh the page automatically when I save the CSS file. At the moment I'm doing it using an AppleScript that's bound to the Save action in my text editor. I could see using Keyboard Maestro instead. But I need some consistent way to force Safari to do a full reload from the keyboard.

Gabe

Posted 2010-09-09T14:59:51.853

Reputation: 571

Do you have any extensions installed. Had this problem once with Adblock... It messed up one page in particular, thought it was a stylesheet problem too, tried everything... but it was Adblock messing with it. – unom – 2014-01-08T22:08:49.200

Answers

36

Enable the Develop menu from Safari menu - Preferences - Advanced.

On Safari version 11.1 and above :

CMD+OPTION+R reloads the page ignoring cache.

On Safari version 9 and above :

CMD+SHIFT+R reloads the page ignoring cache.

Emptying caches seems not to reload the stylesheets everytimes…

On Safari below version 9 :

Empty cache and then reload so full "hot key" would be :

CMD+OPTION+E

Then

CMD+R to refresh the page

Of course probably turning opening and closing a New Private Windowfrom the File would also work but…

wickdninja

Posted 2010-09-09T14:59:51.853

Reputation: 470

that didn't work for me on Safari 8 – Brian Tingle – 2015-09-11T05:49:52.380

3Safari version 9.1.1 does not reload the page with Cmd-Shift-R. I have "Show Develop in menu bar" enabled. – Jason – 2016-06-21T13:46:10.927

cmd+shift+R didn't work for me in 9.1.3 either – sfletche – 2016-10-13T17:07:12.300

1Cmd+Shift+R didn't work in Version 10.0.1 (11602.2.14.0.7). – Snowcrash – 2017-02-14T10:59:50.850

Checkout @sayan's answer below for a working shortcut

– Vlad – 2018-05-17T14:35:46.947

12

The shortcut has now changed to OPTION + CMD + R. (Safari 11.1)

sayan

Posted 2010-09-09T14:59:51.853

Reputation: 221

1Works perfectly! – kerrin – 2018-04-25T04:23:57.677

7

There is an option in the menubar Develop->Disable Caches. This is true for Safari 5.1. I'm not sure for the rest.

Screenshot

mist

Posted 2010-09-09T14:59:51.853

Reputation: 233

2Please read the second sentence of my question again. – Gabe – 2011-07-28T17:06:14.910

1Oops, I'm sorry :) – mist – 2011-07-29T07:01:13.443

2

Hard refresh was removed as a keyboard shortcut in Safari 5. The old command for that was +SHIFT+R

CTRL+F5 May work but I can't test here.

JNK

Posted 2010-09-09T14:59:51.853

Reputation: 7 642

Yes, that's how to refresh the page, but it doesn't bypass the cache. – Gabe – 2010-09-09T16:02:23.500

2Control-F5 just selects the location bar, like Command-L. – Gabe – 2010-09-09T16:45:30.533

Then it's been disabled completely. I found a number of threads complaining about it. There is an extension that I have NOT tested here: http://twitter.com/siracusa/status/15683201068 that may do what you want.

– JNK – 2010-09-09T16:47:17.143

No, that extension just creates a button in the toolbar (which I guess some people prefer to the icon in the location bar). I also found a lot of threads complaining about it—i was wondering if someone on here had any special knowledge. – Gabe – 2010-09-09T19:37:17.990

Sorry! :( <15chars> – JNK – 2010-09-09T19:47:07.297

Shift + Click on the refresh button – Brian Wigginton – 2011-04-07T00:14:00.310

1

I stumble upon this question and apparently the current answers do not work.

Issue is currently CMD+ALT+R opens the Responsive design.

However if the inspector is open via CMD+ALT+I, then the same shortcut does a clean refresh.

Current Safari Version: 12.1.2

Ant

Posted 2010-09-09T14:59:51.853

Reputation: 111

1

Workaround: in the develop menu, select "start debugging javascript" and it must reload the code properly. You can then stop debugging... I know it's not a clean solution and I'm not sure if it works always or in all versions, but it's working for me now.

Rico

Posted 2010-09-09T14:59:51.853

Reputation: 11

1

Turn on Private mode and refresh the page. It won't get it from the cache in private mode.

Jahanzeb

Posted 2010-09-09T14:59:51.853

Reputation: 11

0

CMD+L focus on the address bar SHIFT+ALT+ENTER full reload for the current address

It seems to work on Safari 9

rraallvv

Posted 2010-09-09T14:59:51.853

Reputation: 345

And how does one click without a mouse? – qasdfdsaq – 2015-10-23T12:51:58.403

1@qasdfdsaq My bad, edited the question. – rraallvv – 2015-10-23T13:00:06.023

-3

Go to Safari's preferences and tick "Show develop menu". In the develop menu, click disable Caches.

user201045

Posted 2010-09-09T14:59:51.853

Reputation: 1

1Please read the second sentence of my question. – Gabe – 2013-02-21T11:55:43.527