# "Loading..." when opening localhost

**URL:** <https://community.plotly.com/t/loading-when-opening-localhost/7284>\
**Category:** Dash Python\
**Created:** [December 12, 2017, 4:15pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284 "2017-12-12T16:15:59Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![amitter](https://avatars.discourse-cdn.com/v4/letter/a/c67d28/32.png) [@amitter](https://community.plotly.com/u/amitter)\
**Post date:** [December 12, 2017, 4:15pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/1 "2017-12-12T16:15:59Z")

</div>

I’m completely new to plotly/dash, therefore likewise to the User Guide. I installed all dash and plotly related stuff as described. I copied the code, created app.py and let it run. Opening localhost on port 8050 as described doesn’t give me the simple Hello Dash example. All I see is a white window with “Loading…” at the top left corner.  
I’m using python 2 with anaconda on Ubuntu 16.04.  
I tried disabling ad-block as described in some forum, didn’t help.  
I set the debug mode = False, didn’t help.  
Re-installing and/or rebooting didn’t help.  
Any suggestions? Thanks

---

<div class="post-metadata">

**Author:** ![amitter](https://avatars.discourse-cdn.com/v4/letter/a/c67d28/32.png) [@amitter](https://community.plotly.com/u/amitter)\
**Post date:** [December 12, 2017, 4:21pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/2 "2017-12-12T16:21:05Z")

</div>

The console output is:  
$ python [app.py](http://app.py)

- Running on [http://127.0.0.1:8050/](http://127.0.0.1:8050/) (Press CTRL+C to quit)  
127.0.0.1 - - [12/Dec/2017 16:58:25] “GET / HTTP/1.1” 200 -

---

<div class="post-metadata">

**Author:** ![chriddyp](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/chriddyp/32/16855_2.png) [@chriddyp](https://community.plotly.com/u/chriddyp)\
**Post date:** [December 12, 2017, 4:35pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/3 "2017-12-12T16:35:29Z")

</div>

@amitter - Could you open up your browser’s dev tools and look at the console? You’ll likely see an error message there.

I suspect that this is related to the JS assets from the CDN not loading properly - perhaps because they are blocked by your firewall or some other reason.

You can load the assets locally by setting:

```auto
app.scripts.config.serve_locally = True
app.css.config.serve_locally = True

```

anywhere in your code.

---

<div class="post-metadata">

**Author:** ![amitter](https://avatars.discourse-cdn.com/v4/letter/a/c67d28/32.png) [@amitter](https://community.plotly.com/u/amitter)\
**Post date:** [December 12, 2017, 4:41pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/4 "2017-12-12T16:41:24Z")

</div>

console output:

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/6/62774493e0018759e355769037526a94e9d2b253.png)

thanks, the local approach works.

---

<div class="post-metadata">

**Author:** ![nahal626](https://avatars.discourse-cdn.com/v4/letter/n/51bf81/32.png) [@nahal626](https://community.plotly.com/u/nahal626)\
**Post date:** [October 4, 2018, 10:09am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/5 "2018-10-04T10:09:14Z")

</div>

Hi,

I have the same Problem (Loading… on the top), but adding the two lines didn’t fix it.  
I’m running python on Spyder with Anaconda.  
Could you please help? Thanks

---

<div class="post-metadata">

**Author:** ![benlindsay](https://avatars.discourse-cdn.com/v4/letter/b/7cd45c/32.png) [@benlindsay](https://community.plotly.com/u/benlindsay)\
**Post date:** [March 13, 2019, 1:37am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/6 "2019-03-13T01:37:15Z")

</div>

@chriddyp I’m also having the same issue and adding the two lines didn’t fix it for me as well. I’m on Mac OSX 10.12.6. I used to be able to run simple plotly dash pages just fine several months ago, but now I can’t get them to work. I also don’t see any console output or errors when I open the dev console. Any thoughts on how to debug this?

---

<div class="post-metadata">

**Author:** ![benlindsay](https://avatars.discourse-cdn.com/v4/letter/b/7cd45c/32.png) [@benlindsay](https://community.plotly.com/u/benlindsay)\
**Post date:** [March 13, 2019, 4:21am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/7 "2019-03-13T04:21:16Z")

</div>

I figured out my problem! @nahal626 this might fix your problem too. My problems happened when I used versions of the dash helper packages that were newer than the dash package. If you specify `dash=0.37.0` when you install with conda, it should work out. So for example, it should work if you create a new environment with `conda env update -f environment.yaml`, where `environment.yaml` looks like this:

```auto
name: dash-test
channels:
  - conda-forge
  - defaults
dependencies:
  - python=3.7
  - dash=0.37.0 

```

If you look at the different versions of dash provided by conda using `conda search dash --info`, you’ll get a list of a bunch of versions, and the latest one looks like this:

```auto
dash 0.37.0 py_0
----------------
file name : dash-0.37.0-py_0.tar.bz2
name : dash
version : 0.37.0
build : py_0
build number: 0
size : 38 KB
license : MIT
subdir : noarch
url : https://conda.anaconda.org/conda-forge/noarch/dash-0.37.0-py_0.tar.bz2
md5 : cddf17a399c6a0fc1778dc14496cfcc5
timestamp : 2019-02-19 06:02:53 UTC
dependencies:
  - dash-core-components 0.43.1
  - dash-html-components 0.13.5
  - dash-renderer 0.18.0
  - dash-table 3.4.0
  - flask >=0.12
  - flask-compress
  - plotly
  - python

```

It’s unique in that it’s the only one that specifies exact versions of the dash helper packages, so if you make sure to specify `dash=0.37.0` you should get those versions that are compatible. Or just check to make sure the versions of your `dash-*` packages match the versions listed above. I also tested older versions of dash and found that the hello world code works fine as long as I was using helper packages that came out at around the same time as any given `dash` release.

By making sure to use a compatible set of packages, I didn’t have to do the `serve_locally` stuff either. Hope this helps!

---

<div class="post-metadata">

**Author:** ![nahal626](https://avatars.discourse-cdn.com/v4/letter/n/51bf81/32.png) [@nahal626](https://community.plotly.com/u/nahal626)\
**Post date:** [March 13, 2019, 9:28am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/8 "2019-03-13T09:28:38Z")

</div>

What browser are you using? My problem was solved when I switched from Internet Explorer 11 to Chrome

---

<div class="post-metadata">

**Author:** ![benlindsay](https://avatars.discourse-cdn.com/v4/letter/b/7cd45c/32.png) [@benlindsay](https://community.plotly.com/u/benlindsay)\
**Post date:** [March 13, 2019, 11:22am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/9 "2019-03-13T11:22:21Z")

</div>

I’ve been using Chrome the whole time so I guess our problems were different. Glad you fixed yours!

---

<div class="post-metadata">

**Author:** ![ploddingplotter](https://avatars.discourse-cdn.com/v4/letter/p/c37758/32.png) [@ploddingplotter](https://community.plotly.com/u/ploddingplotter)\
**Post date:** [March 13, 2019, 3:37pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/10 "2019-03-13T15:37:05Z")

</div>

I’ve been using this library consistently for the last few weeks. It was working just an hour ago. I just rebuilt my virtual environment from scratch and now I cannot proceed past the “Loading…” message. I’m running Mac OS High Sierra (10.13.6), python 3.6.4.

I was previously using dash==0.36.0. When I upgraded to dash==0.39.0 it worked.

---

<div class="post-metadata">

**Author:** ![chriddyp](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/chriddyp/32/16855_2.png) [@chriddyp](https://community.plotly.com/u/chriddyp)\
**Post date:** [March 13, 2019, 3:59pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/11 "2019-03-13T15:59:40Z")

</div>

Could you share a small, reproducable example?

---

<div class="post-metadata">

**Author:** ![danishmnz](https://avatars.discourse-cdn.com/v4/letter/d/8baadc/32.png) [@danishmnz](https://community.plotly.com/u/danishmnz)\
**Post date:** [July 18, 2019, 5:57am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/12 "2019-07-18T05:57:41Z")

</div>

For me the issue was that when I tried to update dash from 0.39 to the version 1.0.2, all my components etc updated but dash itself failed to update due to an issue with pyyaml not uninstalling. After uninstalling dash, I got through this by simply ignoring pyyaml by using:

pip install dash --ignore-installed PyYAML

---

<div class="post-metadata">

**Author:** ![ollerend](https://avatars.discourse-cdn.com/v4/letter/o/a87d85/32.png) [@ollerend](https://community.plotly.com/u/ollerend)\
**Post date:** [August 9, 2019, 6:06am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/13 "2019-08-09T06:06:38Z")

</div>

I’m facing the same problem. I’ve tried a lot of troubleshooting and simplifying. Here’s my best shot at describing where I stand. Any suggestions?

The problem:  
I have an apache webserver running on a raspberry pi and I’d like to make a plotly dash page available. For now, I’m trying to host it at http://\<ip\_of\_pi\>/flask. Here’s what I see when accessing from my laptop with google Chrome (I also tried Safari):

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/4/496adf12e03c5b9fd482006889ce8864f2a91bbd.png)

I’ve tried to strip the dash app down to the bare minimum. Here’s the code:

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/b/b6b8263e7c231600364813f8e8240789551bf652.png)

---

<div class="post-metadata">

**Author:** ![ollerend](https://avatars.discourse-cdn.com/v4/letter/o/a87d85/32.png) [@ollerend](https://community.plotly.com/u/ollerend)\
**Post date:** [August 9, 2019, 6:07am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/14 "2019-08-09T06:07:28Z")

</div>

breaking this into parts to avoid the image limit…

When I run it directly from the command line on the pi, it runs as expected on port 8050:

> > python dash\_app.py
> > 
> > ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/f/f51832dc4b0a022274e9ce4c7f3eb07e98bd7bfd.png)

And here’s what I see on my laptop:

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/5/5ebcf564f4757bf934ef4e2ad5613ab171e1935e.png)

---

<div class="post-metadata">

**Author:** ![ollerend](https://avatars.discourse-cdn.com/v4/letter/o/a87d85/32.png) [@ollerend](https://community.plotly.com/u/ollerend)\
**Post date:** [August 9, 2019, 6:08am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/15 "2019-08-09T06:08:06Z")

</div>

I also created a much simpler flask-based app and I’m able to successfully host it. Here’s the WSGI file that I’m using to toggle between the dash app and the basic flask app:

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/2/2f9ae26bb094dc80b7d623ea3916c3555ae554b5.png)

with the line for flask\_hello uncommented, I can successfully run the following very basic flask app at http://\<ip\_of\_pi\>/flask

![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/b/bd0ba97c5096b686ebd721606c9a6b815507cba1.png)

here’s the result:

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/8/866fc698d3ea42e1d791afc8642a9b1d62174140.png)

A couple more points of reference:  
This is running in python 2.7 on my pi (I haven’t yet figured out how to make apache/wsgi use anything other than the base python. Any tips on how to configure it to run from a python 3 conda environment?)

Here’re the dash versions as installed by pip:

> $pip list | grep dash  
> dash (1.1.1)  
> dash-core-components (1.1.1)  
> dash-daq (0.1.7)  
> dash-html-components (1.0.0)  
> dash-renderer (1.0.0)  
> dash-table (4.1.0)

And here’s the relevant part of my /etc/apache2/sites-enabled/000-default.conf file

> ```
> WSGIDaemonProcess webtool user=pi group=pi threads=5 home=/var/www/html/flask/
> WSGIScriptAlias /flask /var/www/html/flask/app.wsgi
> 
> <directory /var/www/html/flask>
> WSGIProcessGroup webtool
> WSGIApplicationGroup %{GLOBAL}
> WSGIScriptReloading On
> Order deny,allow
> Allow from all
> </directory>
> 
> ```

And to summarize:

- I can host a flask app through apache at \<ip\_of\_pi\>/flask
- I can host a dash app by running at the command line at \<ip\_of\_pi\>:8050
- But I CANNOT host a dash app using apache at \<ip\_of\_pi\>/flask. I only see “Loading…”

Any tips? Hopefully that’s enough info to diagnose! I can’t think of anything else to try.

---

<div class="post-metadata">

**Author:** ![ouroboroski](https://avatars.discourse-cdn.com/v4/letter/o/53a042/32.png) [@ouroboroski](https://community.plotly.com/u/ouroboroski)\
**Post date:** [August 30, 2019, 11:04am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/16 "2019-08-30T11:04:04Z")

</div>

I was experiencing the same problem running the ‘Hello Dash’ script from the tutorials from Spyder (Anaconda).

I realised that when **copying the IP address with CTRL+C** I was **cancelling the process** before I accessed the website.

Not sure if anybody is as stupid as me, but check if you are doing this as well.

---

<div class="post-metadata">

**Author:** ![dr\_glenn](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/dr_glenn/32/9757_2.png) [@dr\_glenn](https://community.plotly.com/u/dr_glenn)\
**Post date:** [March 29, 2020, 12:46am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/17 "2020-03-29T00:46:00Z")

</div>

I’m posting my worthless “me too” reply in the hopes that somebody who follows this thread actually has an answer by now.  
I have the same problem when using CGI in Apache. Flask app in apache OK. Dash app cmd line OK. Dash app in apache no go, Ijust get “Loading …”.

---

<div class="post-metadata">

**Author:** ![dr\_glenn](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/dr_glenn/32/9757_2.png) [@dr\_glenn](https://community.plotly.com/u/dr_glenn)\
**Post date:** [March 29, 2020, 1:52am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/18 "2020-03-29T01:52:32Z")

</div>

I have a tip on running with Python 3.x, even though Apache is running 2.7.x.  
Create your virtualenv (with Conda or other). Then I used CGI. Here is my CGI script (I am unable to install mod\_wsgi on our server).

```auto
#!/home/jkhyrsmy/venv36/weather/bin/python
# Python virtualenv must be activated
activate_this = '/home/jkhyrsmy/venv36/weather/bin/activate_this.py'

with open(activate_this) as f:
    code = compile(f.read(), activate_this, 'exec')
    exec(code, dict( __file__ =activate_this))

from wsgiref.handlers import CGIHandler

from dash_test import app

CGIHandler().run(app.server)

```

You have to specify the python interpreter from your virtual env. Then your app can truly run in Python 3 - except for the issue that we are discussing here!

---

<div class="post-metadata">

**Author:** ![akhare5](https://avatars.discourse-cdn.com/v4/letter/a/ccd318/32.png) [@akhare5](https://community.plotly.com/u/akhare5)\
**Post date:** [August 27, 2020, 6:13am UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/19 "2020-08-27T06:13:47Z")

</div>

Did anyone figure out how to fix Loading issue. Trying to makr dash work on RHEL8 . reached till here. mod wsgi work but now Dash gives loading error

---

<div class="post-metadata">

**Author:** ![chriddyp](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/chriddyp/32/16855_2.png) [@chriddyp](https://community.plotly.com/u/chriddyp)\
**Post date:** [August 27, 2020, 3:43pm UTC](https://community.plotly.com/t/loading-when-opening-localhost/7284/20 "2020-08-27T15:43:13Z")

</div>

I’d recommend opening your browser’s network console and looking at the (failed) requests

[Next page](https://community.plotly.com/t/loading-when-opening-localhost/7284.md?page=2)
