I am trying to open an empty project using PyQGIS, i.e. doing this:

enter image description here

All the answers I can find relate to already existing projects. i.e. they load a file like this:

project = QgsProject.instance()

I've tried passing no parameters/empty string to the read method, but with no effect. Looking at the methods that QgsProject.instance() provides, it doesn't seem like there is another method that would do this either.


You only need this,



  • 2
    The reason I could not find any answers is because no one asked it because it is too simple! Good to know that the iface makes this possible :-) May 4 '20 at 8:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.