Forums

Connecting database at PythonAnywhere EU from PythonAnywhere web app

Hello Guys!

I would like to ask you that is it possible to connect a database hosted at PA EU from a ''simple' PA app (Flask)?

I have a web app at pythonanywhere.com and I would like to connect to a db hosted at eu.pythonanywhere.com. Based on my experience it works fine with web apps hosted at pythonanywhere.com, but I have mysql connection problems while trying to connect to the EU.

Is it a normal behavior that I can't connect or is it possible that I am doing something wrong?

We do not expose user databases to the internet, so the databases on the US site are not visible from the EU site. If you have a paid account in both the EU and the US, you can use an SSH tunnel to connect: http://help.pythonanywhere.com/pages/AccessingMySQLFromOutsidePythonAnywhere/